commit 32e3df18b76cd3f29b8219415c9bf3d42451867e parent ea1149fe1ff1b1f72ccf3a90513c027dffe04be3 Author: GeaRSiX <gearsix@tuta.io> Date: Mon, 15 Jun 2020 10:42:54 +0100 install-all ignores non-dfl files (cmd now works) Diffstat:
M | src/dotfm.py | | | 11 | +++++++++-- |
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/src/dotfm.py b/src/dotfm.py @@ -122,8 +122,15 @@ def dotfm_installall(dotfile_dir): df = os.path.abspath('{}/{}'.format(dotfile_dir, df)) if os.path.isfile(df): LOGGER.debug('found {}, installing...'.format(df)) - dotfm_install(df) - elif os.path.isdir(df): + found = False + for dfl in DOTFILE_LOCATIONS: + if os.path.basename(df) in dfl[0]: + found = True + if found: + dotfm_install(df) + else: + LOGGER.info('found {}, skipping...'.format(df)) + elif os.path.isdir(df) and os.path.basename(df) != ".git": LOGGER.debug('found dir {}') dotfm_installall(df)