def update(): """ Update this tool. """ root_dir = config.get_root_dir() shell.run(f"git -C {root_dir} pull") shell.run("poetry install --remove-untracked", cwd=root_dir)
def _link_zshrc(self): """ Create symlink from ~/.zshrc.d to the zshrc file for this module. """ zshrc_fname = self.zshrc_file or f"{self.name.lower()}.zsh" zshrc_path = config.get_root_dir() / "zshrc" / zshrc_fname if zshrc_path.exists(): files.create_symlink( zshrc_path, Path.home() / ".zshrc.d", )
def _create_symlinks(self): for _target, _link in self.symlinks.items(): files.create_symlink( config.get_root_dir() / "configfiles" / _target, Path(_link).expanduser(), )
def upgrade_action(self): shell.run(str(config.get_root_dir() / "scripts" / "set-defaults.sh"))