question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Need mechanism to disable globbing

See original GitHub issue

Globbing support on Linux has caused us to have to revert to using bash scripts because we can’t pass parameters that contain * through to the executable. In this case, we are trying to invoke a C++ pkg manager called conan. It would be nice to have an option like set -o noglob in bash to disable globbing.

Steps to reproduce

Try to execute conan (or echoargs) with:

conan info --only "None" --package_filter 'PkgName/*' --cwd ../..

Note: I’ve tried quoting the arg and escaping the *. Neither works with conan.

Expected behavior

The PkgName/* gets passed through to conan,

Actual behavior

This generates an error:

Cannot find path '/home/hillr/code/dotnet/echoargs/bin/Debug/netcoreapp2.0/PkgName' because it does not exist.
At line:1 char:1
+ dotnet ./echoargs.dll info --only "None" --package_filter PkgName/* - ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (/home/hillr/cod...eapp2.0/PkgName:String) [], ItemNotFoundException
    + FullyQualifiedErrorId : PathNotFound

Environment data

> $PSVersionTable
Name                           Value
----                           -----
PSVersion                      6.0.0-beta.8
PSEdition                      Core
GitCommitId                    v6.0.0-beta.8
OS                             Linux 4.4.0-43-Microsoft #1-Microsoft Wed Dec 31 14:42:53 PST 2014
Platform                       Unix
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1
WSManStackVersion              3.0

Related issues: #3931 #4971 #4683 and PR #4489

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:3
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
rkeithhillcommented, Oct 2, 2019

It does and that is what I’ve been using for a while now on Linux.

0reactions
SteveL-MSFTcommented, Oct 2, 2019

@rkeithhill let me know if #5188 doesn’t resolve your issue

Read more comments on GitHub >

github_iconTop Results From Across the Web

bash - How to turn globbing on and off?
If you want globs to be disabled only while the shell is interpreting code in any.sh , with bash4.4+ or ash -based shells,...
Read more >
Command substitution in shell script without globbing
One solution I have come up with is to disable globbing with set -o noglob just before the command substitution. Here is the...
Read more >
Shell Wildcards and Globbing
To enable it, the following command needs to be executed: shopt -s extglob . There are a few more advanced shell glob expressions,...
Read more >
Thread: [Mingw-users] Shell globbing when running ...
What I'm looking for is a way to disable globbing > > temporarily at run time, so I could do that for the...
Read more >
Filenames and Pathnames in Shell: How to do it Correctly
POSIX includes various portable mechanisms to disable and re-enable file globbing in shell. The “set -f” command disables file globbing.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found