projects/guix·blob java-team · refs

66 lines · 1.8 KiB

1From 5396f4d6312b24eac79da2f70279df773443fd10 Mon Sep 17 00:00:00 2001
2From: Nicolas Graves <[email protected]>
3Date: Wed, 19 Mar 2025 13:02:47 +0100
4Subject: [PATCH] Replace git.
5
6---
7 makem.sh | 34 +++++-----------------------------
8 1 file changed, 5 insertions(+), 29 deletions(-)
9
10diff --git a/makem.sh b/makem.sh
11index fd81e0f..4ec9577 100755
12--- a/makem.sh
13+++ b/makem.sh
14@@ -385,34 +385,13 @@ function byte-compile-file {
15
16 # ** Files
17
18-function submodules {
19- # Echo a list of submodules's paths relative to the repo root.
20- # TODO: Parse with bash regexp instead of cut.
21- git submodule status | awk '{print $2}'
22-}
23-
24-function project-root {
25- # Echo the root of the project (or superproject, if running from
26- # within a submodule).
27- root_dir=$(git rev-parse --show-superproject-working-tree)
28- [[ $root_dir ]] || root_dir=$(git rev-parse --show-toplevel)
29- [[ $root_dir ]] || error "Can't find repo root."
30-
31- echo "$root_dir"
32-}
33-
34 function files-project {
35 # Echo a list of files in project; or with $1, files in it
36- # matching that pattern with "git ls-files". Excludes submodules.
37- [[ $1 ]] && pattern="/$1" || pattern="."
38-
39- local excludes
40- for submodule in $(submodules)
41- do
42- excludes+=(":!:$submodule")
43- done
44-
45- git ls-files -- "$pattern" "${excludes[@]}"
46+ # matching that pattern with "find".
47+ if [[ $1 ]]
48+ then find . -type f -name "$1" | sed 's|^\./||'
49+ else find . -type f | sed 's|^\./||'
50+ fi
51 }
52
53 function dirs-project {
54@@ -1223,9 +1202,6 @@ paths_temp+=("$package_initialize_file")
55
56 trap cleanup EXIT INT TERM
57
58-# Change to project root directory first.
59-cd "$(project-root)"
60-
61 # Discover project files.
62 files_project_feature=($(files-project-feature))
63 files_project_test=($(files-project-test))
64--
652.48.1
66