mirror of
https://github.com/deadc0de6/dotdrop.git
synced 2026-02-11 12:34:16 +00:00
fix bug with ALL when importing new dotfile
This commit is contained in:
@@ -126,7 +126,7 @@ class Cfg:
|
|||||||
if not v[self.key_profiles_dots]:
|
if not v[self.key_profiles_dots]:
|
||||||
continue
|
continue
|
||||||
dots = v[self.key_profiles_dots]
|
dots = v[self.key_profiles_dots]
|
||||||
if len(dots) == 1 and dots == [self.key_all]:
|
if self.key_all in dots:
|
||||||
self.prodots[k] = list(self.dotfiles.values())
|
self.prodots[k] = list(self.dotfiles.values())
|
||||||
else:
|
else:
|
||||||
self.prodots[k].extend([self.dotfiles[d] for d in dots])
|
self.prodots[k].extend([self.dotfiles[d] for d in dots])
|
||||||
@@ -192,8 +192,10 @@ class Cfg:
|
|||||||
if profile not in self.prodots:
|
if profile not in self.prodots:
|
||||||
self.prodots[profile] = []
|
self.prodots[profile] = []
|
||||||
self.prodots[profile].append(dotfile)
|
self.prodots[profile].append(dotfile)
|
||||||
|
|
||||||
l = self.content[self.key_profiles][profile]
|
l = self.content[self.key_profiles][profile]
|
||||||
l[self.key_profiles_dots].append(dotfile.key)
|
if self.key_all not in l[self.key_profiles_dots]:
|
||||||
|
l[self.key_profiles_dots].append(dotfile.key)
|
||||||
return True
|
return True
|
||||||
|
|
||||||
# adding the dotfile
|
# adding the dotfile
|
||||||
@@ -208,7 +210,8 @@ class Cfg:
|
|||||||
|
|
||||||
# link it to this profile
|
# link it to this profile
|
||||||
pro = self.content[self.key_profiles][profile]
|
pro = self.content[self.key_profiles][profile]
|
||||||
pro[self.key_profiles_dots].append(dotfile.key)
|
if self.key_all not in pro[self.key_profiles_dots]:
|
||||||
|
pro[self.key_profiles_dots].append(dotfile.key)
|
||||||
|
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user