Meta: Update makem.sh
This commit is contained in:
parent
881d298cd0
commit
ca03ad0d4a
1 changed files with 33 additions and 6 deletions
37
makem.sh
37
makem.sh
|
|
@ -60,6 +60,7 @@ Rules:
|
|||
lint-checkdoc Run checkdoc.
|
||||
lint-compile Byte-compile source files with warnings as errors.
|
||||
lint-declare Run check-declare.
|
||||
lint-elsa Run Elsa (not included in "lint" rule).
|
||||
lint-indent Lint indentation.
|
||||
lint-package Run package-lint.
|
||||
lint-regexps Run relint.
|
||||
|
|
@ -478,7 +479,9 @@ function sandbox {
|
|||
then
|
||||
debug "Installing linters: package-lint relint"
|
||||
|
||||
args_sandbox_package_install+=(--eval "(package-install 'package-lint)"
|
||||
args_sandbox_package_install+=(
|
||||
--eval "(package-install 'elsa)"
|
||||
--eval "(package-install 'package-lint)"
|
||||
--eval "(package-install 'relint)")
|
||||
fi
|
||||
|
||||
|
|
@ -671,8 +674,9 @@ function compile {
|
|||
}
|
||||
|
||||
function batch {
|
||||
# Run Emacs with $args_batch and with project source and test files loaded.
|
||||
verbose 1 "Executing Emacs with arguments: ${args_batch[@]}"
|
||||
# Run Emacs in batch mode with ${args_batch_interactive[@]} and
|
||||
# with project source and test files loaded.
|
||||
verbose 1 "Executing Emacs with arguments: ${args_batch_interactive[@]}"
|
||||
|
||||
run_emacs \
|
||||
$(args-load-files "${files_project_feature[@]}" "${files_project_test[@]}") \
|
||||
|
|
@ -681,6 +685,9 @@ function batch {
|
|||
|
||||
function interactive {
|
||||
# Run Emacs interactively. Most useful with --sandbox and --install-deps.
|
||||
verbose 1 "Running Emacs interactively..."
|
||||
verbose 2 "Loading files:" "${files_project_feature[@]}" "${files_project_test[@]}"
|
||||
|
||||
unset arg_batch
|
||||
run_emacs \
|
||||
$(args-load-files "${files_project_feature[@]}" "${files_project_test[@]}") \
|
||||
|
|
@ -737,6 +744,20 @@ function lint-declare {
|
|||
|| error "Linting declarations failed."
|
||||
}
|
||||
|
||||
function lint-elsa {
|
||||
verbose 1 "Linting with Elsa..."
|
||||
|
||||
# MAYBE: Install Elsa here rather than in sandbox init, to avoid installing
|
||||
# it when not needed. However, we should be careful to be clear about when
|
||||
# packages are installed, because installing them does execute code.
|
||||
run_emacs \
|
||||
--load elsa \
|
||||
-f elsa-run-files-and-exit \
|
||||
"${files_project_feature[@]}" \
|
||||
&& success "Linting with Elsa finished without errors." \
|
||||
|| error "Linting with Elsa failed."
|
||||
}
|
||||
|
||||
function lint-indent {
|
||||
verbose 1 "Linting indentation..."
|
||||
|
||||
|
|
@ -952,8 +973,7 @@ do
|
|||
;;
|
||||
-f|--file)
|
||||
shift
|
||||
project_source_files+=("$1")
|
||||
project_byte_compile_files+=("$1")
|
||||
args_files+=("$1")
|
||||
;;
|
||||
-O|--no-org-repo)
|
||||
unset elisp_org_package_archive
|
||||
|
|
@ -991,6 +1011,13 @@ files_project_feature=($(files-project-feature))
|
|||
files_project_test=($(files-project-test))
|
||||
files_project_byte_compile=("${files_project_feature[@]}" "${files_project_test[@]}")
|
||||
|
||||
if [[ ${args_files[@]} ]]
|
||||
then
|
||||
# Add specified files.
|
||||
files_project_feature+=("${args_files[@]}")
|
||||
files_project_byte_compile+=("${args_files[@]}")
|
||||
fi
|
||||
|
||||
debug "EXCLUDING FILES: ${files_exclude[@]}"
|
||||
debug "FEATURE FILES: ${files_project_feature[@]}"
|
||||
debug "TEST FILES: ${files_project_test[@]}"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue