On 04/27/2014 02:06 PM, Carlos E. R. wrote:
On 2014-04-27 18:30, Anton Aylward wrote:
On 04/27/2014 11:12 AM, Carlos E. R. wrote:
[...]
I see. Interesting.
That gave me an idea of another part of the script, but I failed:
cer@Telcontar:~> grep Bourne-Again "$(head -c 1000 bin/0_script_constructs | File -)" grep: /dev/stdin: Bourne-Again shell script, UTF-8 Unicode text executable: No such file or directory cer@Telcontar:~>
The intention here was for grep to locate the string "Bourne-Again" on the output text of the subshell. But it does not do that, it interprets it as the file(s) to look inside.
Of course it fails! Check the man page for grep. In that usage it take a list of files. What you subshell is producing is a texzt stream What you meant was head -c 1000 bin/0_script_constructs | File - | Grep Bourne-Again No need for an embedded subshell.
But this seems to be exactly what you want http://www.liamdelahunty.com/tips/linux_find_exclude_multiple_directories.ph...
It is indeed. I'm using now:
find "$DONDE" -type f \ -prune -o -path '/var/spool/news' \ -prune -o -path '/var/run/udev/links' \ -prune -o -path '/var/run/user' \ -prune -o -path '/var/run/systemd' \ -prune -o -path '/var/lib/ntp/proc' \ -prune -o -path '/proc' \ -prune -o -path '/run/udev/links' \ > $LISTADO_FIND
which is exactly what I wanted :-)
-- "The capacity to learn is a gift; The ability to learn is a skill; The willingness to learn is a choice." -- Brain Herbert, -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org