Welcome To Snipplr


Everyone's Recent Bash Snippets



1 ... 34 35 36 37 38 ... 41
"-b" and "-a" tells grep to show you 10 lines before and 10 lines after
0 577 posted 16 years ago by lakedenman
Execute this to remove the .svn directory from the current directory and all sub directories
3 671 posted 16 years ago by meinhard
This is meant to be run as root, so do it at your own risk. It's very raw and needs error checking, but works. I run this script to get new django sites off the ground in a few minutes.
0 1309 posted 16 years ago by mandric
Start mplayer with -vf screenshot, and press 's' when you want to capture a frame.
0 546 posted 16 years ago by mandric
Check out the bash command 'shopt -s cdable_vars' From the man bash page: If set, an argument to the cd builtin command that is not a directory is assumed to be the name of a variable whose value is the directory to change to.
0 549 posted 16 years ago by cczona
(EDITED: Originally I had this snip using 'cat /proc/version'. But have since replaced it with a more reliable -- and specific -- method) If you need still more info (or are on a BSD), see 'uname', 'dpkg-architecture'
1 534 posted 16 years ago by cczona
If Ubuntu Server fails to resolve hostnames or find a network connection via Parallels 3 bridged networking, it may be attempting to use the wrong network interface.
0 578 posted 16 years ago by cczona
Quick command I use to remove .SVN folders from a tree structure copied from SVN working copy. Sometimes a bit easier than running an export.
6 1211 posted 16 years ago by wfdev
find command just returns a list of HTML files that have 'search_str' in it, vim takes a list of files.
0 636 posted 16 years ago by mandric
0 457 posted 16 years ago by mandric
count .htm or .html files in the directory. use ls and grep command.
1 577 posted 16 years ago by kyokutyo
1 703 posted 16 years ago by CharlyBr
recover to normal speed with /sbin/ipfw delete 100 /sbin/ipfw delete 200 ... or reboot
0 758 posted 16 years ago by zingo
Useful when trying to cleanup a large repo to see where you've made the most changes
1 1216 posted 16 years ago by JacobSingh
Forces a recalcitrant port to install by *uninstalling* it completely first
0 390 posted 16 years ago by cczona
//for options available, see: http://www.ss64.com/bash/shopt.html
1 682 posted 16 years ago by cczona
Sure that programmers know this, but me as a sysadmin does not use svn that much.
3 930 posted 16 years ago by therobot
This command will not delete the .DS_Store files from the file system, just take them out of version control. Before doing this it would be a good idea to setup the repository to ignore .DS_Store files.
1 1430 posted 16 years ago by jachin
Improved blipsend miniapp Requires curl, zenity and sed
0 460 posted 16 years ago by lukaszkorecki
\Q...\E perl quoting means no ugly escaping in the regex. find's -print0 with xargs -0 is the secret to handling files with spaces in their names.
1 935 posted 16 years ago by ches
Il suffit de créer une page PHP et y placer un phpinfo() ou si vous avez accès au serveur en ligne de commande (Putty, WinSCP, ...), vous pouvez tapez cette commande. Dans l'exemple, nous souhaitons savoir si l'extension openssl est présente et no...
0 640 posted 16 years ago by cyo
0 753 posted 16 years ago by zingo
0 722 posted 16 years ago by zingo
2 734 posted 16 years ago by zingo
This script removes (DROPS) all tables that start with foo_. Usefull if you had some CMS or application that (ab)uses table prefixing, and want to clean 0ut your database. NOTE: the data is remove FOREVER! So take good casre: make backups and all...
2 835 posted 16 years ago by berkes
0 633 posted 16 years ago by assbach
1 ... 34 35 36 37 38 ... 41