Skip to content

march-language/setup-march

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 

Repository files navigation

setup-march

A GitHub Action that installs the March programming language in your CI workflow.

Usage

- uses: march-language/setup-march@v1
  with:
    march-version: main

Inputs

Input Description Default
march-version Branch, tag, or commit SHA to install main
ocaml-compiler OCaml compiler version used to build March 5.3.0
github-token GitHub token to avoid API rate limits ${{ github.token }}

Outputs

Output Description
march-version The commit SHA of the installed March version
march-path Path to the March installation directory

Example

name: CI
on: [push, pull_request]

jobs:
  test:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4

      - uses: march-language/setup-march@v1
        with:
          march-version: main

      - run: march my_program.march

How it works

  1. Resolves the march-version input to a commit SHA for reliable cache keying.
  2. Restores the March build from cache if available (keyed by SHA + OS + OCaml version).
  3. Always installs system dependencies (blake3, brotli, zstd, llvm).
  4. On a cache miss: sets up OCaml via ocaml/setup-ocaml, clones the march repo, installs opam dependencies, and builds with dune.
  5. Adds march to PATH.

Cached runs skip OCaml setup and the March build — the expensive parts — keeping them fast.

Step 3 is deliberately not cache-gated. The march binary dynamically links against these libraries, and they install to system paths outside the cached directory (~/.local/march). Skipping them on a cache hit yields a restored binary that cannot load, failing with exit 127 on every invocation.

Platform support

OS Status
Ubuntu Supported
macOS Supported
Windows Not supported

About

github action for installing the March Programming Language

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors