Skip to content

added checkout of head to show latest tag #37

added checkout of head to show latest tag

added checkout of head to show latest tag #37

Workflow file for this run

on:
push:
tags:
- '*.*.*'
workflow_dispatch:
concurrency:
group: "pages"
cancel-in-progress: false
jobs:
package_and_update_repository:
runs-on: ubuntu-latest
permissions:
contents: write
container:
image: debian:experimental
steps:
- name: Create Release
uses: ncipollo/release-action@v1
- name: Install Packages & set environment
run: |
apt update
apt install -t experimental reprepro git make build-essential libpam0g-dev sudo -y
echo "VERSION=${{ github.ref_name }}" >> $GITHUB_ENV
echo "ARCH=amd64" >> $GITHUB_ENV
- name: Checkout code
uses: actions/checkout@v4
- name: Build
run: make package
- name: Upload Release Asset
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: package/libpam-daily-word_${{ github.ref_name }}_amd64.deb
asset_name: libpam-daily-word_${{ github.ref_name }}_amd64.deb
overwrite: false
- name: Update Repository
env:
GPG_PRIVATE_KEY: ${{ secrets.GPG_PRIVATE_KEY }}
GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}
run: |
echo "$GPG_PRIVATE_KEY" | tr '|' '\n' | gpg --batch --yes --import --verbose
gpg --verbose --pinentry-mode loopback -su 'manindark@own.manindark.me' --batch --passphrase "$GPG_PASSPHRASE" list
reprepro -b repository/debian includedeb bookworm package/libpam-daily-word_${{ github.ref_name }}_amd64.deb
git config --global --add safe.directory /__w/pam_daily_word/pam_daily_word
- uses: EndBug/add-and-commit@v9
with:
add: "repository/debian"
message: apt repository update
committer_name: GitHub Actions
committer_email: 41898282+github-actions[bot]@users.noreply.github.com
new_branch: main
deploy_github_pages:
runs-on: ubuntu-latest
needs: package_and_update_repository
permissions:
contents: read
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Checkout
uses: actions/checkout@v4
with:
ref: main
- name: Setup Pages
uses: actions/configure-pages@v5
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: './repository'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4