Category: Unix Automation and Security

1

100+ Perl One Liners

Double-space a file perl -pe ‘$\ = “\n”‘ file Double-space a file, excluding the blank lines perl -pe ‘$_ .= “\n” unless /^$/’ Add a blank line before every line perl -pe ‘s/^/\n/’ Remove all blank lines perl -ne ‘print unless /^$/’

1

awk or gawk reference

Awk and Gawk – pattern scanning and processing language Gawk is the GNU Project’s implementation of the AWK programming language. It conforms to the definition of the language in the POSIX 1003.1 Standard. This version in turn is based on the description in The AWK Programming...

0

Bash Scripting – Controlling the Loop

You might be tempted to think that after you start a loop, you’re stuck until the loop finishes all its iterations. This is not true. A couple of commands help us control what happens inside of a loop: The break command The continue command Each command...

0

Bash Scripting – Displaying Interactive Messages

Most shell commands produce their own output, which is displayed on the console monitor where the script is running. Many times, however, you will want to add your own text messages to help the script user know what is happening within the script. You can do...

Page 1 of 6

[contact-form to='ramkumar.ramadevu@gmail.com' subject='New Learning Request Submitted'][contact-field label='Name' type='name' required='1'/][contact-field label='Email' type='email' required='1'/][contact-field label='Learning Request' type='textarea' required='1'/][contact-field label='Are you Looking for ' type='radio' required='1' options='Paid Training,Free Training'/][/contact-form]

What is your Learning Goal for Next Six Months ? Talk to us