#!/bin/bash # Paste at Pastebin.com using command line (browsers are slow, right?) # coder : Anil Dewani # date : Novemeber 7, 2010 #help function howto() { echo "\ Pastebin.com Bash Script \ Usage : $0 [ -n ] [ -e ] [ -t ] [ -h ] Specify the name of paste to be used (optional) Specify email to be used while pasting (optional) Specify code language used, use any of the following values (optional and default value is plain text) => Some famous [ -t ] Values:: php - PHP actionscript3 - Action Script 3 asp - ASP bash - BASH script c - C language csharp - C# cpp - C++ java - JAVA sql - SQL " } NAME= EMAIL= TYPE= #getopts, config while getopts "n:e:t:h" OPTION do case $OPTION in n) NAME=$OPTARG ;; e) EMAIL=$OPTARG ;; t) TYPE=$OPTARG ;; h) howto exit ;; ?) howto exit ;; esac done #get data from stdin INPUT="$(