aboutsummaryrefslogtreecommitdiffstats
path: root/dotfiles.py
diff options
context:
space:
mode:
authorGravatar Jon Bernard <jbernard@tuxion.com> 2016-01-05 09:49:50 -0500
committerGravatar Jon Bernard <jbernard@tuxion.com> 2016-01-05 11:23:30 -0500
commitf627d48163a05801868915e69d630a2961178374 (patch)
tree3464e598736d329765b525800f343aba3cf35ea6 /dotfiles.py
parent6735cda88aac20d21aecd239927311f07ef4f7f2 (diff)
downloaddotfiles-f627d48163a05801868915e69d630a2961178374.tar.gz
dotfiles-f627d48163a05801868915e69d630a2961178374.tar.bz2
dotfiles-f627d48163a05801868915e69d630a2961178374.zip
Rename sync/unsync to link/unlink
I think this naming is more appropriate and intuitive
Diffstat (limited to 'dotfiles.py')
-rw-r--r--dotfiles.py14
1 files changed, 7 insertions, 7 deletions
diff --git a/dotfiles.py b/dotfiles.py
index af35d13..caf5108 100644
--- a/dotfiles.py
+++ b/dotfiles.py
@@ -76,7 +76,7 @@ class Dotfile(object):
if self.target.check(exists=1):
raise OSError(errno.EEXIST, self.target)
self.name.move(self.target)
- self.sync()
+ self.link()
def remove(self):
if self.target.check(exists=0):
@@ -84,10 +84,10 @@ class Dotfile(object):
self.name.remove()
self.target.move(self.name)
- def sync(self):
+ def link(self):
self.name.mksymlinkto(self.target)
- def unsync(self):
+ def unlink(self):
self.name.remove()
@@ -164,16 +164,16 @@ def status(repo, all, color):
@cli.command()
@click.argument('files', nargs=-1, type=click.Path())
@pass_repo
-def sync(repo, files):
+def link(repo, files):
"""Create any missing symlinks."""
for filename in files:
- click.echo('Dotfile(%s).sync()' % filename)
+ click.echo('Dotfile(%s).link()' % filename)
@cli.command()
@click.argument('files', nargs=-1, type=click.Path(exists=True))
@pass_repo
-def unsync(repo, files):
+def unlink(repo, files):
"""Remove existing symlinks."""
for filename in files:
- click.echo('Dotfile(%s).unsync()' % filename)
+ click.echo('Dotfile(%s).unlink()' % filename)