1
0
mirror of https://github.com/deadc0de6/dotdrop.git synced 2026-02-10 08:04:16 +00:00

remove unused script

This commit is contained in:
deadc0de6
2019-02-11 21:14:28 +01:00
parent fe163d37d5
commit bae53f2776
2 changed files with 0 additions and 86 deletions

View File

@@ -504,37 +504,6 @@ class Cfg:
cnt += 1
return key
def short_to_long(self):
"""transform all short keys to long keys"""
if not self.content[self.key_dotfiles]:
return
match = {}
new = {}
# handle the entries in dotfiles
for oldkey, v in self.content[self.key_dotfiles].items():
path = v[self.key_dotfiles_dst]
path = os.path.expanduser(path)
newkey = self._get_long_key(path)
new[newkey] = v
match[oldkey] = newkey
# replace with new keys
self.content[self.key_dotfiles] = new
# handle the entries in profiles
for k, v in self.lnk_profiles.items():
if self.key_profiles_dots not in v:
continue
if not v[self.key_profiles_dots]:
continue
new = []
for oldkey in v[self.key_profiles_dots]:
if oldkey == self.key_all:
continue
newkey = match[oldkey]
new.append(newkey)
# replace with new keys
v[self.key_profiles_dots] = new
def _dotfile_exists(self, dotfile):
"""return True and the existing dotfile key
if it already exists, False and a new unique key otherwise"""