Archive

Archive for the ‘linux’ Category

Linux Noob: An introduction to shell scripting

September 25th, 2009 No comments

Using the command line in Linux can be one of the most daunting tasks to a regular Windows User. The Linux command line, or “Shell” is vastly more powerful that the command line you might be used to in windows. On Linux, you can create shell scripts (like a Windows Batch file, but on fists full of steroids).

If you want to learn more about
An Introduction to Shell Scripting

It’s a work in progress, but has a lot of great information for someone getting started.

Categories: linux, noob Tags:

Use Cygwin to count the lines in a text file on Windows.

September 24th, 2009 No comments

You can quickly count the lines in text file on a Linux (or other *nix based system) with this command

wc -l < filename

(Of course, you need to substitute the filename with your filename.

Need to do this on a WIndows system? Download cygwin and you can issue the same command from the cygwin command line.  The only trick to cygwin is to remember that your root directory (C:\ on most Windows systems) is /cygdrive/c. Then the directory structure is the same from there.

Categories: linux Tags: , ,

What was that command again? Linux History

September 14th, 2009 No comments

Here is a total noob hint.

You can see the last 500 or so commands you have entered in the command line on a Linux system with the following command:
history

Now, if you want to filter that list you can use grep. For example, if you want to see the files you have edited, you could:
history | grep nano
Assuming of course, that you use nano as your text editor.

Categories: linux, noob Tags:

The worlds shortest guide to cron

September 14th, 2009 No comments

You can see a guide to complete a cron entry here. It always seems a lot harder to find how to actually see and edit the schedule.

To see what you have in your cron schedule
crontab -l

To edit your cron schedule
crontab -e

Categories: linux Tags: