Added help screens.

This commit is contained in:
Robert R Evans
2010-10-02 15:04:24 -07:00
parent 6491f50a91
commit a7d1ee0c02
24 changed files with 29 additions and 2304 deletions

View File

@@ -1,36 +0,0 @@
#!/bin/bash
function rh {
history | awk '{a[$2]++}END{for(i in a){print a[i] " " i}}' | sort -rn | head
}
function ips {
ifconfig | grep "inet " | awk '{ print $2 }'
}
# View man documentation in Preview
pman () {
man -t "${1}" | open -f -a /Applications/Preview.app/
}
pcurl() {
curl "${1}" | open -f -a /Applications/Preview.app/
}
pri() {
ri -T "${1}" | open -f -a /Applications/Preview.app/
}
# disk usage per directory
usage ()
{
if [ $1 ]
then
du -hd $1
else
du -hd 1
fi
}

View File

@@ -1,15 +0,0 @@
#!/bin/bash
function git_remote {
echo "Running: git remote add origin ${GIT_HOSTING}:$1.git"
git remote add origin $GIT_HOSTING:$1.git
}
function git_first_push {
echo "Running: git push origin master:refs/heads/master"
git push origin master:refs/heads/master
}
function git_remove_missing_files() {
git ls-files -d -z | xargs -0 git update-index --remove
}

View File

@@ -1,13 +0,0 @@
#!/bin/bash
function rails_jquery {
curl -o public/javascripts/rails.js http://github.com/rails/jquery-ujs/raw/master/src/rails.js
}
function jquery_install {
curl -o public/javascripts/jquery.js http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js
}
function jquery_ui_install {
curl -o public/javascripts/jquery_ui.js http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.5/jquery-ui.min.js
}

View File

@@ -1,50 +0,0 @@
#!/bin/bash
function nginx_reload() {
FILE="${NGINX_PATH}/logs/nginx.pid"
if [ -e $FILE ]; then
echo "Reloading NGINX..."
PID=`cat $NGINX_PATH/logs/nginx.pid`
sudo kill -HUP $PID
else
echo "Nginx pid file not found"
return 0
fi
}
function nginx_stop() {
FILE="${NGINX_PATH}/logs/nginx.pid"
if [ -e $FILE ]; then
echo "Stopping NGINX..."
PID=`cat $NGINX_PATH/logs/nginx.pid`
sudo kill -INT $PID
else
echo "Nginx pid file not found"
return 0
fi
}
function nginx_start() {
FILE="${NGINX_PATH}/sbin/nginx"
if [ -e $FILE ]; then
echo "Starting NGINX..."
sudo $NGINX_PATH/sbin/nginx
else
echo "Couldn't start nginx"
fi
}
function nginx_restart() {
FILE="${NGINX_PATH}/logs/nginx.pid"
if [ -e $FILE ]; then
echo "Stopping NGINX..."
PID=`cat $NGINX_PATH/logs/nginx.pid`
sudo kill -INT $PID
sleep 1
echo "Starting NGINX..."
sudo $NGINX_PATH/sbin/nginx
else
echo "Nginx pid file not found"
return 0
fi
}