MCPcopy
hub / github.com/blackboxo/CleanMyWechat / get_dir_name

Function get_dir_name

utils/selectVersion.py:111–127  ·  view source on GitHub ↗
(filepath)

Source from the content-addressed store, hash-verified

109
110
111def get_dir_name(filepath):
112 dirlist = []
113 names = []
114 if not filepath or not os.path.exists(filepath):
115 return (dirlist, names)
116
117 account_dirs = search_account_dirs(filepath)
118 for account_dir in account_dirs:
119 name = os.path.basename(account_dir.rstrip(os.sep))
120 if not name:
121 name = account_dir
122 if 'wxwork' in account_dir.lower() and not name.lower().startswith('wxwork'):
123 name = 'WXWork-' + name
124 dirlist.append(account_dir)
125 names.append(name)
126
127 return (dirlist, names)
128
129
130def find_all_wechat_paths():

Callers 4

merge_detected_accountsFunction · 0.90
open_fileMethod · 0.90
getAllPathMethod · 0.85

Calls 1

search_account_dirsFunction · 0.85

Tested by

no test coverage detected