ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
That's not "piping". The syntax above is just a way to tell SED to do two different things. If you actually run one SED command and then pipe the output to another one, you may get a different answer.
In my experience, there's only one way to get this stuff to "stick" to you brain---run lots of tests on simple commands.
That's not "piping". The syntax above is just a way to tell SED to do two different things. If you actually run one SED command and then pipe the output to another one, you may get a different answer.
In my experience, there's only one way to get this stuff to "stick" to you brain---run lots of tests on simple commands.
sorry didn't post my question properly?
Is piping the only option
Code:
sed -e Task1 -e Task2 -e Task3 $file | sed '$d' > $Newfile
Is there any way we could perform without piping???
Lastly
Where can I get the definitions for -
Quote:
$1 ---- first argument
$2 ---- second argument
$* ---- all argument
$# ---- number of arguments
$d ---- lastline
Hard to google on them
Last edited by tostay2003; 07-24-2008 at 04:45 PM.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.