Permalink
Browse files

Merge branch 'master' of github.com:sorin-ionescu/oh-my-zsh

  • Loading branch information...
2 parents 6e727ca + 10ab5e2 commit d282b096c85526c28bbd5c4a5a907b0175e15f4f @vguerci committed Apr 16, 2012
@@ -0,0 +1,34 @@
+Directory
+=========
+
+Sets directory options and defines directory aliases.
+
+Options
+-------
+
+ - `AUTO_CD` auto cd to a directory without typing `cd`.
+ - `AUTO_PUSHD` push the old directory onto the stack on `cd`.
+ - `PUSHD_IGNORE_DUPS` don't store duplicates in the stack.
+ - `PUSHD_SILENT` do not print the directory stack after `pushd` or `popd`.
+ - `PUSHD_TO_HOME` push to home directory when no argument is given.
+ - `CDABLE_VARS` change directory to a path stored in a variable.
+ - `AUTO_NAME_DIRS` auto add variable-stored paths to `~` list.
+ - `MULTIOS` write to multiple descriptors.
+ - `EXTENDED_GLOB` use extended globbing syntax.
+ - `CLOBBER` don't overwrite existing files with `>` and `>>`. Use `>!` and
+ `>>!` to bypass.
+
+Aliases
+-------
+
+ - `d` print the contents of the directory stack.
+ - `1 ... 9` change directory to the **n** previous one.
+
+Authors
+-------
+
+*The authors of this module should be contacted via the GitHub issue tracker.*
+
+ - [James Cox](/imajes)
+ - [Sorin Ionescu](/sorin-ionescu)
+
View
@@ -17,6 +17,8 @@ alias gbx='git branch -d'
alias gbX='git branch -D'
alias gbm='git branch -m'
alias gbM='git branch -M'
+alias gbs='git show-branch'
+alias gbS='git show-branch -a'
# Commit (c)
alias gc='git commit'
@@ -22,14 +22,17 @@
# # %b - Branch name.
# zstyle ':omz:module:git' branch 'branch:%b'
#
+# # %C - Indicator to notify of a clean working directory.
+# zstyle ':omz:module:git' clean 'clean'
+#
# # %c - SHA-1 hash.
# zstyle ':omz:module:git' commit 'commit:%c'
#
# # %d - Indicator to notify of deleted files.
# zstyle ':omz:module:git' deleted 'deleted:%d'
#
# # %D - Indicator to notify of dirty files.
-# zstyle ':omz:module:git' dirty '%(D.clean.dirty:%D)'
+# zstyle ':omz:module:git' dirty 'dirty:%D'
#
# # %m - Indicator to notify of modified files.
# zstyle ':omz:module:git' modified 'modified:%m'
@@ -57,7 +60,7 @@
#
# # Prompts.
# zstyle ':omz:module:git' info \
-# 'prompt' ' git:(%b%D)' \
+# 'prompt' ' git:(%b%C%D)' \
# 'rprompt' ''
#
@@ -186,6 +189,8 @@ function git-info {
local branch_format
local branch_formatted
local branch_info
+ local clean
+ local clean_formatted
local commit
local commit_format
local commit_formatted
@@ -375,9 +380,13 @@ function git-info {
zformat -f untracked_formatted "$untracked_format" "u:$untracked"
fi
- # Format dirty.
- zstyle -s ':omz:module:git' dirty 'dirty_format'
- zformat -f dirty_formatted "$dirty_format" "D:$dirty"
+ # Format dirty and clean.
+ if (( $dirty > 0 )); then
+ zstyle -s ':omz:module:git' dirty 'dirty_format'
+ zformat -f dirty_formatted "$dirty_format" "D:$dirty"
+ else
+ zstyle -s ':omz:module:git' clean 'clean_formatted'
+ fi
# Format info.
zstyle -a ':omz:module:git' info 'info_formats'
@@ -391,6 +400,7 @@ function git-info {
"U:$unmerged_formatted" \
"a:$added_formatted" \
"b:$branch_formatted" \
+ "C:$clean_formatted" \
"c:$commit_formatted" \
"d:$deleted_formatted" \
"m:$modified_formatted" \
View
@@ -0,0 +1,44 @@
+History
+=======
+
+Sets [history][1] options and defines history aliases.
+
+VARIABLES
+---------
+
+ - `HISTFILE` the file to save the history in when an interactive shell exits.
+ - `HISTSIZE` the maximum size of the history list.
+ - `SAVEHIST` the maximum number of history events to save in the history file.
+
+Options
+-------
+
+ - `BANG_HIST` treat the **!** character specially during expansion.
+ - `EXTENDED_HISTORY` write the history file in the *:start:elapsed;command* format.
+ - `INC_APPEND_HISTORY` write to the history file immediately, not when the shell exits.
+ - `SHARE_HISTORY` share history between all sessions.
+ - `HIST_EXPIRE_DUPS_FIRST` expire duplicate entries first when trimming history.
+ - `HIST_IGNORE_DUPS` do not record an entry that was just recorded again.
+ - `HIST_IGNORE_ALL_DUPS` delete old recorded entry if new entry is a duplicate.
+ - `HIST_FIND_NO_DUPS` do not display a line previously found.
+ - `HIST_IGNORE_SPACE` do not record an entry starting with a space.
+ - `HIST_SAVE_NO_DUPS` do not write duplicate entries in the history file.
+ - `HIST_REDUCE_BLANKS` remove superfluous blanks before recording entry.
+ - `HIST_VERIFY` do not execute immediately upon history expansion.
+ - `HIST_BEEP` beep when accessing non-existent history.
+
+Aliases
+-------
+
+ - `history-stat` list the ten most used commands
+
+Authors
+-------
+
+*The authors of this module should be contacted via the GitHub issue tracker.*
+
+ - [Robby Russell](/robbyrussell)
+ - [Sorin Ionescu](/sorin-ionescu)
+
+[1]: http://zsh.sourceforge.net/Guide/zshguide02.html#l16
+
View
@@ -1,5 +1,5 @@
#
-# Sets history options.
+# Sets history options and defines history aliases.
#
# Authors:
# Robby Russell <robby@planetargon.com>
@@ -11,18 +11,18 @@ HISTSIZE=10000
SAVEHIST=10000
setopt BANG_HIST # Treat the '!' character specially during expansion.
-setopt EXTENDED_HISTORY # Write the history file in the ":start:elapsed;command" format.
+setopt EXTENDED_HISTORY # Write the history file in the ':start:elapsed;command' format.
setopt INC_APPEND_HISTORY # Write to the history file immediately, not when the shell exits.
setopt SHARE_HISTORY # Share history between all sessions.
setopt HIST_EXPIRE_DUPS_FIRST # Expire duplicate entries first when trimming history.
-setopt HIST_IGNORE_DUPS # Don't record an entry that was just recorded again.
+setopt HIST_IGNORE_DUPS # Do not record an entry that was just recorded again.
setopt HIST_IGNORE_ALL_DUPS # Delete old recorded entry if new entry is a duplicate.
setopt HIST_FIND_NO_DUPS # Do not display a line previously found.
-setopt HIST_IGNORE_SPACE # Don't record an entry starting with a space.
-setopt HIST_SAVE_NO_DUPS # Don't write duplicate entries in the history file.
+setopt HIST_IGNORE_SPACE # Do not record an entry starting with a space.
+setopt HIST_SAVE_NO_DUPS # Do not write duplicate entries in the history file.
setopt HIST_REDUCE_BLANKS # Remove superfluous blanks before recording entry.
-setopt HIST_VERIFY # Don't execute immediately upon history expansion.
-setopt HIST_BEEP # Beep when accessing nonexistent history.
+setopt HIST_VERIFY # Do not execute immediately upon history expansion.
+setopt HIST_BEEP # Beep when accessing non-existent history.
# Aliases
View
@@ -0,0 +1,23 @@
+Prompt
+======
+
+Loads prompt [themes][1].
+
+Settings
+--------
+
+To select a prompt theme, add the following to *zshrc*, and replace **name** with the
+name of the theme you wish to load. Setting it to **random** will load a random
+theme.
+
+ zstyle ':omz:module:prompt' theme 'name'
+
+Authors
+-------
+
+*The authors of this module should be contacted via the GitHub issue tracker.*
+
+ - [Sorin Ionescu](/sorin-ionescu)
+
+[1]: http://zsh.sourceforge.net/Doc/Release/User-Contributions.html#Prompt-Themes
+
View
@@ -4,13 +4,6 @@
# Authors:
# Sorin Ionescu <sorin.ionescu@gmail.com>
#
-# Usage:
-# To select a prompt theme, add the following to zshrc, and replace 'name'
-# with the name of the theme you wish to load. Setting it to random will load
-# a random theme.
-#
-# zstyle ':omz:module:prompt' theme 'name'
-#
# Load and run the prompt theming system.
autoload -Uz promptinit && promptinit

0 comments on commit d282b09

Please sign in to comment.