You are here: TWiki > Guides Web > Linux r11 - 10 Sep 2008 - 18:51 - JesseSuen


Start of topic | Skip to actions

Linux Guides

SSH Tips & Tricks

Force removal of a RPM

If an application was removed uncleanly (i.e. 'rm -rf' instead of 'rpm -e'), then you may have trouble uninstalling the rpm, especially if the rpm relies on pre/post-install scripts. To force the uninstall, you can give the --noscripts option:
# rpm --noscripts -e <package>

GNU Screen

Help! I'm locked out of GNU screen!

If you are using GNU screen and the terminal has suddenly become unresponsive to keypresses, you may have accidently locked the screen through the command: Ctrl+A+S. You can unlock screen by simply pressing Ctrl+Q.

Edit your .screenrc to have a tab bar at the bottom

Add the following to your ~/.screenrc file
#change the hardstatus settings to give an window list at the bottom of the
#screen, with the time and date and with the current window highlighted
hardstatus alwayslastline
hardstatus string '%{= kG}[ %{G}%H %{g}][%= %{= kw}%?%-Lw%?%{r}(%{W}%n*%f%t%?(%u)%?%{r})%{w}%?%+Lw%?%?%= %{g}][%{B} %m/%d %{W}%c %{g}]'

Then type Ctrl+A, and type: source .screenrc to apply the changes.

References

Vim Tips

Tab navigation like Firefox in vim

Add the following to your ~/.vimrc file:
:nmap <C-S-tab> :tabprevious<cr>
:nmap <C-tab> :tabnext<cr>
:map <C-S-tab> :tabprevious<cr>
:map <C-tab> :tabnext<cr>
:imap <C-S-tab> <ESC>:tabprevious<cr>i
:imap <C-tab> <ESC>:tabnext<cr>i
:nmap <C-t> :tabnew<cr>
:imap <C-t> <ESC>:tabnew<cr> 

Space usage in local hard disk root directory:

Linux:
# du -chsx /*
SolarisL?
# du -dhs /*

Indentation in vim

Add the following to your ~/.vimrc file:
set et
set sw=4
set smarttab

Other vim tips:

References

Edit | Attach | Printable | Raw View | Backlinks: Web, All Webs | History: r11 < r10 < r9 < r8 < r7 | More topic actions
This site is powered by the TWiki collaboration platformCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback