Skip to content

Commit

Permalink
Add GitHub values
Browse files Browse the repository at this point in the history
Create release on pipeline run
  • Loading branch information
jabbermouth committed Nov 23, 2024
1 parent 73ae68d commit 7504a79
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 3 deletions.
22 changes: 21 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ on:

# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
contents: write
pages: write
id-token: write

Expand Down Expand Up @@ -44,6 +44,26 @@ jobs:
pip install mkdocs
pip install mkdocs-material
pip install mkdocs-mermaid2-plugin
pip install mkdocs-git-revision-date-localized-plugin
# pip install mkdocs-git-committers-plugin-2
# pip install mkdocs-git-authors-plugin
- name: Tag and Create Release
shell: pwsh
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
$today = Get-Date -Format "yyyy.MMdd"
$tag = "$today.$($env:GITHUB_RUN_NUMBER)"
git config user.name "Blog Publisher"
git config user.email "[email protected]"
Write-Host "Tagging version $tag"
git tag -a $tag -m "$tag"
git push origin $tag
gh release create $tag -t $tag -n "Release $tag" --notes "Release $tag" --target main
- name: Build site
run: mkdocs build
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
.cache/
site/
15 changes: 13 additions & 2 deletions mkdocs.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
site_name: Neil's Whiteboard
copyright: Copyright © 2020-2024 Neil Docherty

repo_url: https://github.com/jabbermouth/blog
edit_uri: edit/main/docs/

plugins:
- search
Expand All @@ -17,15 +18,25 @@ plugins:
lineColor: '#F8B229'
secondaryColor: '#006100'
tertiaryColor: '#fff'

- git-revision-date-localized:
enable_creation_date: true
# - git-authors
# - git-committers:
# repository: jabbermouth/blog
# branch: main

theme:
name: material
logo: gfx/jabbermouth-good.png
icon:
repo: fontawesome/brands/github
features:
- navigation.indexes
- navigation.top
- navigation.expand
- navigation.tabs
- content.action.view
# - content.action.edit

palette:
# Palette toggle for light mode
Expand Down

0 comments on commit 7504a79

Please sign in to comment.