66,291 reputation
864147
bio website
location European Union
age
visits member for 1 years, 8 months
seen 10 hours ago

Apr
17
comment Get bash DEBUG trap to execute only once for and/or lists?
Sounds like you want the equivalent of zsh's preexec() hook.
Apr
17
answered Seperate messages of multiple sshds in syslog-ng
Apr
17
comment Is there a one liner which can list public key fingerprints with authorised_keys as input?
That doesn't work, -f expects a file name (and that file has to be a regular file as ssh-keygen opens and reads the file several times)
Apr
17
comment Want to replace the words with space in multiple files using SED commmand
@danny, use -i (GNU sed) or -i '' (FreeBSD, OS/X) if you want in-place editing but no backup.
Apr
17
comment Find “.git” dirs but ignore some paths; or how does `find -not` work
-path '*/old' is the same as -name old
Apr
17
revised Find “.git” dirs but ignore some paths; or how does `find -not` work
added 18 characters in body
Apr
17
comment Find “.git” dirs but ignore some paths; or how does `find -not` work
That still descends into the old directories, you may want to use -prune here to avoid that.
Apr
17
revised Find “.git” dirs but ignore some paths; or how does `find -not` work
added 6 characters in body
Apr
17
revised Want to replace the words with space in multiple files using SED commmand
added 72 characters in body
Apr
17
comment Want to replace the words with space in multiple files using SED commmand
@Danny, note that the .php files are the backup files (the original) the modified ones are the files themselves.
Apr
17
revised Want to replace the words with space in multiple files using SED commmand
added 5 characters in body
Apr
17
answered Want to replace the words with space in multiple files using SED commmand
Apr
17
comment Perform filename expansion on $@
If (wild guess) what you want is absolute paths of those of the positional parameters that are non-empty directories, then that'd be something like $^@(NF:a)
Apr
17
revised `ls -l` of a file and all the directories leading to it?
added 178 characters in body
Apr
17
answered `ls -l` of a file and all the directories leading to it?
Apr
8
comment Why is this OSX/BSD/GNU sed workaround not working
Or if "$darwin"; then sedi() { sed -i '' "$@"; }...
Apr
5
comment How to make bidirectional pipe between two programs?
If you make it prog2 < fifo0 > fifo1, you can avoid your little dance with exec 30< ... (which by the way only works with bash or yash for fds over 10 like that).
Apr
4
comment Which is the most portable of sed, awk, perl and sh?
You may have them, but what they do will vary across systems, so the question does not make much sense as it is stated.
Apr
3
comment Bash script error: integer expression expected
However, to check against thresholds, you don't want to round up. 49.6 should still be OK if the warning threshold is 50. So result=$(( 100 * $used / $total )) should be just fine.
Apr
3
revised Delete *.txt files by date between MMDDYYYY and MMDDYYYYY
added 27 characters in body