diff options
author | Johannes Löthberg <johannes@kyriasis.com> | 2016-01-08 02:12:22 +0100 |
---|---|---|
committer | Johannes Löthberg <johannes@kyriasis.com> | 2016-01-08 02:12:22 +0100 |
commit | 8aa0b76259be3ca8acf5ec944125cd4e047d49cd (patch) | |
tree | 5e6fc6db864871e26ce6afa3343081ab80d8f028 | |
parent | e4538c99a5432874fa8e6f2ec23574c3a01fa1b9 (diff) | |
download | website-8aa0b76259be3ca8acf5ec944125cd4e047d49cd.tar.xz |
fabfile: Split pull and make tasks out
Signed-off-by: Johannes Löthberg <johannes@kyriasis.com>
-rw-r--r-- | fabfile.py | 20 |
1 files changed, 16 insertions, 4 deletions
@@ -1,10 +1,22 @@ from fabric.api import run, cd, env, task env.hosts = ['theos.kyriasis.com'] +code_dir = 'code/website' + @task(default=True) def deploy(): - code_dir = 'code/website' - with cd(code_dir): - run("git pull") - run("make") + pull() + make() + + +@task +def pull(): + with cd(code_dir): + run("git pull") + + +@task +def make(): + with cd(code_dir): + run("make") |