From a0a2f82134f3f7e38ec8137b44b257f8983a023f Mon Sep 17 00:00:00 2001 From: ARATA Mizuki Date: Sun, 1 Sep 2024 21:46:49 +0900 Subject: [PATCH] Add GitHub Actions to build ClutTeX --- .gitattributes | 1 + .github/workflows/build.yaml | 35 +++++++++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+) create mode 100644 .github/workflows/build.yaml diff --git a/.gitattributes b/.gitattributes index de2f316..b15f795 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,2 +1,3 @@ .gitignore export-ignore .gitattributes export-ignore +/.github export-ignore diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml new file mode 100644 index 0000000..737a111 --- /dev/null +++ b/.github/workflows/build.yaml @@ -0,0 +1,35 @@ +on: [push, pull_request] +name: build +jobs: + lunarml: + name: Build + runs-on: ubuntu-24.04 + steps: + - uses: actions/checkout@v4 + - name: Install dependencies + run: | + sudo apt-get update + sudo apt-get install lua5.3 liblua5.3-dev + docker pull ghcr.io/minoki/lunarml:0.2.0 + sudo ln -s /usr/bin/lua /usr/local/bin/texlua + - name: Install LuaFileSystem + run: | + curl -LO "https://github.com/lunarmodules/luafilesystem/archive/refs/tags/v1_8_0.tar.gz" + tar xf v1_8_0.tar.gz + cd luafilesystem-1_8_0 + make LUA_VERSION=5.3 + sudo make LUA_VERSION=5.3 install + - name: Build + run: | + make lunarml="docker run --rm --platform linux/amd64 -v \"$(pwd)\":/work -w /work ghcr.io/minoki/lunarml:0.2.0 lunarml" + - name: Show version + run: make check-version + - name: Archive + run: make archive + - name: Upload + uses: actions/upload-artifact@v4 + with: + name: archive + path: | + cluttex-*.tar.gz + cluttex-*.zip