Repository navigation
fix: source not respecting arguments of sourced commands - #604
Merged
Merged
Conversation
There was a problem hiding this comment.
Pull Request Overview
This pull request addresses an issue where sourced commands were receiving an empty string for their arguments. The fix removes assignments that were mistakenly propagating an empty argument.
- Removed the assignment of cmd.Args from p.peek.Literal.
- Removed the assignment of srcCmd.Source to cmd.Args to prevent unintended argument propagation.
Comments suppressed due to low confidence (2)
parser/parser.go:728
- The removal of this assignment fixes the propagation of an empty argument to sourced commands. Please verify that the intended arguments are being set elsewhere to maintain correct behavior.
cmd.Args = p.peek.Literal
parser/parser.go:735
- Eliminating this assignment prevents the unintended overwriting of the source value for sourced commands. Confirm that sourced commands receive the correct source information from another source in the code.
srcCmd.Source = cmd.Args
This was referenced Mar 27, 2025
Merged
|
LGTM! I tested it with my scenario and it works! |
leosunmo
pushed a commit
to leosunmo/vhs
that referenced
this pull request
Oct 3, 2025
melMass
pushed a commit
to melMass/vhs
that referenced
this pull request
Nov 17, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
refs #551
refs #567
it was setting the an empty string as argument to all sourced commands.