From 9ee5920f69e7ca25e94bbd027fc3fd07fbb4b9ba Mon Sep 17 00:00:00 2001 From: Stephan Creutz Date: Sun, 18 Jun 2023 21:15:37 +0200 Subject: [PATCH 1/2] Remove ERT and "package" installation in CI Since Emacs 23 is dropped for quite some time now, remove installation of ERT and "package", because they are built-in since Emacs 24. --- .github/workflows/test.yml | 6 ------ test/github-actions.sh | 20 ++------------------ 2 files changed, 2 insertions(+), 24 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 6112e35cc..df70119e3 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -39,15 +39,9 @@ jobs: env emacs --version - - name: Install prereqs - run: | - source test/github-actions.sh - prereqs - - name: Compilation run: | source test/github-actions.sh - byte-compile pkg/*.el byte-compile -Werror *.el methods/*.el - name: Test diff --git a/test/github-actions.sh b/test/github-actions.sh index d95786c02..32e802f77 100644 --- a/test/github-actions.sh +++ b/test/github-actions.sh @@ -6,22 +6,6 @@ # - check-whitespace() # - ert-tests() -# Installs ert and package.el as needed. -prereqs() { - # Put external elisp into pkg/. - (mkdir -p pkg && cd pkg - if ! emacs -Q --batch --eval "(require 'ert)" ; then - ert_compat=https://raw.githubusercontent.com/ohler/ert/c619b56c5bc6a866e33787489545b87d79973205 - curl -LO $ert_compat/lisp/emacs-lisp/ert.el \ - -O $ert_compat/lisp/emacs-lisp/ert-x.el - fi - if ! emacs -Q --batch --eval "(require 'package)" ; then - pkg_compat23=https://raw.githubusercontent.com/mirrors/emacs/ba08b24186711eaeb3748f3d1f23e2c2d9ed0d09 - curl -LO $pkg_compat23/lisp/emacs-lisp/package.el \ - -O $pkg_compat23/lisp/emacs-lisp/package-x.el - fi) -} - BASE=$(cat "$GITHUB_EVENT_PATH" | jq -r '.pull_request.base.sha') if [ "$BASE" = 'null' ]; then BASE=$(cat "$GITHUB_EVENT_PATH" | jq -r '.before') @@ -70,7 +54,7 @@ else fi ert-tests() { - emacs -batch -Q $EMACS_OPT -L pkg/ -L . -l test/el-get-tests.el -f ert-run-tests-batch-and-exit + emacs -batch -Q $EMACS_OPT -L . -l test/el-get-tests.el -f ert-run-tests-batch-and-exit } # byte-compile [-Werror] ... @@ -80,7 +64,7 @@ byte-compile() { error_on_warning=t shift fi - emacs -Q -L pkg/ -L . -L methods/ -batch \ + emacs -Q -L . -L methods/ -batch \ --eval "(setq byte-compile-error-on-warn $error_on_warning)" \ -f batch-byte-compile "$@" } From 21d9df39dcee1750eb14abfee7970f056f2beade Mon Sep 17 00:00:00 2001 From: Stephan Creutz Date: Sun, 18 Jun 2023 21:32:55 +0200 Subject: [PATCH 2/2] Remove "prereqs" function left-overs --- test/github-actions.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/test/github-actions.sh b/test/github-actions.sh index 32e802f77..8cc7b1741 100644 --- a/test/github-actions.sh +++ b/test/github-actions.sh @@ -1,6 +1,5 @@ # source me # Define the following functions here to keep .github/workflows/test.yml nice and tidy -# - prereqs() # - byte-compile() # - check-recipes() # - check-whitespace() @@ -72,4 +71,4 @@ byte-compile() { shopt -s nullglob # show definitions for log -declare -f prereqs byte-compile ert-tests check-recipes check-whitespace +declare -f byte-compile ert-tests check-recipes check-whitespace