Add tmux plugin manager and plugins

This commit is contained in:
2017-11-01 12:11:35 +01:00
parent ee8364d7f3
commit 2ebc02fdc7
2 changed files with 26 additions and 0 deletions

View File

@@ -78,6 +78,20 @@ def install_tmux(pdotfiles, force=False):
print("Symlinking {} to {}".format(phome_tmuxrc, pdotfiles_tmuxrc))
phome_tmuxrc.symlink_to(pdotfiles_tmuxrc)
# tpm
tpm = phome / Path(".tmux/plugins/tpm")
if not force and tpm.exists():
print("tpm already installed?")
else:
if force and tpm.exists():
shutil.rmtree(tpm.as_posix())
print("Install tpm")
check_call(
["git", "clone", "https://github.com/tmux-plugins/tpm",
tpm.as_posix()])
check_call((tpm / Path("bin") / Path("install_plugins")).as_posix())
if __name__ == "__main__":
args = docopt(HELPTEXT, version='0.1')
if args["install"]: