Hi Keith!
Thanks for trying out xonsh! Now as per your question...
You should be able to pipe commands together like you would in bash. Is this not working for you for some reason? Do you have a full and complete command that is breaking that you can share, along with the error message?
Be Well
Anthony
--
You received this message because you are subscribed to the Google Groups "xonsh" group.
To unsubscribe from this group and stop receiving emails from it, send an email to xonsh+un...@googlegroups.com.
To post to this group, send email to xo...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/xonsh/30123083-b359-4685-a084-d1f8b93e2f84%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Asst. Prof. Anthony Scopatz
Nuclear Engineering Program
Mechanical Engineering Dept.
University of South Carolina
sco...@cec.sc.edu
Office: (803) 777-9334
Cell: (512) 827-8239
Office: Horizon 1, #011 (ground floor, not first)
Book a meeting with me at https://scopatz.youcanbook.me/
Open up an issue: https://github.com/scopatz/me/issues
Check my calendar
--
You received this message because you are subscribed to the Google Groups "xonsh" group.
To unsubscribe from this group and stop receiving emails from it, send an email to xonsh+un...@googlegroups.com.
To post to this group, send email to xo...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/xonsh/CALD07fx9N3FtuU3chXAG4Jy4gmftfQxUDj_XQ205WU4c%3DPra0Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Hi Keith,Why not just type in:>>> grep -w root /opt/home.txt | sed -e 's|/home||g' | cut -f 2 | sudo -su root rsync -a --files-from=- /home /mnt/archive/homeI don't think that you should be using @(cmd) here. That takes a Python object and converts it to a string for a command line argument. It is meant for passing Python objects into the command. The second case with @(cmd.split()) is more correct, and it is weird that it isn't finding grep. However, you *are* circumventing $PATH lookup. I bet if you used abspaths for all of the commands it might work.In any event, you should type in the command normally. Let us know how it goes!Be WellAnthony
On Tue, Dec 19, 2017 at 9:49 AM Keith Gunderson <kegu...@gmail.com> wrote:
Hi Anthony.Here's what I'm seeing:>>> cmd_sample"grep -w root /opt/home.txt | sed -e 's|/home||g' | cut -f 2 | sudo -su root rsync -a --files-from=- /home /mnt/archive/home">>> @(cmd_sample)xonsh: subprocess mode: command not found: grep -w root /opt/home.txt | sed -e 's|/home||g' | cut -f 2 | sudo -su root rsync -a --files-from=- /home /mnt/archive/home>>> @(cmd_sample.split())grep: 2: No such file or directoryThanks so much,Keith
--
You received this message because you are subscribed to the Google Groups "xonsh" group.
To unsubscribe from this group and stop receiving emails from it, send an email to xonsh+unsubscribe@googlegroups.com.
To post to this group, send email to xo...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/xonsh/CALD07fx9N3FtuU3chXAG4Jy4gmftfQxUDj_XQ205WU4c%3DPra0Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
To unsubscribe from this group and stop receiving emails from it, send an email to xonsh+un...@googlegroups.com.
To post to this group, send email to xo...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/xonsh/CALD07fx9N3FtuU3chXAG4Jy4gmftfQxUDj_XQ205WU4c%3DPra0Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
--Asst. Prof. Anthony Scopatz
Nuclear Engineering Program
Mechanical Engineering Dept.
University of South Carolina
sco...@cec.sc.edu
Office: (803) 777-9334
Cell: (512) 827-8239
Office: Horizon 1, #011 (ground floor, not first)
Book a meeting with me at https://scopatz.youcanbook.me/
Open up an issue: https://github.com/scopatz/me/issues
Check my calendar
--
You received this message because you are subscribed to the Google Groups "xonsh" group.
To unsubscribe from this group and stop receiving emails from it, send an email to xonsh+un...@googlegroups.com.
To post to this group, send email to xo...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/xonsh/CALD07fwNwQS-uMpb%3D59bcbjwC-2VK79FT%3Daq%2BYUhfSDFNWfdbA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
To unsubscribe from this group and stop receiving emails from it, send an email to xonsh+unsubscribe@googlegroups.com.
To post to this group, send email to xo...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/xonsh/CALD07fx9N3FtuU3chXAG4Jy4gmftfQxUDj_XQ205WU4c%3DPra0Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
--Asst. Prof. Anthony Scopatz
Nuclear Engineering Program
Mechanical Engineering Dept.
University of South Carolina
sco...@cec.sc.edu
Office: (803) 777-9334
Cell: (512) 827-8239
Office: Horizon 1, #011 (ground floor, not first)
Book a meeting with me at https://scopatz.youcanbook.me/
Open up an issue: https://github.com/scopatz/me/issues
Check my calendar
--
You received this message because you are subscribed to the Google Groups "xonsh" group.
To unsubscribe from this group and stop receiving emails from it, send an email to xonsh+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/xonsh/CALD07fwNwQS-uMpb%3D59bcbjwC-2VK79FT%3Daq%2BYUhfSDFNWfdbA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
0 seq.
1 open('/tmp/foo').
2 filter(lambda x: 'grep grep' not in x).
3 map(lambda x: x.split('|')).
4 map(lambda x: [len(x), x]).
5 filter(lambda x: x[0]>6).
6 map(lambda x: x[1]).
7 map(lambda x: seq(x).map(
lambda x: x.partition(' ')[0].strip()
) ).
8 flatten().
9 sorted ().
10 distinct()
1 '/tmp/foo'
2 filter 'bar' in x
3 map x.split('|')
4 map [len(x), x]
5 filter x[0]>6
6 map x[1]
7 map seq(x).map(lambda x: x.partition(' ')[0].strip())
8 flatten
9 sorted
10 distinct
To unsubscribe from this group and stop receiving emails from it, send an email to xonsh+un...@googlegroups.com.
To post to this group, send email to xo...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/xonsh/CALD07fx9N3FtuU3chXAG4Jy4gmftfQxUDj_XQ205WU4c%3DPra0Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
--Asst. Prof. Anthony Scopatz
Nuclear Engineering Program
Mechanical Engineering Dept.
University of South Carolina
sco...@cec.sc.edu
Office: (803) 777-9334
Cell: (512) 827-8239
Office: Horizon 1, #011 (ground floor, not first)
Book a meeting with me at https://scopatz.youcanbook.me/
Open up an issue: https://github.com/scopatz/me/issues
Check my calendar
--
You received this message because you are subscribed to the Google Groups "xonsh" group.
To unsubscribe from this group and stop receiving emails from it, send an email to xonsh+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/xonsh/CALD07fwNwQS-uMpb%3D59bcbjwC-2VK79FT%3Daq%2BYUhfSDFNWfdbA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.