New answers tagged gnu
This was unnecessarily disruptive and was reverted for >= coreutils-8.7 Since then you need to specify %.Y etc to get the fractional part included
The special handling of \s was added in grep 2.6.3. Commit message Whenever possible, use the info docs that are on your system. Just run info grep. To get this behavior, try adding the -P flag to make it work in Perl regex mode.
I could reproduce your issue with GNU grep v2.5.1. However, when I use -i switch it worked: grep -i 'hello\sworld' file From the man page: -i, --ignore-case Ignore case distinctions in both the PATTERN and the input files. It might be a bug in grep.
You should use "" instead of '' : grep "hello\sworld" file When you use '' grep discardes scape codes.
The [ is always given as an equivalent to test, but I had'nt seen the ] mentioned explicitly, although it is always there. I have just now found this in http://ss64.com/bash/test.html : When the [ form is used, the last argument to the command must be a ] which is reassuring -- at last I have completion as they say.
Run tmux tmux Go to the command mode in your tmux session: ctrlB then : Then split a new window with a command associated. split-window -d 'exec sx -b /tmp/file' Option -d is optional, it is to detach from the new pane and to return to the first. That will works with new-window command too. CtrlB then o will switch from one pane to the ...
The [ command is the same as the test command. It allows you to write rather terse conditional statements in shell scripts. From the SunOS manual page: if [ "$1" = "pear" ] || [ "$1" = "grape" ] || [ "$1" = "apple" ] then command fi If you remove it, scripts will break!
The [ binary residing under the /bin tree in many GNU/Linux distributions is not something to be alarmed off. At least in my Fedora 19 it is a part of the coreutils package, as demonstrated below: $ rpm -qf /bin/[ coreutils-8.21-13.fc19.x86_64 and is a synonym for test to allow for expressions like [ expression ] to be written in shell scripts or even ...
Top 50 recent answers are included