Skip to content

Packages

Packages #1

Workflow file for this run

name: Packages
on:
workflow_run:
workflows: ["Startup"]
types:
- completed
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
REPO_BADGES: 'jcs-emacs/badges'
REPO_BIN: 'jcs-emacs/binaries'
jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
emacs-version:
- 29.1
steps:
- name: Checkout binaries repository
uses: actions/checkout@v4
with:
repository: ${{ env.REPO_BIN }}
persist-credentials: false
fetch-depth: 0
- name: Create LFS file list
run: git lfs ls-files -l | cut -d' ' -f1 | sort > .lfs-assets-id
- name: Restore LFS cache
uses: actions/cache@v3
id: lfs-cache
with:
path: .git/lfs
key: ${{ runner.os }}-lfs-${{ hashFiles('.lfs-assets-id') }}
- name: Git LFS Pull
continue-on-error: true
run: |
git lfs pull
git add .
git reset --hard
- name: Extract zipped .emacs.d
continue-on-error: true
run: tar -xvf main.tar -C $HOME
- uses: jcs090218/setup-emacs@master
with:
version: ${{ matrix.emacs-version }}
- uses: actions/checkout@v4
- name: Copy configuration files
run: |
chmod -R 777 ./
make copy_config
- name: Test packages
run: make packages
- name: Move badges to home
run: mv ./docs/badges/packages.svg ~/
- name: Checkout badges repository
uses: actions/checkout@v4
with:
repository: ${{ env.REPO_BADGES }}
persist-credentials: false
fetch-depth: 0
- name: Move badges to repository (Unix)
if: matrix.os == 'ubuntu-latest' || matrix.os == 'macos-latest'
run: mv -f ~/packages.svg ./config/
- name: Move badges to repository (Windows)
if: matrix.os == 'windows-latest'
run: mv -Force ~/packages.svg ./config/
- name: Set git config
run: |
git config user.name github-actions
git config user.email [email protected]
- name: Commit
continue-on-error: true
run: |
git pull
git add .
git commit -m "Update SVG badges - packages"
- name: Push generated badges - packages
continue-on-error: true
uses: jcs090218/github-push-action@master
with:
repository: ${{ env.REPO_BADGES }}
github_token: ${{ secrets.PAT }}
branch: master
retry: 3