Skip to content

Commit 8b57f20

Browse files
committed
Fix GitHub Actions build on macOS
- Install gnu getopt - Replace egrep with grep -E (not necessary?) - Try explicitly setting excludes to an array Otherwise, if it is unset, it appears that (at least on macos), the following expands to an empty string argument rather than no arguments: "${excludes[@]}"
1 parent b2ff017 commit 8b57f20

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ jobs:
5858
- name: Byte compilation
5959
run: emacs --eval "(setq byte-compile-error-on-warn (>= emacs-major-version 26))" -L . --batch -f batch-byte-compile ./*.el
6060
- name: Tests
61-
run: nix shell ${{ matrix.ledger_version || 'nixpkgs#ledger' }} --print-build-logs -c ./makem.sh test -vv
61+
run: nix shell 'nixpkgs#getopt' ${{ matrix.ledger_version || 'nixpkgs#ledger' }} --print-build-logs -c ./makem.sh test -vv
6262
# This is currently for information only, since a lot of docstrings need fixing up
6363
- name: Checkdoc
6464
run: make lint-checkdoc || true

makem.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -406,7 +406,7 @@ function files-project {
406406
# matching that pattern with "git ls-files". Excludes submodules.
407407
[[ $1 ]] && pattern="/$1" || pattern="."
408408
409-
local excludes
409+
local excludes=()
410410
for submodule in $(submodules)
411411
do
412412
excludes+=(":!:$submodule")
@@ -424,7 +424,7 @@ function dirs-project {
424424
function files-project-elisp {
425425
# Echo list of Elisp files in project.
426426
files-project 2>/dev/null \
427-
| egrep "\.el$" \
427+
| grep -E "\.el$" \
428428
| filter-files-exclude-default \
429429
| filter-files-exclude-args
430430
}

0 commit comments

Comments
 (0)