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 886 posted 17 years ago by lakedenman
Execute this to remove the .svn directory from the current directory and all sub directories
3 1002 posted 17 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 1727 posted 17 years ago by mandric
Start mplayer with -vf screenshot, and press 's' when you want to capture a frame.
0 911 posted 17 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 872 posted 17 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 907 posted 17 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 930 posted 17 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 1615 posted 17 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 948 posted 17 years ago by mandric
0 744 posted 17 years ago by mandric
count .htm or .html files in the directory. use ls and grep command.
1 935 posted 17 years ago by kyokutyo
1 1060 posted 17 years ago by CharlyBr
recover to normal speed with /sbin/ipfw delete 100 /sbin/ipfw delete 200 ... or reboot
0 1160 posted 17 years ago by zingo
Useful when trying to cleanup a large repo to see where you've made the most changes
1 1638 posted 17 years ago by JacobSingh
Forces a recalcitrant port to install by *uninstalling* it completely first
0 640 posted 17 years ago by cczona
//for options available, see: http://www.ss64.com/bash/shopt.html
1 1042 posted 17 years ago by cczona
Sure that programmers know this, but me as a sysadmin does not use svn that much.
3 1302 posted 17 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 1862 posted 17 years ago by jachin
Improved blipsend miniapp Requires curl, zenity and sed
0 738 posted 17 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 1365 posted 17 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 949 posted 17 years ago by cyo
0 1103 posted 17 years ago by zingo
0 1111 posted 17 years ago by zingo
2 1108 posted 17 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 1195 posted 17 years ago by berkes
0 974 posted 17 years ago by assbach
1 ... 34 35 36 37 38 ... 41