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

fix: sources brace expansion #2075

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

pd93
Copy link
Member

@pd93 pd93 commented Feb 19, 2025

Fixes #2073

Removes zglob as a dependency and instead relies on mvdan's expand.Fields with globbing turned on for sources globs.

We also use expand.Fields in multiple other places to resolve things like ~ and environment variables. However, most of the time, we don't also want brace expansion or globbing, so I have separated this into two functions. One wraps expand.Literal which returns a single string with just the variables resolved, and the other wraps expand.Fields with braces and globbing enabled.

@pd93 pd93 force-pushed the 2073-fix-sources-brace-expansion branch 2 times, most recently from 12df237 to 2a1e9da Compare February 24, 2025 11:06
@pd93 pd93 marked this pull request as ready for review February 25, 2025 10:39
@pd93 pd93 marked this pull request as draft February 25, 2025 10:50
@pd93 pd93 force-pushed the 2073-fix-sources-brace-expansion branch from 2a1e9da to 0c25845 Compare February 25, 2025 14:23
@pd93 pd93 marked this pull request as ready for review February 25, 2025 14:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Using glob curly braces expansion in sources prevents change detection for some files
1 participant