feat: add CI
CI / build (26.3) (push) Successful in 3m7s Details
CI / build (27.2) (push) Successful in 3m55s Details
CI / build (28.2) (push) Successful in 3m32s Details
CI / build (29.1) (push) Successful in 3m39s Details
CI / build (snapshot) (push) Successful in 2m50s Details

This commit is contained in:
Lucien Cartier-Tilet 2023-12-06 19:49:59 +01:00
parent 9942e063b3
commit 49b6ca3efe
Signed by: phundrak
GPG Key ID: BD7789E705CB8DCA
5 changed files with 106 additions and 9 deletions

45
.gitea/workflows/test.yml Normal file
View File

@ -0,0 +1,45 @@
name: CI
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
emacs_version:
- 26.3
- 27.2
- 28.2
- 29.1
- snapshot
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
id: cache-nix-conf
with:
path: /etc/nix
key: cache-nix-conf-000
- uses: actions/cache@v3
id: cache-nix-packages
with:
path: /nix
key: cache-nix-packages-000
- uses: purcell/setup-emacs@master
with:
version: ${{ matrix.emacs_version }}
- uses: actions/cache@v3
id: cache-eask-packages
with:
path: .eask
key: cache-eask-packages-000
- uses: emacs-eask/setup-eask@master
with:
version: 'snapshot'
- name: "Execute Eask CI"
run: make ci

3
.gitignore vendored Normal file
View File

@ -0,0 +1,3 @@
/.eask/
/dist/
*.elc

14
Eask Normal file
View File

@ -0,0 +1,14 @@
(package "quick-find-files"
"0.2.1"
"Quickly find files in directories and by extension")
(website-url "https://labs.phundrak.com/phundrak/quick-find-files.el")
(keywords "convenience")
(package-file "quick-find-files.el")
(script "test" "echo \"Error: no test specified\" && exit 1")
(source "gnu")
(depends-on "emacs" "26.1")

34
Makefile Normal file
View File

@ -0,0 +1,34 @@
EMACS ?= emacs
EASK ?= eask
.PHONY: clean package install compile test checkdoc lint
ci: clean package install compile checkdoc lint
package:
@echo "Packaging..."
$(EASK) package
install:
@echo "Installing..."
$(EASK) install
compile:
@echo "Compiling..."
$(EASK) compile
test:
@echo "Testing..."
$(EASK) install-deps --dev
$(EASK) test ert ./test/*.el
checkdoc:
@echo "Checking documentation..."
$(EASK) lint checkdoc --strict
lint:
@echo "Linting..."
$(EASK) lint package
clean:
$(EASK) clean all

View File

@ -2,9 +2,10 @@
;; Author: Lucien Cartier-Tilet <lucien@phundrak.com>
;; Maintainer: Lucien Cartier-Tilet <lucien@phundrak.com>
;; Version: 0.1.0
;; Package-Requires: ((emacs "24"))
;; Version: 0.2.1
;; Package-Requires: ((emacs "26"))
;; Homepage: https://labs.phundrak.com/phundrak/quick-find-files.el
;; Keywords: convenience
;; This file is not part of GNU Emacs
@ -48,8 +49,8 @@
'find)
"Program to find files on your system.
By default, the value is 'fd, but you can change it to 'find too.
For now, no other program is supported.
By default, the value is \\='fd, but you can change it to
\\='find too. For now, no other program is supported.
By default, `quick-find-files' will try to find fd or find in
your path. You can customize the executable to use with
@ -75,18 +76,18 @@ your path. You can customize the executable to use with
Each element should be a pair of a directory path and an
extension, such as
'((\"~/Documents/org/\" . \"org\"))"
\\='((\"~/Documents/org/\" . \"org\"))"
:group 'quick-find-files
:type 'list)
(defcustom quick-find-files-fd-additional-options ""
"Additional command-line options for fd."
"Additional command line options for fd."
:group 'quick-find-files
:type 'string
:safe #'stringp)
(defcustom quick-find-files-find-additional-options ""
"Additional command-line options for find."
"Additional command line options for find."
:group 'quick-find-files
:type 'string)
@ -95,7 +96,8 @@ extension, such as
The function must accept a prompt as its first argument and the
collection of elements to choose from as its second argument."
:group 'quick-find-files)
:group 'quick-find-files
:type 'function)
; Internal functions ;;;;;;;;;;;;;;;;;;
@ -157,7 +159,6 @@ user for the root directory of their search and the file
extention they are looking for. When the file extension is left
empty, all files are to be looked for."
(interactive "P")
(message "qff prefix: %S" arg)
(let (dir ext)
(when arg
(setq dir (read-file-name "Root directory: "))