Gek Essential

Author Archive

Linux Shell Tip

by admin on Nov.17, 2009, under Uncategorized

Here’s an interesting short cut that I never knew “^” and “!” in linux shell.

It’s an interesting short cut, but it going to need some getting used to.

Link to the original article is listed at the bottom of the page and the original content copied is as below.

Tip: ^ and ! in the shell

I’m astounded. So don’t people know about using ^ and ! in the shell?!? Last week I watched an experienced Linux user carefully hit the ↑ cursor key to get a previous line of history, then ←&→ just to make a simple edit!

Here’s my 30 second guide:

!! Repeat the previous command. Example:

$ ls
bin  d  Desktop  rpmbuild  tmp
$ !!
ls
bin  d  Desktop  rpmbuild  tmp
!-2 (etc) Repeat the command 2 previously (so !! = !-1), or for any number previously. This is the most useful I think.
^foo^bar Replace foo with bar in the previous command. eg:

$ ls -l /etx/httpd/conf.d/local.conf
ls: cannot access /etx/httpd/conf.d/local.conf: No
such file or directory
$ ^etx^etc
ls -l /etc/httpd/conf.d/local.conf
-rw-r--r-- 1 root root 76 2009-07-16 14:59 /etc/httpd/conf.d/local.conf
!foo Run the most recent command that started foo, eg:

$ !ls
ls -l /etc/httpd/conf.d/local.conf
-rw-r--r-- 1 root root 76 2009-07-16 14:59 /etc/httpd/conf.d/local.conf

Today I discovered that these are called event designators. When I first saw someone using them it was on an Apollo workstation circa 1991, and I pretty quickly picked these up myself.

Original Link: http://rwmj.wordpress.com/2009/11/16/tip-and-in-the-shell/

Leave a Comment more...

Debian LAMP Install command

by admin on Sep.24, 2009, under Uncategorized

Haven’t really touched my home server in a while but planning some upgrade both hardware and software. Including a basic LAMP server.

In order to do this, simply copy and paste following command line for Debian etch

apt-get update
apt-get install apache2 libapache2-mod-php5 php5 php5-cli php5-mysql php5-gd php5-mcrypt mysql-client mysql-server libmysqlclient15-dev phpmyadmin

and follow relevant steps to configure apache, mysql and phpmyadmin and secure it before putting online.

Leave a Comment more...

Palm pre vs iPhone Gs

by admin on Jul.21, 2009, under cellphone, gadget

My contract is coming up November and I am needing to figure out my options. Two phone
A that caught my eye were iPhone and palm pre. From hour or so of idling on internet I found out that it is not that obvious choice. Following is brief summary of what I found so far…

iPhone GS:
- multi-lingual support out of the box
- sleek and solid design
- faster than pre
- vast array of software from App Store
- support max size of 32G

Palm Pre
- true multi-tasking OS
- recently released online SDK so potential for just as many apps in coming months
- built in keyboard but no multi-lingual support

So far iphone wins by bit, because of it’s speed and multi-lingual support but Palm has very good potential in coming months with it’s SDK being public. I’m sure there are slew of developers eager to get their hands on it, if they haven’t already.

Maybe my decision may change by November but we’ll have to see as I eagerly wait.

Leave a Comment :, , more...

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!

Visit our friends!

A few highly recommended friends...

Archives

All entries, chronologically...