Rename repo_root to workspace_root

This seems like a slightly better term
because I think it also applies to tarball.
Ref: https://github.com/fish-shell/fish-shell/pull/11785#discussion_r2335280389
This commit is contained in:
Johannes Altmanninger
2025-09-13 10:18:32 +02:00
parent 33735f507a
commit 27db0e5fed
8 changed files with 21 additions and 21 deletions

View File

@@ -34,13 +34,13 @@ if $lint; then
export RUSTDOCFLAGS="--deny=warnings ${RUSTDOCFLAGS}"
fi
repo_root="$(dirname "$0")/.."
build_dir="${CARGO_TARGET_DIR:-$repo_root/target}/${target_triple}/debug"
workspace_root="$(dirname "$0")/.."
build_dir="${CARGO_TARGET_DIR:-$workspace_root/target}/${target_triple}/debug"
template_file=$(mktemp)
FISH_GETTEXT_EXTRACTION_FILE=$template_file cargo build --workspace --all-targets --features=gettext-extract
if $lint; then
PATH="$build_dir:$PATH" "$repo_root/build_tools/style.fish" --all --check
PATH="$build_dir:$PATH" "$workspace_root/build_tools/style.fish" --all --check
for features in "" --no-default-features; do
cargo clippy --workspace --all-targets $features
done
@@ -50,7 +50,7 @@ cargo test --doc --workspace
if $lint; then
cargo doc --workspace
fi
FISH_GETTEXT_EXTRACTION_FILE=$template_file "$repo_root/tests/test_driver.py" "$build_dir"
FISH_GETTEXT_EXTRACTION_FILE=$template_file "$workspace_root/tests/test_driver.py" "$build_dir"
exit
}

View File

@@ -19,7 +19,7 @@ begin
echo ""
end
set -g repo_root (status dirname)/..
set -g workspace_root (status dirname)/..
set -l rust_extraction_file
if set -l --query _flag_use_existing_template
@@ -66,7 +66,7 @@ begin
sed -E -e 's_\\\\_\\\\\\\\_g' -e 's_"_\\\\"_g' -e 's_^(.*)$_msgid "\1"\nmsgstr ""\n_'
end
set -g share_dir $repo_root/share
set -g share_dir $workspace_root/share
# This regex handles explicit requests to translate a message. These are more important to translate
# than messages which should be implicitly translated.

View File

@@ -24,7 +24,7 @@ if set -l -q _flag_all
end
end
set -l repo_root (status dirname)/..
set -l workspace_root (status dirname)/..
if test $all = yes
if not set -l -q _flag_force; and not set -l -q _flag_check
@@ -43,7 +43,7 @@ if test $all = yes
end
end
end
set fish_files $repo_root/{benchmarks,build_tools,etc,share}/**.fish
set fish_files $workspace_root/{benchmarks,build_tools,etc,share}/**.fish
set python_files {doc_src,share,tests}/**.py
else
# Format the files specified as arguments.

View File

@@ -6,7 +6,7 @@
# updates the PO files for each language from that
# (changed line numbers, added messages, removed messages),
# and finally generates a machine-readable MO file for each language,
# which is stored in share/locale/$LANG/LC_MESSAGES/fish.mo (relative to the repo root).
# which is stored in share/locale/$LANG/LC_MESSAGES/fish.mo (relative to the workspace root).
#
# Use cases:
# For developers: