No description
  • Shell 57.6%
  • Common Lisp 42.4%
Find a file
dxtr c9f3c09031 Install stift 0.3.0 in stift-ci by default
stift 0.3.0 vendors a build list and verifies the copies, and compresses
executables with stift build --compress where the Lisp can.
2026-10-16 22:55:44 +02:00
checkout Make checkout run under sh and install git when missing 2026-10-07 17:29:59 +02:00
lib Move Lisp install steps into shared scripts 2026-10-14 02:13:24 +02:00
lisp-ci Move Lisp install steps into shared scripts 2026-10-14 02:13:24 +02:00
rebar3-ci Stop claiming rebar3-ci treats warnings as errors 2026-10-11 17:00:48 +02:00
stift-ci Install stift 0.3.0 in stift-ci by default 2026-10-16 22:55:44 +02:00
vend-ci Add vend-ci composite action for vend projects 2026-10-14 02:13:24 +02:00
README.md Install stift 0.3.0 in stift-ci by default 2026-10-16 22:55:44 +02:00

forgejo-actions

Reusable composite actions for Forgejo Actions workflows.

All actions are shell-only (no JavaScript), so they run inside bare language container images such as erlang:NN that ship without Node.js. Scripts that several of them share live in lib/, which is not an action itself.

Versions

Releases are tagged vMAJOR.MINOR.PATCH, and the major tag, v1, moves to each release of its major version. A workflow that uses @v1 gets compatible releases as they come, such as a newer release of stift that stift-ci installs by default, without a change of its own; one that uses a full version, such as @v1.3.1, stays on that release. A release that would break the workflows that use @v1 starts v2 instead.

checkout

A node-less replacement for actions/checkout. It hand-rolls an authenticated git fetch using the default workflow token, so it works in containers where the JS-based actions/checkout cannot run. It only needs a POSIX sh; if git is missing it is installed via the image's package manager (apt, apk, dnf, microdnf, yum, zypper or pacman).

Must be referenced remotely, never as a local ./checkout. A local action is read from the checked-out workspace — but this action is what populates the workspace, so it has to be fetched by the runner first.

- uses: fakehacker/actions/checkout@v1
  # with:
  #   ref: ${{ github.ref }}   # ref to fetch
  #   fetch-depth: "1"         # 0 for full history
  #   token: ${{ github.token }}

rebar3-ci

Runs a standard Erlang/rebar3 quality gate: installs rebar3 if absent, then compile, xref, eunit, and dialyzer. To make compiler warnings fail the build, set warnings_as_errors in your rebar.config erl_opts.

- uses: fakehacker/actions/rebar3-ci@v1

lisp-ci

Runs a qlot-pinned Common Lisp project's Parachute suite on SBCL and/or CCL. It installs SBCL and CCL from their upstream x86-64 release tarballs and qlot from its installer (SBCL unless the requested version is already on PATH, the others only if they are missing), runs qlot install, then loads <system>/test and runs the Parachute test named after its package on each Lisp. Needs an apt-based image, such as debian:forky.

- uses: fakehacker/actions/lisp-ci@v1
  with:
    system: cl-ft2
    # test-system: cl-ft2/test        # defaults to <system>/test
    # lisps: sbcl ccl                 # either or both
    # packages: libfreetype6 fonts-dejavu-core   # extra apt packages
    # features: cl-net-force-usocket  # pushed onto *features* before loading
    # force: "true"                   # recompile system + test system
    # sbcl-version: "2.6.9"
    # ccl-version: "1.13"

Each Lisp exits 0 if the suite passed, 1 if it failed and 2 if loading signalled an error. To test a project under several feature sets, call the action once per set. Pass force: "true" on the later calls so the earlier fasls are rebuilt. To test several SBCL versions, put sbcl-version in a job matrix.

vend-ci

Runs the test suites of a Common Lisp project whose dependencies are managed by vend, on SBCL and/or CCL. It installs SBCL and CCL as lisp-ci does, and vend from the release binary of that SBCL-built fork unless the requested version is already on PATH. It then runs vend get, which keeps whatever is already in vendored/, and vend test on each Lisp. Needs an apt-based image with glibc 2.38 or newer, such as debian:forky.

- uses: fakehacker/actions/vend-ci@v1
  # with:
  #   lisps: sbcl ccl                 # either or both
  #   packages: libfreetype6 fonts-dejavu-core   # extra apt packages
  #   sbcl-version: "2.6.9"
  #   ccl-version: "1.13"
  #   vend-version: "0.4.0"

vend test finds test systems through the test-op of the project's systems and runs Parachute, clunit2 and FiveAM suites; see vend's README for the setup it expects. Each Lisp's step fails if any suite failed or a test system signalled an error while loading.

stift-ci

Runs the test suites of a Common Lisp project whose dependencies are pinned by stift, on SBCL and/or CCL. It installs SBCL and CCL as lisp-ci does, SBCL always, since stift is built with it, and builds stift from its release tag, 0.2.0 or later, unless that version is already on PATH. Then stift test fetches what the project's stiftfile pins and runs each suite in a new Lisp for each implementation. Needs an apt-based image, such as debian:forky.

- uses: fakehacker/actions/stift-ci@v1
  # with:
  #   lisps: sbcl ccl                 # either or both
  #   systems: cl-ft2                 # defaults to the project's primary systems
  #   packages: libfreetype6 fonts-dejavu-core   # extra apt packages
  #   sbcl-version: "2.6.9"
  #   ccl-version: "1.13"
  #   stift-version: "0.3.0"

stift test runs each system's suite with asdf:test-system, and counts a suite as failed when an error escapes it, so the test system's test-op must signal when its tests fail; see stift's README. The step fails if any suite failed. stift sets ASDF up to find exactly the build list, with no init files and no Quicklisp; a later step can load the same setup into another Lisp with (load "$(stift setup)").

Example workflow

runs-on, container, and any version matrix stay in the caller — composite actions cannot declare them.

name: CI
on: [push, pull_request]
jobs:
  test:
    runs-on: ubuntu-latest
    strategy:
      fail-fast: false
      matrix:
        otp: ['27', '28', '29']
    container:
      image: erlang:${{ matrix.otp }}
    steps:
      - uses: fakehacker/actions/checkout@v1
      - uses: fakehacker/actions/rebar3-ci@v1

  lisp:
    runs-on: ubuntu-latest
    strategy:
      fail-fast: false
      matrix:
        sbcl: ['2.5.0', '2.6.9']
    container:
      image: debian:forky
    steps:
      - uses: fakehacker/actions/checkout@v1
      - uses: fakehacker/actions/lisp-ci@v1
        with:
          system: cl-ft2
          lisps: sbcl
          sbcl-version: ${{ matrix.sbcl }}