04-25-2011
Pipes with the < and >> meanings.
Hey,
Well, we're starting scripting next week for my class, and I have my command done, but I don't actually understand what the meaning is, so I was just wondering if someone could "translate" this in to words so that I might be able to do this better...
Quote:
c1 | c2 | c3 < inputInfo.txt >> outputCollection.txt
command1 | command2 | command3 etc.
But yeah...
Also, the command I have now, I was wondering if their is a way to get the output of the pips to work on 2 commands rather than just one...
Like, if I had ps -A | grep [numbers] | then have this pipe to both, wc and sort, so I can get the total amount of processes and have it sorted...
Sorry for multi-questioning, I really only care about the translation though,
Thanks so much!
10 More Discussions You Might Find Interesting
1. Filesystems, Disks and Memory
Hello!
How I can increase or decrease predefined pipe buffer size?
System FreeBSD 4.9 and RedHat Linux 9.0
Thanks! (1 Reply)
Discussion started by: Jus
1 Replies
2. Shell Programming and Scripting
Hi,
Can the cd command be invoked using pipes???
My actual question is slightly different. I am trying to run an executable from different folders and the path of these folders are obtained dynamically from the front end. Is there a way in which i can actually run the executable... (2 Replies)
Discussion started by: Sinbad
2 Replies
3. Shell Programming and Scripting
I'm investigating strange behaviour on two boxes (Sun OS 5.10 and AIX 5.1) in ksh
have used $? to get exit codes returned:-
137 and 34
where can I find what these mean?
thank you (1 Reply)
Discussion started by: speedieB
1 Replies
4. Shell Programming and Scripting
How to have a conversation between 2 processes using named pipes? (5 Replies)
Discussion started by: kanchan_agr
5 Replies
5. Cybersecurity
Hi everybody, I'm writing to know what the following event stands for. I know that the following event is about a "su to root" action but I don't have any Idea about what action could rise this message. For example If an acction performed by the root crontab, a sudo command or something like that.... (1 Reply)
Discussion started by: PVelazco
1 Replies
6. Shell Programming and Scripting
Hi,
thanks for b4. can anyone tell me why following not working:
noUsers=$(who | cut -d" " -f1 | wc -l)
What i'm trying to do is get a list of logged on users and pass it to 'wc -l' and store the output to a variable. Any ideas? (1 Reply)
Discussion started by: Furqan_79
1 Replies
7. UNIX for Dummies Questions & Answers
im trying to figure out how to do the following:
using pipes to combine grep and find commands to print all lines in files that start with the letter f in the current directory that contain the word "test" for example?
again using pipes to combine grep and find command, how can I print all... (1 Reply)
Discussion started by: ez45
1 Replies
8. Shell Programming and Scripting
Hi Friends,
Could i get the meaning for the following FTP codes?
421 425 426 530 450 550 451 551 452 552 553
Thanks,
Raja. (1 Reply)
Discussion started by: smr_rashmy
1 Replies
9. Programming
Hello all, I am trying to learn more about programming Unix pipes in C.
I have created a pipe that does od -bc < myfile | head
Now, I am trying to create od -bc < myfile | head | wc
Here is my code, and I know I might be off, thats why I am here so I can get some clarification.
#include... (1 Reply)
Discussion started by: petrca
1 Replies
10. UNIX for Dummies Questions & Answers
Hi all,
I was trying see some CPU utilization of a Red hat Linux machine using 'top' command.
Any way I got high level idea from the out puts,
but when I observed the following line:
Cpu(s): 7.4%us, 0.5%sy, 0.0%ni, 91.6%id, 0.4%wa, 0.0%hi, 0.1%si, 0.0%st
I couldn't make out what... (2 Replies)
Discussion started by: a99u
2 Replies
LEARN ABOUT DEBIAN
smd-translate
smd-translate(1) Sync Mail Dir (smd) documentation smd-translate(1)
NAME
smd-translate - translates mailbox names according to predefined patterns
SYNOPSIS
smd-translate [-m mode] [-d direction] endpoint mailbox
DESCRIPTION
smd-translate translates mailbox names according to predefined patterns. It is designed to be used in the configuration file of smd-
push(1) and smd-pull(1).
Refer to smd-config(5) for a longer discussion on translators.
Supported modes follow.
oimap-dovecot
This mode is designed to make the transition of offlineimap users to smd simpler. It assumes remote mailboxes are named like in the follow-
ing:
Maildir/cur
Maildir/.sub.folder/new
The corresponding local mailboxes are named like in the following:
Mail/cur
Mail/sub.folder/new
nodots
This mode simply gets rid of all dots. It assumes remote mailboxes are named like in the following:
Maildir/cur
Maildir/.sub.folder/new
The corresponding local mailboxes are named like in the following:
Mail/cur
Mail/sub/folder/new
move
This mode just replaces the root of the mailbox, i.e. substitutes MAILBOX_LOCAL for MAILBOX_REMOTE and viceversa.
USAGE IN CONFIGURATION FILE
Assuming the MAILBOX_LOCAL configuration variable is set to Mail and the MAILBOX_REMOTE is set to Maildir, one can use the following con-
figuration file snippet in ~/.smd/config.endpoint:
TRANSLATOR_RL="smd-translate -m oimap-dovecot -d RL endpoint"
TRANSLATOR_LR="smd-translate -m oimap-dovecot -d LR endpoint"
To test your setup use the smd-check-conf(1) utility.
OPTIONS
-m mode
One of the supported modes listed above
-d direction
One of RL or LR
endpoint
Is the suffix for the name of the configuration file to use
mailbox
The mailbox name to translate
FILES
~/.smd/config.*
SEE ALSO
smd-push(1), smd-pull(1), smd-config(5), smd-check-conf(1)
AUTHOR
Enrico Tassi <gares@fettunta.org>
11 June 2012 smd-translate(1)