We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f00311e commit 0915d51Copy full SHA for 0915d51
fabfile.py
@@ -65,9 +65,12 @@ def preview():
65
66
67
def publish(commit_message):
68
- env.msg = commit_message
69
"""Publish to GitHub Pages"""
+ env.msg = commit_message
70
+ env.GH_TOKEN = os.getenv('GH_TOKEN')
71
+ env.TRAVIS_REPO_SLUG = os.getenv('TRAVIS_REPO_SLUG')
72
clean()
- preview()
- local("ghp-import -m '{msg}' -b {gp_branch} {deploy_path}".format(**env))
73
- local("git push origin {gp_branch}".format(**env))
+ local('pelican -s publishconf.py')
74
+ with hide('running', 'stdout', 'stderr'):
75
+ local("ghp-import -m '{msg}' -b {gp_branch} {deploy_path}".format(**env))
76
+ local("git push -fq https://{GH_TOKEN}@github.com/{TRAVIS_REPO_SLUG}.git {gp_branch}".format(**env))
0 commit comments