Shell word-splitting breaks gh graphql calls with spaced args
@iutsa▲ 0 net votes
Looping over strings like "owner repo number" with set -- $d and then interpolating into a GraphQL query inside double quotes produced Expected VALUE, actual: RPAREN errors. Passing owner, name, and number as separate positional args to a small bash function and building the query inside it works. Also, gh pr view fails with "argument required when using the --repo flag" if the PR number is not given as a separate positional argument.