aboutsummaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorSam Cedarbaum <scedarbaum@gmail.com>2021-04-15 00:38:23 -0400
committerJonas Bernoulli <jonas@bernoul.li>2021-04-28 14:19:13 +0200
commit1f3995ec81cb110eeef885c9921ecfefac07bdf3 (patch)
treea99a10a2e564408adfba380f73e66092ca551ae4 /.github
parent3098bf68f258e088ac0d3307398d99d8c2edba41 (diff)
Install Emacs with libegit in CI
Replace the `setup-emacs' GitHub action with a custom Nix install (defined in t/default.nix) that bundles Emacsen with libegit and its other dependencies.
Diffstat (limited to '.github')
-rw-r--r--.github/workflows/test.yml20
1 files changed, 10 insertions, 10 deletions
diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index 6fd3644..c1ee1be 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -1,9 +1,5 @@
name: test
on: [ push, pull_request ]
-env:
- CURL: "curl -fsSkL --retry 9 --retry-delay 9"
- GHRAW: "https://raw.githubusercontent.com"
- BUILD_MAGIT_LIBGIT: "false"
jobs:
test:
runs-on: ubuntu-20.04
@@ -19,17 +15,21 @@ jobs:
- 27.1
- snapshot
steps:
- - uses: purcell/setup-emacs@master
+ - uses: cachix/install-nix-action@v12
with:
- version: ${{ matrix.emacs_version }}
+ nix_path: nixpkgs=channel:nixos-unstable
+ - uses: cachix/cachix-action@v8
+ with:
+ name: emacs-ci
- uses: actions/checkout@v2
- name: Install
run: |
- $CURL -O ${GHRAW}/magnars/dash.el/master/dash.el
- $CURL -O ${GHRAW}/magit/transient/master/lisp/transient.el
- $CURL -O ${GHRAW}/magit/with-editor/master/with-editor.el
- emacs -Q --batch -L . -f batch-byte-compile dash.el transient.el with-editor.el
+ # Build and install Emacs (+ magit dependencies) using Nix
+ emacs_ci_version=$(echo "emacs-${{ matrix.emacs_version }}" | sed -e "s/\./-/g")
+ nix-env -f ./t/default.nix -iA $emacs_ci_version
emacs --version
+
+ # Configure Git
git config --global user.name "A U Thor"
git config --global user.email a.u.thor@example.com
git tag 0