mirror of
https://github.com/asdf-vm/asdf.git
synced 2024-11-15 01:28:17 -07:00
fix: Remove unecessary backslashes (#1384)
This commit is contained in:
parent
ec972cbdf0
commit
15faf93a0d
@ -365,7 +365,7 @@ get_asdf_config_value_from_file() {
|
||||
fi
|
||||
|
||||
local result
|
||||
result=$(grep -E "^\\s*$key\\s*=\\s*" "$config_path" | head | sed -e 's/^[^=]*= *//' -e 's/^[[:space:]]*//' -e 's/[[:space:]]*$//')
|
||||
result=$(grep -E "^\s*$key\s*=\s*" "$config_path" | head | sed -e 's/^[^=]*= *//' -e 's/^[[:space:]]*//' -e 's/[[:space:]]*$//')
|
||||
if [ -n "$result" ]; then
|
||||
printf "%s\\n" "$result"
|
||||
return 0
|
||||
|
@ -3,4 +3,4 @@
|
||||
set -euo pipefail
|
||||
|
||||
version=$(cat version.txt)
|
||||
sed -i "s/\\(git clone.*--branch \\).*\\(\`.*|\\)/\\1v$version\\2/" docs/guide/getting-started.md
|
||||
sed -i "s/\(git clone.*--branch \).*\(\`.*|\)/\1v$version\2/" docs/guide/getting-started.md
|
||||
|
@ -8,5 +8,5 @@ version_major_minor_x="$(cut -f1-2 -d "." version.txt).x"
|
||||
if ! grep -q "$version_major_minor_x" SECURITY.md; then
|
||||
# prepend new version to the list
|
||||
sed -i "s/white_check_mark:/x: /g" SECURITY.md
|
||||
sed -i "s/^\\(| -* | -* |\\)$/\\1\\n| $version_major_minor_x | :white_check_mark: |/" SECURITY.md
|
||||
sed -i "s/^\(| -* | -* |\)$/\1\n| $version_major_minor_x | :white_check_mark: |/" SECURITY.md
|
||||
fi
|
||||
|
2
test/fixtures/dummy_plugin/bin/latest-stable
vendored
2
test/fixtures/dummy_plugin/bin/latest-stable
vendored
@ -4,7 +4,7 @@ get_latest_stable() {
|
||||
query=$1
|
||||
|
||||
version_list=(1.0.0 1.1.0 2.0.0)
|
||||
printf "%s\n" "${version_list[@]}" | grep -E "^\\s*$query" | tail -1
|
||||
printf "%s\n" "${version_list[@]}" | grep -E "^\s*$query" | tail -1
|
||||
}
|
||||
|
||||
get_latest_stable "$1"
|
||||
|
Loading…
Reference in New Issue
Block a user