mirror of
https://github.com/deadc0de6/dotdrop.git
synced 2026-02-09 22:49:15 +00:00
fix bug when importing with the -l flag
This commit is contained in:
@@ -540,7 +540,7 @@ class Cfg:
|
|||||||
if exists:
|
if exists:
|
||||||
if debug:
|
if debug:
|
||||||
self.log.dbg('key already exists: {}'.format(key))
|
self.log.dbg('key already exists: {}'.format(key))
|
||||||
# when dotfile already there somewhere
|
# retrieve existing dotfile
|
||||||
dotfile = self.dotfiles[key]
|
dotfile = self.dotfiles[key]
|
||||||
if dotfile in self.prodots[profile]:
|
if dotfile in self.prodots[profile]:
|
||||||
self.log.err('\"{}\" already present'.format(dotfile.key))
|
self.log.err('\"{}\" already present'.format(dotfile.key))
|
||||||
@@ -560,6 +560,7 @@ class Cfg:
|
|||||||
self.log.dbg('dotfile attributed key: {}'.format(key))
|
self.log.dbg('dotfile attributed key: {}'.format(key))
|
||||||
# adding the new dotfile
|
# adding the new dotfile
|
||||||
dotfile.key = key
|
dotfile.key = key
|
||||||
|
dotfile.link = link
|
||||||
if debug:
|
if debug:
|
||||||
self.log.dbg('adding new dotfile: {}'.format(dotfile))
|
self.log.dbg('adding new dotfile: {}'.format(dotfile))
|
||||||
# add the entry in the yaml file
|
# add the entry in the yaml file
|
||||||
|
|||||||
@@ -282,7 +282,7 @@ def cmd_importer(opts, conf, paths):
|
|||||||
remove(dst)
|
remove(dst)
|
||||||
os.symlink(srcf, dst)
|
os.symlink(srcf, dst)
|
||||||
retconf, dotfile = conf.new(dotfile, opts['profile'],
|
retconf, dotfile = conf.new(dotfile, opts['profile'],
|
||||||
linkit, debug=opts['debug'])
|
link=linkit, debug=opts['debug'])
|
||||||
if retconf:
|
if retconf:
|
||||||
LOG.sub('\"{}\" imported'.format(path))
|
LOG.sub('\"{}\" imported'.format(path))
|
||||||
cnt += 1
|
cnt += 1
|
||||||
|
|||||||
Reference in New Issue
Block a user