Skip to content

Commit

Permalink
fix docs publishing
Browse files Browse the repository at this point in the history
  • Loading branch information
ofek committed Apr 20, 2020
1 parent d8960b0 commit 38d81ac
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
1 change: 1 addition & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ on:
paths:
- docs/**
- .github/workflows/publish.yml
- tasks/docs.py
- mkdocs.yml
- tox.ini
branches:
Expand Down
6 changes: 5 additions & 1 deletion tasks/docs.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,11 @@ def publish(ctx):
git_user = get_git_user(ctx)
git_email = get_git_email(ctx)
latest_commit_hash = get_latest_commit_hash(ctx)
remote = f'https://{github_token}@github.com/ofek/csi-gcs.git'

if 'GITHUB_ACTIONS' in os.environ:
remote = f'https://{os.getenv("GITHUB_ACTOR")}:{github_token}@github.com/ofek/csi-gcs.git'
else:
remote = f'https://{github_token}@github.com/ofek/csi-gcs.git'

print('Copying site to a temporary directory...')
with TemporaryDirectory() as d:
Expand Down

0 comments on commit 38d81ac

Please sign in to comment.