Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

common/environment/setup/install.sh: fix v* funcs for paths with spaces #48676

Merged
merged 1 commit into from
Jun 14, 2024

Conversation

classabbyamp
Copy link
Member

@classabbyamp classabbyamp commented Feb 12, 2024

also quote, fix tabs, and shellcheck the file

revival of #42850

re: @Chocimier's comment:

How about pushing setting IFS down to cp call? We may need word splitting later on for vsv's LN_OPTS.

this does not work, it still splits the arguments if done at that level. also, LN_OPTS is a single word (either -s or -sf).

Testing the changes

  • I tested the changes in this PR: YES

can be tested with, e.g.:

diff --git a/srcpkgs/chezmoi/template b/srcpkgs/chezmoi/template
index 1b5d674c14a..50e5b113e0a 100644
--- a/srcpkgs/chezmoi/template
+++ b/srcpkgs/chezmoi/template
@@ -21,6 +21,9 @@ pre_build() {
                _date="$(date --utc --date "@$SOURCE_DATE_EPOCH" "+%Y-%m-%d")"
                go_ldflags+=" -X main.date=${_date}"
        fi
+       mkdir "foo bar"
+       for i in 1 2 3 4 5; do touch "foo bar/idk$i.bleh"; done
+       for i in 1 2 3 4 5; do touch "foo bar/ok$i.bleh"; done
 }
 
 do_check() {
@@ -28,8 +31,16 @@ do_check() {
 }
 
 post_install() {
+       vmkdir "foo bar"
+       vcopy "foo bar/*.bleh" "foo bar"
        vlicense LICENSE
        vcompletion completions/chezmoi-completion.bash bash
        vcompletion completions/chezmoi.fish fish
        vcompletion completions/chezmoi.zsh zsh
 }
+
+chezmoi-stuff_package() {
+       pkg_install() {
+               vmove "foo bar/ok*"
+       }
+}

@classabbyamp classabbyamp added the xbps-src xbps-src related label Feb 12, 2024
Copy link

Pull Requests become stale 90 days after last activity and are closed 14 days after that. If this pull request is still relevant bump it or assign it.

@github-actions github-actions bot added the Stale label May 13, 2024
@abenson abenson merged commit 91367b5 into void-linux:master Jun 14, 2024
@classabbyamp classabbyamp deleted the mr-globby branch June 14, 2024 03:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
xbps-src xbps-src related
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants