How to remove blank empty lines in unix/linux
Posted on March 10, 2010
I found 6 ways can do it,if you know others ,pls let us know.
Please see below code for detail.
bash-2.05a$ cat test.txt
aaaaaaa
bbbbbb
cccccc
bash-2.05a$ grep ‘.’ test.txt
aaaaaaa
bbbbbb
cccccc
bash-2.05a$ grep -v ‘^$’ test.txt
aaaaaaa
bbbbbb
cccccc
bash-2.05a$ sed ‘/^$/d’ test.txt
aaaaaaa
bbbbbb
cccccc
bash-2.05a$ sed -n ‘/^$/!p’ test.txt
aaaaaaa
bbbbbb
cccccc
bash-2.05a$ awk ‘/./’ test.txt
aaaaaaa
bbbbbb
cccccc
bash-2.05a$ awk NF test.txt
aaaaaaa
bbbbbb
cccccc
bash-2.05a$
Popularity: 1% [?]
» Filed Under Linux | Leave a Comment
How to remove email account from T-Mobile G1 Google Phone
Posted on July 27, 2009
If you don’t need the email account in your T-mobile G1 phone,you can remove it easily follow the following steps
1. On the Home screen, press the Application button.
2. Touch Email and go your Inbox
3. Then press Menu and select Accounts
4. Tap and hold the account which you want to remove.
5. Select Remove account.
6. Select OK. Done,Good lucks.
Popularity: 45% [?]
» Filed Under Other | Leave a Comment
How to fix keyboard mapping issue of Gnome / Vnc in ubuntu
Posted on June 18, 2009
Yesterday I just intalled an ubuntu 9.04 Server for my co-work.After installed VNC on this server I found the keyboard was messed up while I am connecting this server via vnc client from Windows.After search from internet I found there are 2 good solutions to fix this isssue.
1.In the terminal of this server ,type the following command ,then kill your old vnc then create a new one
gconftool –set /desktop/gnome/peripherals/keyboard/kbd/layouts [...] Continue Reading…
Popularity: 62% [?]
» Filed Under Linux | 11 Comments
How to relocate user profile folder to other drive in windows 7
Posted on May 20, 2009
Bydefault,windows 7/vista put all system data and user data on the same partition,normally it’s drive C.Under this condition we must backup our user data every time we re-install our windows 7/vista.From windows vista ,Microsoft supply us a tool mklink which can create a symbolic link under windows 7 or vista just as the command ln under unix/linux.Below is an example about how to put user data on non-system using [...] Continue Reading…
Popularity: 100% [?]
» Filed Under Windows | 13 Comments
How to show the tab bar when you start firefox
Posted on April 16, 2009
Today I found my firefox do not show the tab bar by default when I start the firefox.In fact it’s very easy to enable this.
To let firefox show the tab bar for you,just go to Tools—Options:
Then select Always show the tab bar,After click OK,you will find Firefox show your the tab bar.
Popularity: 13% [?]
» Filed Under Firefox | Leave a Comment
To install graphics drivers on Ubuntu
Posted on April 10, 2009
If you do not know whether graphics drivers been installed or not,type following in a terminal window ,and it will tell you
and to find out the name of your graphics card,type code:
1.TO install graphics drivers
If it is Nvidia type:
For ATI card :
press enter to install
At last restart your computer
2.Another way,go to System–>Administration–>Hardware Drivers(or Restricted Drivers Manager for different release)
select at the next window and then click “active”
Popularity: 21% [?]
» Filed Under Linux | 4 Comments
3D Desktop switch on Ubuntu
Posted on April 10, 2009
First,you need to install “3ddesktop” by typing the following in a terminal window:
press enter
then you can type 3ddesk ,press enter to run this after the installation
You will see:
And use the up and down or right and left arrow keys to change desktop,press enter to select that desktop
Tips:
You must make sure you have installed graphics drivers before running 3ddesk,and I will do with it in “TO install graphics drivers on [...] Continue Reading…
Popularity: 16% [?]
» Filed Under Linux | Leave a Comment
How to use single click instead of double click in Ubuntu
Posted on April 6, 2009
For single click,first open up the file browser . Open up trash,or start as shown in figure .
Then go to Edit–>Preferences
Open the “Behaviour” tab in the next window,then set to single click
Popularity: 14% [?]
» Filed Under Linux | Leave a Comment
How to play mkv files in windows xp or vista
Posted on April 1, 2009
The MKV file isn’t the regular video and audio compression format. The MKV is an open source container format. It is a general-purpose audio and video container and a contending format to the more popular AVI and MP4 formats. Below will give you 2 methods on how to play mkv files in windows.
The first way is use VLC player to play mkv files in windows,and this is also the [...] Continue Reading…
Popularity: 25% [?]
» Filed Under Windows | 1 Comment
How to know your computer’s uptime in Windows xp/vista/7
Posted on April 1, 2009
As you know,we can use command “uptime” to show your computers uptime in linux/unix.Also we may want to know the uptime of our computers in Windows ,but there is not the uptime command in windows.
Fortunately,windows also give us related commands to show the uptime of the computer.You can find the uptime in the output of command systeminfo,also can find it in the output of command net statistics server or [...] Continue Reading…
Popularity: 25% [?]
» Filed Under Windows | 3 Comments