29 votes

Is pipe ( | ) a command?

In Bash a pipe (| along with |&) is not a command, rather it is a control operator. From this reference: A pipeline is a sequence of one or more commands separated by one of the control operators ...
  • 6,932
1 vote

Not finding folders in bash script with use of asterix

You are expecting na* will expand to several names, but as far as I know the -d test accepts a single argument. Moreover, as pointed out in the other answer no expansion occurs inside [[ ]]. A ...
  • 507
1 vote
Accepted

How do I use xargs to pass arguments as $1, $2, $3, ... to an inline script called with sh -c?

First of all, you don't do sh -c "echo $1 - $2 - $3" because the double-quotes will cause your current shell to expand $1, $2 and $3. Even if you managed to set these in the current shell ...
1 vote
Accepted

Toggling values for Preferred Band for Wi-Fi card on Windows - can I automate it using Powershell?

In Powershell, you can get a list of all the advanced properties by running: Get-NetAdapterAdvancedProperty -Name "*" This will return all the settings that you are able to see in the above ...
  • 3,016
1 vote

Equivalent to ^D (in bash) for cmd.exe?

In Windows 10 using the old conhost.exe terminal the equivalent is Alt+F4! The option is controlled by the registry key AllowAltF4Close and is enabled by default. See Command prompt in Windows 10 can ...
  • 24k

Only top scored, non community-wiki answers of a minimum length are eligible