Browse Source

Added or edited file headers.

master
Sorin Ionescu 13 years ago
parent
commit
b96bbca51c
  1. 7
      alias.zsh
  2. 8
      completion.zsh
  3. 8
      directory.zsh
  4. 7
      environment.zsh
  5. 9
      functions/duh
  6. 7
      functions/reload
  7. 7
      helper.zsh
  8. 8
      history.zsh
  9. 6
      init.zsh
  10. 7
      keyboard.zsh
  11. 7
      plugins/archive/completions/_extract
  12. 7
      plugins/archive/completions/_ls-archive
  13. 7
      plugins/archive/functions/extract
  14. 7
      plugins/archive/functions/ls-archive
  15. 8
      plugins/bundler/init.zsh
  16. 9
      plugins/command-not-found/init.zsh
  17. 12
      plugins/compleat/init.zsh
  18. 9
      plugins/dpkg/functions/apt-copy
  19. 9
      plugins/dpkg/functions/dbb-build
  20. 9
      plugins/dpkg/init.zsh
  21. 7
      plugins/git/alias.zsh
  22. 8
      plugins/git/completion.zsh
  23. 7
      plugins/git/completions/_git-hub
  24. 7
      plugins/git/completions/_git-info
  25. 8
      plugins/git/functions/git-branch
  26. 8
      plugins/git/functions/git-hub
  27. 7
      plugins/git/functions/git-info
  28. 8
      plugins/git/functions/git-root
  29. 10
      plugins/git/hub.zsh
  30. 12
      plugins/git/init.zsh
  31. 7
      plugins/git/style.zsh
  32. 13
      plugins/gnu-utils/init.zsh
  33. 8
      plugins/gpg-agent/init.zsh
  34. 8
      plugins/history-substring-search/init.zsh
  35. 7
      plugins/macports/init.zsh
  36. 8
      plugins/node/functions/node-docs
  37. 8
      plugins/node/init.zsh
  38. 8
      plugins/osx/functions/manb
  39. 8
      plugins/osx/functions/manp
  40. 7
      plugins/osx/functions/pfd
  41. 7
      plugins/osx/functions/pfs
  42. 7
      plugins/osx/functions/tab
  43. 7
      plugins/osx/functions/trash
  44. 7
      plugins/osx/init.zsh
  45. 9
      plugins/pacman/functions/pacdisowned
  46. 9
      plugins/pacman/functions/paclist
  47. 10
      plugins/pacman/init.zsh
  48. 7
      plugins/perl/completions/_prep
  49. 7
      plugins/perl/completions/_psub
  50. 7
      plugins/perl/functions/prep
  51. 7
      plugins/perl/functions/psub
  52. 7
      plugins/perl/init.zsh
  53. 7
      plugins/python/init.zsh
  54. 9
      plugins/rails/init.zsh
  55. 7
      plugins/rsync/init.zsh
  56. 7
      plugins/ruby/init.zsh
  57. 12
      plugins/screen/init.zsh
  58. 29
      plugins/ssh-agent/init.zsh
  59. 12
      plugins/tmux/init.zsh
  60. 8
      plugins/wakeonlan/completions/_wake
  61. 8
      plugins/wakeonlan/functions/wake
  62. 8
      plugins/yum/init.zsh
  63. 16
      plugins/z/init.zsh
  64. 10
      spectrum.zsh
  65. 7
      templates/zshrc.zsh
  66. 8
      terminal.zsh
  67. 8
      themes/minimal/prompt_minimal_setup
  68. 26
      themes/nicoulaj/prompt_nicoulaj_setup
  69. 17
      themes/sorin/prompt_sorin_setup
  70. 14
      themes/steeef/prompt_steeef_setup
  71. 9
      utility.zsh

7
alias.zsh

@ -1,3 +1,10 @@
#
# Defines general aliases.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
setopt CORRECT # Correct commands. setopt CORRECT # Correct commands.
# The 'ls' Family # The 'ls' Family

8
completion.zsh

@ -1,3 +1,11 @@
#
# Sets completion options.
#
# Authors:
# Robby Russell <robby@planetargon.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Dumb terminals lack support. # Dumb terminals lack support.
if [[ "$TERM" == 'dumb' ]]; then if [[ "$TERM" == 'dumb' ]]; then
return return

8
directory.zsh

@ -1,3 +1,11 @@
#
# Sets directory options and defines directory aliases.
#
# Authors:
# James Cox <james@imaj.es>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
setopt AUTO_CD # Auto cd to a directory without typing cd. setopt AUTO_CD # Auto cd to a directory without typing cd.
setopt AUTO_PUSHD # Push the old directory onto the stack on cd. setopt AUTO_PUSHD # Push the old directory onto the stack on cd.
setopt PUSHD_IGNORE_DUPS # Don't store duplicates in the stack. setopt PUSHD_IGNORE_DUPS # Don't store duplicates in the stack.

7
environment.zsh

@ -1,3 +1,10 @@
#
# Sets general shell options and defines environment variables.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Smart URLs # Smart URLs
autoload -Uz url-quote-magic autoload -Uz url-quote-magic
zle -N self-insert url-quote-magic zle -N self-insert url-quote-magic

9
functions/duh

@ -1,4 +1,11 @@
# Displays human readable disk usage statistics. #
# Displays human readable disk usage.
#
# Authors:
# Suraj N. Kurapati <sunaku@gmail.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
function duh() { function duh() {
(( $# == 0 )) && set -- * (( $# == 0 )) && set -- *
if [[ "$OSTYPE" == linux* ]]; then if [[ "$OSTYPE" == linux* ]]; then

7
functions/reload

@ -1,3 +1,10 @@
#
# Reloads the Zsh configuration.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Reloads ~/.zshrc. # Reloads ~/.zshrc.
local zshrc="$HOME/.zshrc" local zshrc="$HOME/.zshrc"
if [[ -n "$1" ]]; then if [[ -n "$1" ]]; then

7
helper.zsh

@ -1,3 +1,10 @@
#
# Defines helper functions.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Checks if a file can be autoloaded by trying to load it in a subshell. # Checks if a file can be autoloaded by trying to load it in a subshell.
function autoloadable() { function autoloadable() {
( unfunction $1 ; autoload -U +X $1 ) &> /dev/null ( unfunction $1 ; autoload -U +X $1 ) &> /dev/null

8
history.zsh

@ -1,3 +1,11 @@
#
# Sets history options.
#
# Authors:
# Robby Russell <robby@planetargon.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
HISTFILE="$HOME/.zhistory" HISTFILE="$HOME/.zhistory"
HISTSIZE=10000 HISTSIZE=10000
SAVEHIST=10000 SAVEHIST=10000

6
init.zsh

@ -1,4 +1,10 @@
#
# Initializes Oh My Zsh. # Initializes Oh My Zsh.
#
# Authors:
# Robby Russell <robby@planetargon.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Check for the minimum supported version. # Check for the minimum supported version.
min_zsh_version='4.3.10' min_zsh_version='4.3.10'

7
keyboard.zsh

@ -1,3 +1,10 @@
#
# Sets keyboard bindings.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Dumb terminals lack support. # Dumb terminals lack support.
if [[ "$TERM" == 'dumb' ]]; then if [[ "$TERM" == 'dumb' ]]; then
return return

7
plugins/archive/completions/_extract

@ -1,6 +1,13 @@
#compdef extract #compdef extract
#autoload #autoload
#
# Completes extract.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
_arguments \ _arguments \
'(-r --remove)'{-r,--remove}'[remove archive]' \ '(-r --remove)'{-r,--remove}'[remove archive]' \
"*::archive file:_files -g '(#i)*.(tar|tgz|tbz|tbz2|txz|tlz|gz|bz2|xz|lzma|Z|zip|rar|7z|deb)(-.)'" && return 0 "*::archive file:_files -g '(#i)*.(tar|tgz|tbz|tbz2|txz|tlz|gz|bz2|xz|lzma|Z|zip|rar|7z|deb)(-.)'" && return 0

7
plugins/archive/completions/_ls-archive

@ -1,6 +1,13 @@
#compdef ls-archive #compdef ls-archive
#autoload #autoload
#
# Completes ls-archive.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
_arguments \ _arguments \
'(-v --verbose)'{-v,--remove}'[verbose archive listing]' \ '(-v --verbose)'{-v,--remove}'[verbose archive listing]' \
"*::archive file:_files -g '(#i)*.(tar|tgz|tbz|tbz2|txz|tlz|gz|bz2|xz|lzma|Z|zip|rar|7z)(-.)'" && return 0 "*::archive file:_files -g '(#i)*.(tar|tgz|tbz|tbz2|txz|tlz|gz|bz2|xz|lzma|Z|zip|rar|7z)(-.)'" && return 0

7
plugins/archive/functions/extract

@ -1,3 +1,10 @@
#
# Extracts the contents of popular archive formats.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
local remove_archive local remove_archive
local success local success
local file_name local file_name

7
plugins/archive/functions/ls-archive

@ -1,3 +1,10 @@
#
# Lists the contents of popular archive formats.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
local verbose local verbose
if (( $# == 0 )); then if (( $# == 0 )); then

8
plugins/bundler/init.zsh

@ -1,3 +1,11 @@
#
# Defines bundler aliases.
#
# Authors:
# Myron Marston <myron.marston@gmail.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Aliases # Aliases
alias b='bundle' alias b='bundle'
alias be='b exec' alias be='b exec'

9
plugins/command-not-found/init.zsh

@ -1,6 +1,9 @@
# Uses the command-not-found package Zsh support as seen in #
# http://www.porcheron.info/command-not-found-for-zsh/ and # Displays installation information for not found commands.
# installed in Ubuntu. #
# Authors:
# Joseph Jon Booker <joe@neoturbine.net>
#
if [[ -f /etc/zsh_command_not_found ]]; then if [[ -f /etc/zsh_command_not_found ]]; then
source /etc/zsh_command_not_found source /etc/zsh_command_not_found

12
plugins/compleat/init.zsh

@ -1,9 +1,9 @@
# ------------------------------------------------------------------------------ #
# FILE: compleat.plugin.zsh # Loads Compleat completions.
# DESCRIPTION: oh-my-zsh plugin file. #
# AUTHOR: Sorin Ionescu <sorin.ionescu@gmail.com> # Authors:
# VERSION: 1.0.2 # Sorin Ionescu <sorin.ionescu@gmail.com>
# ------------------------------------------------------------------------------ #
if (( ${+commands[compleat]} )); then if (( ${+commands[compleat]} )); then
compleat_setup="${commands[compleat]:h:h}/share/compleat-1.0/compleat_setup" compleat_setup="${commands[compleat]:h:h}/share/compleat-1.0/compleat_setup"

9
plugins/dpkg/functions/apt-copy

@ -1,4 +1,11 @@
# Create a simple script that can be used to 'duplicate' a system. #
# Generates a script that can be used to duplicate a dpkg-based system.
#
# Authors:
# Daniel Bolton <danielbarrettbolton@gmail.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
print '#!/bin/sh'"\n" > apt-copy.sh print '#!/bin/sh'"\n" > apt-copy.sh
list=$(perl -m'AptPkg::Cache' -e '$c=AptPkg::Cache->new; for (keys %$c){ push @a, $_ if $c->{$_}->{'CurrentState'} eq 'Installed';} print "$_ " for sort @a;') list=$(perl -m'AptPkg::Cache' -e '$c=AptPkg::Cache->new; for (keys %$c){ push @a, $_ if $c->{$_}->{'CurrentState'} eq 'Installed';} print "$_ " for sort @a;')

9
plugins/dpkg/functions/dbb-build

@ -1,4 +1,11 @@
# Kernel-package building shortcut. #
# Makes a dpkg Linux kernel package.
#
# Authors:
# Daniel Bolton <dbb@9y.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
MAKEFLAGS='' # Temporarily unset MAKEFLAGS ( '-j3' will fail ). MAKEFLAGS='' # Temporarily unset MAKEFLAGS ( '-j3' will fail ).
appendage='-custom' # This shows up in $ (uname -r ). appendage='-custom' # This shows up in $ (uname -r ).
revision=$(date +"%Y%m%d") # This shows up in the .deb file name. revision=$(date +"%Y%m%d") # This shows up in the .deb file name.

9
plugins/dpkg/init.zsh

@ -1,3 +1,12 @@
#
# Defines dpkg aliases.
#
# Authors:
# Daniel Bolton <dbb@9y.com>
# Benjamin Boudreau <boudreau.benjamin@gmail.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Aliases # Aliases
alias as="aptitude -F \"* %p -> %d \n(%v/%V)\" --no-gui --disable-columns search" # Search package. alias as="aptitude -F \"* %p -> %d \n(%v/%V)\" --no-gui --disable-columns search" # Search package.
alias ad="sudo apt-get update" # Update packages lists. alias ad="sudo apt-get update" # Update packages lists.

7
plugins/git/alias.zsh

@ -1,3 +1,10 @@
#
# Defines Git aliases.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Git # Git
alias g='git' alias g='git'
compdef g=git compdef g=git

8
plugins/git/completion.zsh

@ -1,4 +1,10 @@
# Get the latest Git completion. #
# Gets the latest Git completion.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
completion_file="${0:h}/completions/_git" completion_file="${0:h}/completions/_git"
completion_file_url='http://zsh.git.sourceforge.net/git/gitweb.cgi?p=zsh/zsh;a=blob_plain;f=Completion/Unix/Command/_git;hb=HEAD' completion_file_url='http://zsh.git.sourceforge.net/git/gitweb.cgi?p=zsh/zsh;a=blob_plain;f=Completion/Unix/Command/_git;hb=HEAD'
if [[ ! -e "$completion_file" ]] && (( $+commands[git] )); then if [[ ! -e "$completion_file" ]] && (( $+commands[git] )); then

7
plugins/git/completions/_git-hub

@ -1,6 +1,13 @@
#compdef git-hub #compdef git-hub
#autoload #autoload
#
# Completes git-hub.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
local state remotes remote branches ret=1 local state remotes remote branches ret=1
_arguments -C -s -S \ _arguments -C -s -S \

7
plugins/git/completions/_git-info

@ -1,6 +1,13 @@
#compdef git-info #compdef git-info
#autoload #autoload
#
# Completes git-info.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
_arguments "1:toggle:(( _arguments "1:toggle:((
on\:'enable in-prompt information for the current repository' on\:'enable in-prompt information for the current repository'
off\:'disable in-prompt information for the current repository' off\:'disable in-prompt information for the current repository'

8
plugins/git/functions/git-branch

@ -1,4 +1,10 @@
# Gets the current branch. #
# Displays the current Git branch.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
local ref="$(git symbolic-ref HEAD 2> /dev/null)" local ref="$(git symbolic-ref HEAD 2> /dev/null)"
if [[ -n "$ref" ]]; then if [[ -n "$ref" ]]; then
print "${ref#refs/heads/}" print "${ref#refs/heads/}"

8
plugins/git/functions/git-hub

@ -1,4 +1,10 @@
# Open the GitHub repository in the browser. #
# Opens a GitHub repository in the default browser.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
local remote branches branch current_branch url local remote branches branch current_branch url
remote="${1:-origin}" remote="${1:-origin}"

7
plugins/git/functions/git-info

@ -1,3 +1,10 @@
#
# Displays Git repository information.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Gets the Git special action (am, merge, rebase, etc.). # Gets the Git special action (am, merge, rebase, etc.).
# Borrowed from vcs_info and edited. # Borrowed from vcs_info and edited.
function _git-action() { function _git-action() {

8
plugins/git/functions/git-root

@ -1,4 +1,10 @@
# Gets the repository root. #
# Displays the Git repository root.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
local root="$(git rev-parse --show-toplevel 2> /dev/null)" local root="$(git rev-parse --show-toplevel 2> /dev/null)"
if [[ -n "$root" ]]; then if [[ -n "$root" ]]; then
print "$root" print "$root"

10
plugins/git/hub.zsh

@ -1,5 +1,11 @@
# Hub by defunkt #
# https://github.com/defunkt/hub # Adds GitHub knowledge to the Git command.
#
# Authors:
# Chris Wanstrath <chris@wanstrath.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
if (( $+commands[hub] )); then if (( $+commands[hub] )); then
function git() { function git() {
hub "$@" hub "$@"

12
plugins/git/init.zsh

@ -1,9 +1,9 @@
# ------------------------------------------------------------------------------ #
# FILE: git.plugin.zsh # Provides Git aliases and functions.
# DESCRIPTION: oh-my-zsh plugin file. #
# AUTHOR: Sorin Ionescu <sorin.ionescu@gmail.com> # Authors:
# VERSION: 1.0.0 # Sorin Ionescu <sorin.ionescu@gmail.com>
# ------------------------------------------------------------------------------ #
# Source plugin files. # Source plugin files.
source "${0:h}/alias.zsh" source "${0:h}/alias.zsh"

7
plugins/git/style.zsh

@ -1,4 +1,9 @@
# The default styles. #
# Defines Git information display styles.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# %s - Special action name (am, merge, rebase). # %s - Special action name (am, merge, rebase).
zstyle ':omz:plugin:git:prompt' action 'action:%s' zstyle ':omz:plugin:git:prompt' action 'action:%s'

13
plugins/gnu-utils/init.zsh

@ -1,10 +1,9 @@
# ------------------------------------------------------------------------------ #
# FILE: gnu-utils.plugin.zsh # Provides for the interactive usage of GNU Coreutils on BSD systems.
# DESCRIPTION: oh-my-zsh plugin file. #
# AUTHOR: Sorin Ionescu <sorin.ionescu@gmail.com> # Authors:
# VERSION: 1.0.2 # Sorin Ionescu <sorin.ionescu@gmail.com>
# ------------------------------------------------------------------------------ #
if (( $+commands[gdircolors] )); then if (( $+commands[gdircolors] )); then
function __gnu_utils() { function __gnu_utils() {

8
plugins/gpg-agent/init.zsh

@ -1,4 +1,10 @@
# Based on ssh-agent code. #
# Provides for an easier use of gpg-agent.
#
# Authors:
# Florian Walch <florian.walch@gmx.at>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
local GPG_ENV="$HOME/.gnupg/gpg-agent.env" local GPG_ENV="$HOME/.gnupg/gpg-agent.env"

8
plugins/history-substring-search/init.zsh

@ -1,4 +1,10 @@
# This file integrates the history-substring-search script into oh-my-zsh. #
# Integrates history-substring-search into Oh My Zsh.
#
# Authors:
# Suraj N. Kurapati <sunaku@gmail.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
source "${0:h}/history-substring-search.zsh" source "${0:h}/history-substring-search.zsh"

7
plugins/macports/init.zsh

@ -1,3 +1,10 @@
#
# Defines MacPorts aliases.
#
# Authors:
# Matt Cable <wozz@wookie.net>
#
# Aliases # Aliases
alias pc="sudo port clean --all installed" alias pc="sudo port clean --all installed"
alias pi="sudo port install $1" alias pi="sudo port install $1"

8
plugins/node/functions/node-docs

@ -1,4 +1,10 @@
# Open the node api for your current version to the optional section. #
# Opens the Node.js online API documentation in the default browser.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# TODO: Make the sections easier to use. # TODO: Make the sections easier to use.
open "http://nodejs.org/docs/$(node --version | sed 's/-.*//')/api/all.html#${1}" open "http://nodejs.org/docs/$(node --version | sed 's/-.*//')/api/all.html#${1}"

8
plugins/node/init.zsh

@ -1,4 +1,10 @@
# Complete npm. #
# Completes npm.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
cache_file="${0:h}/cache.zsh" cache_file="${0:h}/cache.zsh"
if [[ ! -f "$cache_file" ]] && (( $+commands[npm] )); then if [[ ! -f "$cache_file" ]] && (( $+commands[npm] )); then
# npm is slow; cache its output. # npm is slow; cache its output.

8
plugins/osx/functions/manb

@ -1,4 +1,10 @@
# Open man pages in Bwana. #
# Opens man pages in Bwana.app.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
function manb() { function manb() {
local page local page
if (( $# > 0 )); then if (( $# > 0 )); then

8
plugins/osx/functions/manp

@ -1,4 +1,10 @@
# Open man pages in Preview. #
# Opens man pages in Preview.app.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
function manp() { function manp() {
local page local page
if (( $# > 0 )); then if (( $# > 0 )); then

7
plugins/osx/functions/pfd

@ -1,3 +1,10 @@
#
# Displays the current Finder.app directory.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
osascript 2>/dev/null <<EOF osascript 2>/dev/null <<EOF
tell application "Finder" tell application "Finder"
return POSIX path of (target of window 1 as alias) return POSIX path of (target of window 1 as alias)

7
plugins/osx/functions/pfs

@ -1,3 +1,10 @@
#
# Displays the current Finder.app selection.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
osascript 2>/dev/null <<EOF osascript 2>/dev/null <<EOF
set output to "" set output to ""
tell application "Finder" to set the_selection to selection tell application "Finder" to set the_selection to selection

7
plugins/osx/functions/tab

@ -1,3 +1,10 @@
#
# Opens a new Terminal.app/iTerm.app tab in the current directory.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
local command="cd \\\"$PWD\\\"" local command="cd \\\"$PWD\\\""
(( $# > 0 )) && command="${command}; $*" (( $# > 0 )) && command="${command}; $*"

7
plugins/osx/functions/trash

@ -1,3 +1,10 @@
#
# Moves directories and files to Trash.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
print -N "${@:a}" | xargs -0 osascript -e ' print -N "${@:a}" | xargs -0 osascript -e '
on run theFilePaths on run theFilePaths
tell application "Finder" tell application "Finder"

7
plugins/osx/init.zsh

@ -1,4 +1,9 @@
# Sorin Ionescu <sorin.ionescu@gmail.com> #
# Defines Mac OS X aliases and functions.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Change directory to the current Finder directory. # Change directory to the current Finder directory.
alias cdf='cd "$(pfd)"' alias cdf='cd "$(pfd)"'

9
plugins/pacman/functions/pacdisowned

@ -1,4 +1,11 @@
# List disowned files. #
# Lists pacman disowned files.
#
# Authors:
# Benjamin Boudreau <dreurmail@gmail.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
tmp="${TMPDIR-/tmp}/pacman-disowned-$UID-$$" tmp="${TMPDIR-/tmp}/pacman-disowned-$UID-$$"
db="$tmp/db" db="$tmp/db"
fs="$tmp/fs" fs="$tmp/fs"

9
plugins/pacman/functions/paclist

@ -1,4 +1,11 @@
# List explicitly installed packages. #
# Lists explicitly installed pacman packages.
#
# Authors:
# Benjamin Boudreau <dreurmail@gmail.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
sudo pacman -Qei $(pacman -Qu|cut -d" " -f 1) \ sudo pacman -Qei $(pacman -Qu|cut -d" " -f 1) \
| awk ' BEGIN {FS=":"}/^Name/{printf("\033[1;36m%s\033[1;37m", $2)}/^Description/{print $2}' | awk ' BEGIN {FS=":"}/^Name/{printf("\033[1;36m%s\033[1;37m", $2)}/^Description/{print $2}'

10
plugins/pacman/init.zsh

@ -1,7 +1,13 @@
# Arch Linux Zsh Aliases and Functions
# #
# Pacman Tips: # Defines pacman aliases.
#
# Authors:
# Benjamin Boudreau <dreurmail@gmail.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Tips:
# https://wiki.archlinux.org/index.php/Pacman_Tips # https://wiki.archlinux.org/index.php/Pacman_Tips
#
# Yaourt Aliases # Yaourt Aliases
if (( $+commands[yaourt] )); then if (( $+commands[yaourt] )); then

7
plugins/perl/completions/_prep

@ -1,6 +1,13 @@
#compdef prep #compdef prep
#autoload #autoload
#
# Completes prep.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
_arguments \ _arguments \
'-i[ignore case]' \ '-i[ignore case]' \
'-m[^ and $ match the start and the end of a line]' \ '-m[^ and $ match the start and the end of a line]' \

7
plugins/perl/completions/_psub

@ -1,6 +1,13 @@
#compdef psub #compdef psub
#autoload #autoload
#
# Completes psub.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
_arguments \ _arguments \
'-g[match globally]' \ '-g[match globally]' \
'-i[ignore case]' \ '-i[ignore case]' \

7
plugins/perl/functions/prep

@ -1,4 +1,9 @@
# Perl Grep #
# Provides a grep-like pattern search.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
local usage pattern modifiers invert local usage pattern modifiers invert

7
plugins/perl/functions/psub

@ -1,4 +1,9 @@
# Perl Substitution #
# Provides a sed-like pattern substitution.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
local usage pattern replacement modifiers local usage pattern replacement modifiers

7
plugins/perl/init.zsh

@ -1,3 +1,10 @@
#
# Enables local Perl module installation on Mac OS X and defines aliases.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# For Perl older than 5.10.14, install local::lib. # For Perl older than 5.10.14, install local::lib.
# curl -L -C - -O http://search.cpan.org/CPAN/authors/id/A/AP/APEIRON/local-lib-1.008004.tar.gz # curl -L -C - -O http://search.cpan.org/CPAN/authors/id/A/AP/APEIRON/local-lib-1.008004.tar.gz
# tar xvf local-lib-1.008004.tar.gz # tar xvf local-lib-1.008004.tar.gz

7
plugins/python/init.zsh

@ -1,3 +1,10 @@
#
# Enables local Python package installation.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Prepend PEP 370 per user site packages directory, which defaults to # Prepend PEP 370 per user site packages directory, which defaults to
# ~/Library/Python on Mac OS X and ~/.local elsewhere, to PATH/MANPATH. # ~/Library/Python on Mac OS X and ~/.local elsewhere, to PATH/MANPATH.
if [[ "$OSTYPE" == darwin* ]]; then if [[ "$OSTYPE" == darwin* ]]; then

9
plugins/rails/init.zsh

@ -1,3 +1,12 @@
#
# Defines Ruby on Rails aliases.
#
# Authors:
# Robby Russell <robby@planetargon.com>
# Jake Bell <jake.b.bell@gmail.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Aliases (compatible with Rails 2) # Aliases (compatible with Rails 2)
alias rc='_rails-command console' alias rc='_rails-command console'
alias rd='_rails-command destroy' alias rd='_rails-command destroy'

7
plugins/rsync/init.zsh

@ -1,3 +1,10 @@
#
# Defines rsync aliases.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Aliases # Aliases
rsync_cmd='rsync --verbose --progress --human-readable --compress --archive --hard-links --one-file-system' rsync_cmd='rsync --verbose --progress --human-readable --compress --archive --hard-links --one-file-system'

7
plugins/ruby/init.zsh

@ -1,3 +1,10 @@
#
# Configures Ruby gem installation and loads rvm/rbenv.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Install local gems according to Mac OS X conventions. # Install local gems according to Mac OS X conventions.
if [[ "$OSTYPE" == darwin* ]]; then if [[ "$OSTYPE" == darwin* ]]; then
export GEM_HOME="$HOME/Library/Ruby/Gems/${$(ruby --version)[6,8]}" export GEM_HOME="$HOME/Library/Ruby/Gems/${$(ruby --version)[6,8]}"

12
plugins/screen/init.zsh

@ -1,9 +1,9 @@
# ------------------------------------------------------------------------------ #
# FILE: screen.plugin.zsh # Defines GNU Screen aliases and provides for auto launching it at startup.
# DESCRIPTION: oh-my-zsh plugin file. #
# AUTHOR: Sorin Ionescu <sorin.ionescu@gmail.com> # Authors:
# VERSION: 1.0.0 # Sorin Ionescu <sorin.ionescu@gmail.com>
# ------------------------------------------------------------------------------ #
# Aliases # Aliases
alias sl="screen -list" alias sl="screen -list"

29
plugins/ssh-agent/init.zsh

@ -1,24 +1,23 @@
# #
# INSTRUCTIONS # Provides for an easier use of ssh-agent.
# #
# To enabled agent forwarding support, add the following to # Authors:
# your .zshrc file: # Robby Russell <robby@planetargon.com>
# Theodore Robert Campbell Jr <trcjr@stupidfoot.com>
# Joseph M. Reagle Jr. <reagle@mit.edu>
# Florent Thoumie <flz@xbsd.org>
# Jonas Pfenniger <jonas@pfenniger.name>
# gwjo <gowen72@gmail.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
# #
# zstyle ':omz:plugin:ssh-agent' forwarding 'on' # Usage:
# To enable agent forwarding, add the following to your .zshrc:
# #
# To load multiple identies, use the identities style, For # zstyle ':omz:plugin:ssh-agent' forwarding 'yes'
# example:
# #
# zstyle ':omz:plugin:ssh-agent' identities 'id_rsa' 'id_rsa2' 'id_github' # To load multiple identies, add the following to your .zshrc:
#
#
# CREDITS
# #
# Based on code from Joseph M. Reagle # zstyle ':omz:plugin:ssh-agent' identities 'id_rsa' 'id_rsa2' 'id_github'
# http://www.cygwin.com/ml/cygwin/2001-06/msg00537.html
#
# Agent forwarding support based on ideas from
# Florent Thoumie and Jonas Pfenniger
# #
_ssh_agent_env="$HOME/.ssh/environment-$HOST" _ssh_agent_env="$HOME/.ssh/environment-$HOST"

12
plugins/tmux/init.zsh

@ -1,9 +1,9 @@
# ------------------------------------------------------------------------------ #
# FILE: tmux.plugin.zsh # Defines tmux aliases and provides for auto launching it at startup.
# DESCRIPTION: oh-my-zsh plugin file. #
# AUTHOR: Sorin Ionescu <sorin.ionescu@gmail.com> # Authors:
# VERSION: 1.0.0 # Sorin Ionescu <sorin.ionescu@gmail.com>
# ------------------------------------------------------------------------------ #
# Aliases # Aliases
alias ta="tmux attach-session" alias ta="tmux attach-session"

8
plugins/wakeonlan/completions/_wake

@ -1,5 +1,13 @@
#compdef wake #compdef wake
#autoload #autoload
#
# Completes wake.
#
# Authors:
# Paul Gideon Dann <pdgiddie@gmail.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
_arguments "1:device to wake:_files -W '$HOME/.wakeonlan'" && return 0 _arguments "1:device to wake:_files -W '$HOME/.wakeonlan'" && return 0

8
plugins/wakeonlan/functions/wake

@ -1,3 +1,11 @@
#
# Wakes devices via wakeonlan.
#
# Authors:
# Paul Gideon Dann <pdgiddie@gmail.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
local config_file="$HOME/.wakeonlan/$1" local config_file="$HOME/.wakeonlan/$1"
if [[ ! -f "$config_file" ]]; then if [[ ! -f "$config_file" ]]; then
print "$0: no such device file: $1" >&2 print "$0: no such device file: $1" >&2

8
plugins/yum/init.zsh

@ -1,3 +1,11 @@
#
# Defines yum aliases.
#
# Authors:
# Simon <contact@saimon.org>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Aliases # Aliases
alias ys="yum search" # Search package. alias ys="yum search" # Search package.
alias yp="yum info" # Show package info. alias yp="yum info" # Show package info.

16
plugins/z/init.zsh

@ -1,13 +1,9 @@
# ------------------------------------------------------------------------------ #
# FILE: z.plugin.zsh # Maintains a frequently used directory list for fast directory changes.
# DESCRIPTION: oh-my-zsh plugin file. #
# AUTHOR: Sorin Ionescu <sorin.ionescu@gmail.com> # Authors:
# VERSION: 1.0.0 # Sorin Ionescu <sorin.ionescu@gmail.com>
# ------------------------------------------------------------------------------ #
# z is the new j.
# https://github.com/rupa/z
if [[ -f /etc/profile.d/z.zsh ]]; then if [[ -f /etc/profile.d/z.zsh ]]; then
source /etc/profile.d/z.zsh source /etc/profile.d/z.zsh

10
spectrum.zsh

@ -1,6 +1,10 @@
# A script to make using 256 colors in Zsh less painful. #
# P.C. Shyamshankar <sykora@lucentbeing.com> # Provides for easier formatting and use of 256 colors.
# Sorin Ionescu <sorin.ionescu@gmail.com> #
# Authors:
# P.C. Shyamshankar <sykora@lucentbeing.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
typeset -Ag FX FG BG typeset -Ag FX FG BG

7
templates/zshrc.zsh

@ -1,3 +1,10 @@
#
# Sets Oh My Zsh options.
#
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Set the key mapping style to 'emacs' or 'vi'. # Set the key mapping style to 'emacs' or 'vi'.
zstyle ':omz:editor' keymap 'emacs' zstyle ':omz:editor' keymap 'emacs'

8
terminal.zsh

@ -1,3 +1,11 @@
#
# Sets terminal window and tab titles.
#
# Authors:
# James Cox <james@imaj.es>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Dumb terminals lack support. # Dumb terminals lack support.
if [[ "$TERM" == 'dumb' ]]; then if [[ "$TERM" == 'dumb' ]]; then
return return

8
themes/minimal/prompt_minimal_setup

@ -1,3 +1,11 @@
#
# A monochrome theme that displays basic information.
#
# Authors:
# Brian Tse <briankftse@gmail.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
function +vi-git-status() { function +vi-git-status() {
# Untracked files. # Untracked files.
if [[ -n $(git ls-files --other --exclude-standard 2> /dev/null) ]]; then if [[ -n $(git ls-files --other --exclude-standard 2> /dev/null) ]]; then

26
themes/nicoulaj/prompt_nicoulaj_setup

@ -1,14 +1,20 @@
# ------------------------------------------------------------------------------ #
# Prompt for Zsh: # A simple theme that displays only relevant information.
# * One line. #
# * VCS info on the right prompt. # Authors:
# * Only shows the path on the left prompt by default. # Julien Nicoulaud <julien.nicoulaud@gmail.com>
# * Crops the path to a defined length and only shows the path relative to # Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Features:
# - One line.
# - VCS information in the right prompt.
# - Only shows the path on the left prompt by default.
# - Crops the path to a defined length and only shows the path relative to
# the current VCS repository root. # the current VCS repository root.
# * Wears a different color wether the last command succeeded/failed. # - Uses a different color depending on if the last command succeeded/failed.
# * Shows user@hostname if connected through SSH. # - Shows user@hostname if connected through SSH.
# * Shows if logged in as root or not. # - Shows if logged in as root or not.
# ------------------------------------------------------------------------------ #
function prompt_nicoulaj_setup() { function prompt_nicoulaj_setup() {
setopt LOCAL_OPTIONS setopt LOCAL_OPTIONS

17
themes/sorin/prompt_sorin_setup

@ -1,10 +1,13 @@
# ------------------------------------------------------------------------------ #
# FILE: prompt_sorin_setup # A simple theme that only shows relevant information.
# DESCRIPTION: oh-my-zsh theme file. #
# AUTHOR: Sorin Ionescu <sorin.ionescu@gmail.com> # Authors:
# VERSION: 1.0.6 # Sorin Ionescu <sorin.ionescu@gmail.com>
# SCREENSHOT: http://i.imgur.com/aipDQ.png #
# ------------------------------------------------------------------------------ # Screenshots:
# http://i.imgur.com/aipDQ.png
#
function prompt_sorin_precmd () { function prompt_sorin_precmd () {
setopt LOCAL_OPTIONS setopt LOCAL_OPTIONS
unsetopt XTRACE KSH_ARRAYS unsetopt XTRACE KSH_ARRAYS

14
themes/steeef/prompt_steeef_setup

@ -1,11 +1,13 @@
# Prompt style and colors based on Steve Losh's Prose theme:
# http://github.com/sjl/oh-my-zsh/blob/master/themes/prose.zsh-theme
# #
# vcs_info modifications from Bart Trojanowski's Zsh prompt: # A theme based on Steve Losh's prompt with VCS_INFO integration.
# http://www.jukie.net/bart/blog/pimping-out-zsh-prompt #
# Authors:
# Steve Losh <steve@stevelosh.com>
# Bart Trojanowski <bart@jukie.net>
# Brian Carper <brian@carper.ca>
# steeef <steeef@gmail.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
# #
# Git untracked files modification from Brian Carper:
# http://briancarper.net/blog/570/git-info-in-your-zsh-prompt
function virtualenv_info() { function virtualenv_info() {
if [[ -n "$VIRTUAL_ENV" ]]; then if [[ -n "$VIRTUAL_ENV" ]]; then

9
utility.zsh

@ -1,3 +1,12 @@
#
# Defines utility functions.
#
# Authors:
# Robby Russell <robby@planetargon.com>
# Suraj N. Kurapati <sunaku@gmail.com>
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
# Lists the ten most used commands. # Lists the ten most used commands.
alias history-stat="history | awk '{print \$2}' | sort | uniq -c | sort -n -r | head" alias history-stat="history | awk '{print \$2}' | sort | uniq -c | sort -n -r | head"

Loading…
Cancel
Save