How to change command prompt in FreeBSD

By default FreeBSD does not show anything in command prompt such as path, username, hostname except $. For many this can be quite annoying. As an example user does not know the current path and to get that must run pwd which is a redundant step. To have a more … Continue Reading →

Renaming files in Linux terminal in batch

Few days ago I have encountered a problem whereby I had to rename 10,000 files and remove a prefix (_BK). There are two approaches to handle such a problem, Rename files manually from GUI. Using a small bash script to do the job. Here, I talk about second approach as … Continue Reading →

Awesome Linux command line

To be honest with you, I like command line so much, even before I became familiar with Linux, I used to use DOS command prompt extensively, which in comparison with Linux command line is nothing. After, I had experienced Linux for the first time, I have fascinated how it is … Continue Reading →

Running command under root user in bash script

Sometimes there are cases that required to run certain commands under root user in bash scripts. However, for switching the root, user must key in the root password. In such conditions the best approach is to utilize “sudo” command with -S parameter to be able to run a process under … Continue Reading →

Resolving extra space in bash completion Ubuntu 12.04

Due to legacy ATI graphic card I have to stick to Ubuntu 12.04 yet since open source driver is almost terrible in power management and causes my laptop fan runs all the time and therefore, low battery life as well as heat up in Dell 1557 series. Anyhow, last night … Continue Reading →