Permalink
Browse files

functions: remove unused crap

  • Loading branch information...
1 parent 1c75a8a commit cbd620a4e6827ddfa2c2865e6923e9b8d7a28d13 @falconindy committed Apr 22, 2013
Showing with 1 addition and 84 deletions.
  1. +1 −84 .functions
View
@@ -158,7 +158,7 @@ down() {
ex() {
if [[ -f $1 ]]; then
case $1 in
- *.@(tar|tbz2|tgz|txz|rpm)?(.bz2|.gz|.xz))
+ *.@(deb|tar|tbz2|tgz|txz|rpm)?(.bz2|.gz|.xz))
bsdtar xvf "$1" ;;
*.bz2) bzip2 -d "$1" ;;
*.rar) unrar x "$1" ;;
@@ -226,20 +226,11 @@ ip2hex() {
echo
}
-kc() {
- eval $(keychain --eval id_rsa)
-}
-
kopt() {
[[ $1 ]] || return 1
zgrep "${1^^}" /proc/config.gz
}
-ljoin() {
- [[ $1 ]] || { echo "usage: ljoin IFS args..."; return 1; } >&2
- local IFS=$1; echo "${*:2}"
-}
-
ll() {
case $1 in
*.tar.gz|*.tgz)
@@ -259,65 +250,12 @@ ll() {
esac
}
-longest() {
- awk '
- BEGIN {
- linecount = 0
- maxlen = 0
- line = ""
- }
- {
- len = length($0)
- if(len > maxlen) {
- maxlen = len
- line = $0
- }
- }
- END {
- if(linecount > 0) {
- printf "%d\t%d\n", maxlen, line
- }
- }
- ' < ${1:-/dev/stdin}
-}
-
-mak() {
- if [[ ! -f Makefile ]]; then
- local -a src=(*.c)
- make "${src[@]%.c}" "$@"
- else
- make "$@"
- fi
-}
-
-man2pdf() {
- local manpage out
-
- [[ $1 ]] || { echo "usage: man2pdf <manpage>"; return 1; }>&2
-
- if manpage=$(man -w "$1"); then
- out=/tmp/$1.pdf
- [[ -e $out ]] || man -t $1 | ps2pdf - > $out
- [[ -e $out ]] && xo $out
- else
- echo "ERROR: manpage \"$1\" not found."
- fi
-}
-
mkcd() {
[[ $1 ]] || return 0
[[ -d $1 ]] || mkdir -vp "$1"
[[ -d $1 ]] && builtin cd "$1"
}
-q() {
- "$@" >/dev/null
-}
-
-qq() {
- "$@" &>/dev/null
-}
-
rlatest() {
local count=${2:-1}
@@ -342,27 +280,6 @@ t() {
tmux -L main "${@:-attach}"
}
-unwork() {
- if [[ -z $1 ]]; then
- echo "usage: unwork <dirname>"
- return 1
- fi
-
- if [[ -d $1 ]]; then
- local count
- count=$(find "$1" -depth -type d -name '.svn' -printf '.' -exec rm -rf {} + | wc -c)
- if (( $? != 0 )); then
- echo "Error occurred. Nothing done." >&2
- elif (( count = 0 )); then
- echo "Nothing done."
- else
- echo "SUCCESS. Directory is no longer a working copy ($count .svns removed)."
- fi
- else
- echo "ERROR: $1 is not a directory"
- fi
-}
-
up() {
local cdinto=0 x= traverse= curpath=

0 comments on commit cbd620a

Please sign in to comment.