From 0b2a3d2a1b7472231f29bf08b638273c59fbd60e Mon Sep 17 00:00:00 2001 From: Steve Purcell Date: Wed, 6 Nov 2024 15:18:44 +0000 Subject: [PATCH] Update CI config --- .github/dependabot.yml | 10 ++++++++++ .github/workflows/test.yml | 17 ++++++++++++++--- Makefile | 10 +++++----- 3 files changed, 29 insertions(+), 8 deletions(-) create mode 100644 .github/dependabot.yml diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..ba29cb1 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,10 @@ +version: 2 +updates: +- package-ecosystem: github-actions + directory: "/" + schedule: + interval: daily + open-pull-requests-limit: 10 + commit-message: + prefix: "chore" + include: "scope" diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 8358a41..294f321 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -7,6 +7,16 @@ on: - '**.md' jobs: + lint: + runs-on: ubuntu-latest + steps: + - uses: purcell/setup-emacs@master + with: + version: 29.4 + - uses: actions/checkout@v4 + - name: Run tests + run: make package-lint + build: runs-on: ubuntu-latest strategy: @@ -20,12 +30,13 @@ jobs: - 27.2 - 28.1 - 28.2 + - 29.4 - snapshot steps: - uses: purcell/setup-emacs@master with: version: ${{ matrix.emacs_version }} - - uses: actions/checkout@v2 - - name: Run tests - run: make + - uses: actions/checkout@v4 + - name: Compile + run: make compile diff --git a/Makefile b/Makefile index 9a1f1e7..2be223d 100644 --- a/Makefile +++ b/Makefile @@ -1,26 +1,26 @@ EMACS ?= emacs # A space-separated list of required package names -NEEDED_PACKAGES = package-lint +DEPS = INIT_PACKAGES="(progn \ (require 'package) \ (push '(\"melpa\" . \"https://melpa.org/packages/\") package-archives) \ (package-initialize) \ - (dolist (pkg '(${NEEDED_PACKAGES})) \ + (dolist (pkg '(PACKAGES)) \ (unless (package-installed-p pkg) \ (unless (assoc pkg package-archive-contents) \ (package-refresh-contents)) \ (package-install pkg))) \ )" -all: compile package-lint clean-elc +all: compile package-lint test clean-elc package-lint: - ${EMACS} -Q --eval ${INIT_PACKAGES} -batch -f package-lint-batch-and-exit ibuffer-vc.el + ${EMACS} -Q --eval $(subst PACKAGES,package-lint,${INIT_PACKAGES}) -batch -f package-lint-batch-and-exit ibuffer-vc.el compile: clean-elc - ${EMACS} -Q --eval ${INIT_PACKAGES} -L . -batch -f batch-byte-compile *.el + ${EMACS} -Q --eval $(subst PACKAGES,${DEPS},${INIT_PACKAGES}) -L . -batch -f batch-byte-compile *.el clean-elc: rm -f f.elc