Skip to content

Commit

Permalink
Merge branch 'track-upstream'
Browse files Browse the repository at this point in the history
* track-upstream:
  Add recipe for lsp-pyright (dimitri#2908)
  Fix swiper build (dimitri#2907)
  Remove ERT and "package" installation in CI (dimitri#2906)
  Add Emacs 28.2 to CI builds and fix newly introduced warnings (dimitri#2905)
  Upgrade deprecated actions/checkout@v2 to v3 (dimitri#2904)
  • Loading branch information
vedang committed Aug 8, 2023
2 parents 541418f + f3f1edd commit ee3b8ef
Show file tree
Hide file tree
Showing 7 changed files with 33 additions and 36 deletions.
9 changes: 2 additions & 7 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,12 @@ jobs:
- 25.3
- 26.3
- 27.2
- 28.2
- snapshot
env:
EMACS_VERSION: ${{ matrix.emacs_version }}
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
fetch-depth: 0

Expand All @@ -38,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
Expand Down
3 changes: 2 additions & 1 deletion el-get-check.el
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,8 @@ Current possibe elements are:
1))))

(defun el-get-check-recipe-batch ()
"emacs -Q -batch -f el-get-check-recipe-batch [-W<:level>] [-Wno-<warning>...] *.rcp
"emacs -Q -batch -f el-get-check-recipe-batch [-W<:level>]
[-Wno-<warning>...] *.rcp
<:level> can be any valid warning level, see `warning-levels'.
See `el-get-check-suppressed-warnings' for possible <warning> values."
Expand Down
3 changes: 2 additions & 1 deletion el-get-status.el
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,8 @@ REMOVED are added and removed properties, respectively."
(defun el-get-merge-properties-into-status (package-or-source
operation
&rest keys)
"Merge updatable properties for package into package status alist (or status file).
"Merge updatable properties for package into package status
alist (or status file).
The first argument is either a package source or a package name,
in which case the source will be read using
Expand Down
6 changes: 4 additions & 2 deletions el-get.el
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,8 @@
"List of packages to install next, used when dealing with dependencies.")

(defun el-get-installation-failed (package signal-data)
"Run all the failure hooks for PACKAGE and `signal' the car and cdr of SIGNAL-DATA."
"Run all the failure hooks for PACKAGE and `signal' the car and
cdr of SIGNAL-DATA."
(run-hook-with-args 'el-get-post-error-hooks package signal-data)
(signal (car signal-data) (cdr signal-data)))

Expand Down Expand Up @@ -336,7 +337,8 @@ which defaults to the first element in `el-get-recipe-path'."
(eval form el-get-eval-lexical)))))

(defun el-get-lazy-run-package-support (form fname package)
"Like `el-get-run-package-support', but using `eval-after-load' to wait until PACKAGE is loaded."
"Like `el-get-run-package-support', but using `eval-after-load'
to wait until PACKAGE is loaded."
(el-get-eval-after-load package
`(el-get-run-package-support ',form ',fname ',package)))

Expand Down
5 changes: 5 additions & 0 deletions recipes/lsp-pyright.rcp
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
(:name lsp-pyright
:description "lsp-mode client leveraging Pyright language server"
:depends (dash lsp-mode ht)
:type github
:pkgname "emacs-lsp/lsp-pyright")
20 changes: 15 additions & 5 deletions recipes/swiper.rcp
Original file line number Diff line number Diff line change
@@ -1,10 +1,20 @@
(:name swiper
:description "Gives you an overview as you search for a regex."
:type github
:depends (cl-lib avy)
:depends (cl-lib avy hydra)
:pkgname "abo-abo/swiper"
:build `(("make" ,(format "emacs=%s -L %s" el-get-emacs (concat (file-name-as-directory el-get-dir) "avy")) "compile")
("makeinfo" "-o" "doc/ivy.info" "doc/ivy.texi"))
:build/berkeley-unix `(("gmake" ,(format "emacs=%s -L %s" el-get-emacs (concat (file-name-as-directory el-get-dir) "avy")) "compile")
("gmakeinfo" "-o" "doc/ivy.info" "doc/ivy.texi"))
:build `(("make"
,(format "emacs=%s -L %s -L %s"
el-get-emacs
(concat (file-name-as-directory el-get-dir) "avy")
(concat (file-name-as-directory el-get-dir) "hydra"))
"compile")
("makeinfo" "-o" "doc/ivy.info" "doc/ivy.texi"))
:build/berkeley-unix `(("gmake"
,(format "emacs=%s -L %s -L %s"
el-get-emacs
(concat (file-name-as-directory el-get-dir) "avy")
(concat (file-name-as-directory el-get-dir) "hydra"))
"compile")
("gmakeinfo" "-o" "doc/ivy.info" "doc/ivy.texi"))
:info "doc/ivy.info")
23 changes: 3 additions & 20 deletions test/github-actions.sh
Original file line number Diff line number Diff line change
@@ -1,27 +1,10 @@
# source me
# Define the following functions here to keep .github/workflows/test.yml nice and tidy
# - prereqs()
# - byte-compile()
# - check-recipes()
# - 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')
Expand Down Expand Up @@ -70,7 +53,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] <files>...
Expand All @@ -80,12 +63,12 @@ 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 "$@"
}

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

0 comments on commit ee3b8ef

Please sign in to comment.