Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: added copyright note with auto replacement #123

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions .github/workflows/ci-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -85,5 +85,15 @@ jobs:
with:
path: cache
key: mkdocs-overpass-dev-cache-${{ runner.os }}
- uses: jannekem/run-python-script-action@v1
name: Replace copyright date
with:
script: |
import time
file_name = "mkdocs.yml"
with open(file_name) as f:
data = f.read().replace('{current_year}', time.strftime("%Y"))
with open(file_name, "w") as f:
f.write(data)
- name: Publish dev documentation
run: mike deploy --push dev
10 changes: 10 additions & 0 deletions .github/workflows/ci-prod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,5 +71,15 @@ jobs:
with:
path: cache
key: mkdocs-overpass-prod-cache-${{ runner.os }}
- uses: jannekem/run-python-script-action@v1
name: Replace copyright date
with:
script: |
import time
file_name = "mkdocs.yml"
with open(file_name) as f:
data = f.read().replace('{current_year}', time.strftime("%Y"))
with open(file_name, "w") as f:
f.write(data)
- name: Publish latest documentation
run: mike deploy --push --update-aliases ${{github.ref_name}} latest
2 changes: 1 addition & 1 deletion mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,8 @@ extra_css:
- assets/css/palette.css
- assets/css/jupyter.css

# Copyright © 2022 - 2022 SRAI Lab –
copyright: >
Copyright © 2022 - {current_year} SRAI Lab –
<a href="#__consent">Change cookie settings</a>

plugins:
Expand Down