From 80782afecac1876a90b6efdf93adbcb8b246ca9a Mon Sep 17 00:00:00 2001 From: Carlos Cardoso Date: Sat, 22 Mar 2014 22:53:30 -0300 Subject: [PATCH 1/4] New git aliases. --- templates/zshrc-linux.zsh | 6 ++++++ templates/zshrc-mac.zsh | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/templates/zshrc-linux.zsh b/templates/zshrc-linux.zsh index 4fb6b37fb..dd1afe86e 100644 --- a/templates/zshrc-linux.zsh +++ b/templates/zshrc-linux.zsh @@ -49,6 +49,12 @@ if [ -e $HOME/.cabal/bin ]; then export PATH="$HOME/.cabal/bin:$PATH"; fi alias ta='tmux attach -t' alias tl='tmux list-session' alias ts='tmux new-session' +# Git aliases +alias gita='git add -A' +alias gits='git status' +alias gitl='git l' +alias gitw='git who' +alias gitt='git tags' source $ZSH/oh-my-zsh.sh unsetopt correctall diff --git a/templates/zshrc-mac.zsh b/templates/zshrc-mac.zsh index a34c6ba99..1bda5e370 100644 --- a/templates/zshrc-mac.zsh +++ b/templates/zshrc-mac.zsh @@ -48,6 +48,12 @@ if [ -z "$LANG" ]; then export LANG=en_US.UTF-8; fi alias ta='tmux attach -t' alias tl='tmux list-session' alias ts='tmux new-session' +# Git aliases +alias gita='git add -A' +alias gits='git status' +alias gitl='git l' +alias gitw='git who' +alias gitt='git tags' # Compilation flags # export ARCHFLAGS="-arch x86_64" From eff8820e29d1df917afb233d91b583eb3c056e5b Mon Sep 17 00:00:00 2001 From: Carlos Cardoso Date: Sun, 23 Mar 2014 19:28:27 -0300 Subject: [PATCH 2/4] Unified aliases in oh-my-zsh aliases file. --- lib/aliases.zsh | 13 +++++++++---- templates/zshrc-linux.zsh | 11 ----------- templates/zshrc-mac.zsh | 11 ----------- 3 files changed, 9 insertions(+), 26 deletions(-) diff --git a/lib/aliases.zsh b/lib/aliases.zsh index b0de2173b..518babfbc 100644 --- a/lib/aliases.zsh +++ b/lib/aliases.zsh @@ -26,6 +26,7 @@ else alias history='fc -l 1' fi +alias afind='ack-grep -il' # List direcory contents alias lsa='ls -lah' alias l='ls -la' @@ -33,9 +34,13 @@ alias ll='ls -l' alias la='ls -lA' alias l=la alias sl=ls # often screw this up - -alias afind='ack-grep -il' - # Git aliases +alias gita='git add -A' alias gits='git st' -alias gitk='gitk --all &' +alias gitl='git l' +alias gitw='git who' +alias gitt='git tags' +# Aliases +alias ta='tmux attach -t' +alias tl='tmux list-session' +alias ts='tmux new-session' diff --git a/templates/zshrc-linux.zsh b/templates/zshrc-linux.zsh index dd1afe86e..e625e5ded 100644 --- a/templates/zshrc-linux.zsh +++ b/templates/zshrc-linux.zsh @@ -45,16 +45,5 @@ if [ -e $HOME/.cabal/bin ]; then export PATH="$HOME/.cabal/bin:$PATH"; fi [ "$TERM" = "xterm" ] && TERM="xterm-256color" -# Aliases -alias ta='tmux attach -t' -alias tl='tmux list-session' -alias ts='tmux new-session' -# Git aliases -alias gita='git add -A' -alias gits='git status' -alias gitl='git l' -alias gitw='git who' -alias gitt='git tags' - source $ZSH/oh-my-zsh.sh unsetopt correctall diff --git a/templates/zshrc-mac.zsh b/templates/zshrc-mac.zsh index 1bda5e370..97282c898 100644 --- a/templates/zshrc-mac.zsh +++ b/templates/zshrc-mac.zsh @@ -44,17 +44,6 @@ export EDITOR='vim' if [ -z "$LC_ALL" ]; then export LC_ALL=en_US.UTF-8; fi if [ -z "$LANG" ]; then export LANG=en_US.UTF-8; fi -# Aliases -alias ta='tmux attach -t' -alias tl='tmux list-session' -alias ts='tmux new-session' -# Git aliases -alias gita='git add -A' -alias gits='git status' -alias gitl='git l' -alias gitw='git who' -alias gitt='git tags' - # Compilation flags # export ARCHFLAGS="-arch x86_64" From c31f9e6f0959a5bae2004f0830551653a44dd525 Mon Sep 17 00:00:00 2001 From: Carlos Cardoso Date: Sun, 23 Mar 2014 20:18:19 -0300 Subject: [PATCH 3/4] Cleanup .orig files. --- README.textile.orig | 118 ------------------------------------------ lib/aliases.zsh.orig | 52 ------------------- tools/install.sh.orig | 51 ------------------ 3 files changed, 221 deletions(-) delete mode 100644 README.textile.orig delete mode 100644 lib/aliases.zsh.orig delete mode 100755 tools/install.sh.orig diff --git a/README.textile.orig b/README.textile.orig deleted file mode 100644 index ca0975029..000000000 --- a/README.textile.orig +++ /dev/null @@ -1,118 +0,0 @@ -!https://s3.amazonaws.com/ohmyzsh/oh-my-zsh-logo.png! - -oh-my-zsh is an open source, community-driven framework for managing your ZSH configuration. It comes bundled with a ton of helpful functions, helpers, plugins, themes, and few things that make you shout... - -bq. "OH MY ZSHELL!" - -h2. Setup - -@oh-my-zsh@ should work with any recent release of "zsh":http://www.zsh.org/, the minimum recommended version is 4.3.9. - -h3. The automatic installer... (do you trust me?) - -You can install this via the command line with either `curl` or `wget`. - -h4. via `curl` - -<<<<<<< HEAD -@curl -L https://github.com/cadusk/oh-my-zsh/raw/master/tools/install.sh | sh@ - -h4. via `wget` - -@wget --no-check-certificate https://github.com/cadusk/oh-my-zsh/raw/master/tools/install.sh -O - | sh@ -======= -@curl -L http://install.ohmyz.sh | sh@ - -h4. via `wget` - -@wget --no-check-certificate http://install.ohmyz.sh -O - | sh@ ->>>>>>> blessed-master - -h4. Optional: change the install directory - -The default location is `~/.oh-my-zsh` (hidden in your home directory). - -You can change the install directory with the ZSH environment variable, either -by running `export ZSH=/your/path` before installing, or setting it before the -end of the install pipeline like this: - -@curl -L https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh | ZSH=~/.dotfiles/zsh sh@ - - -h3. The manual way - -1. Clone the repository - - @git clone git://github.com/cadusk/oh-my-zsh.git ~/.oh-my-zsh@ - -2. *OPTIONAL* Backup your existing ~/.zshrc file - - @cp ~/.zshrc ~/.zshrc.orig@ - -3. Create a new zsh config by copying the zsh template we've provided. - - @cp ~/.oh-my-zsh/templates/zshrc.zsh-template ~/.zshrc@ - -4. Set zsh as your default shell: - - @chsh -s /bin/zsh@ - -5. Start / restart zsh (open a new terminal is easy enough...) - -h3. Problems? - -You _might_ need to modify your PATH in ~/.zshrc if you're not able to find some commands after switching to _Oh My Zsh_. - -If you installed manually or changed the install location, check ZSH in ~/.zshrc - -h2. Usage - -* enable the plugins you want in your @~/.zshrc@ (take a look at the @plugins/@ directory and the "wiki":https://github.com/robbyrussell/oh-my-zsh/wiki/Plugins to see what's possible) -** example: @plugins=(git osx ruby)@ -* Theme support: Change the @ZSH_THEME@ environment variable in @~/.zshrc@. -** Take a look at the "current themes":https://wiki.github.com/cadusk/oh-my-zsh/themes that come bundled with _Oh My Zsh_. -* much much more... take a look at @lib/@ what _Oh My Zsh_ offers... - -h2. Useful - -the "refcard":http://www.bash2zsh.com/zsh_refcard/refcard.pdf is pretty tasty for tips. - -h3. Customization - -If you want to override any of the default behavior, just add a new file (ending in @.zsh@) into the @custom/@ directory. -If you have many functions which go well together you can put them as a *.plugin.zsh file in the @custom/plugins/@ directory and then enable this plugin. -If you would like to override the functionality of a plugin distributed with oh-my-zsh, create a plugin of the same name in the @custom/plugins/@ directory and it will be loaded instead of the one in @plugins/@. - -h3. Updates - -By default you will be prompted to check for updates. If you would like oh-my-zsh to automatically update itself without prompting you, set the following in your ~/.zshrc - -@DISABLE_UPDATE_PROMPT=true@ - -To disable updates entirely, put this in your ~/.zshrc - -@DISABLE_AUTO_UPDATE=true@ - -To upgrade directly from the command line, just run @upgrade_oh_my_zsh@ - -h3. Uninstalling - -If you want to uninstall it, just run @uninstall_oh_my_zsh@ from the command line and it'll remove itself and revert you to bash (or your previous zsh config). - -h2. Help out! - -I'm far from being a zsh-expert and suspect there are many ways to improve. If you have ideas on how to make the configuration easier to maintain (and faster), don't hesitate to fork and send pull requests! - -h3. (Don't) Send us your theme! (for now) - --I'm hoping to collect a bunch of themes for our command prompts. You can see existing ones in the @themes/@ directory.- - -We have enough themes for the time being. Please fork the project and add on in there, you can let people know how to grab it from there. - -h2. Contributors - -This project wouldn't exist without all of our awesome users and contributors. - -* "View our growing list of contributors":https://github.com/cadusk/oh-my-zsh/contributors - -Thank you so much! diff --git a/lib/aliases.zsh.orig b/lib/aliases.zsh.orig deleted file mode 100644 index e59505b78..000000000 --- a/lib/aliases.zsh.orig +++ /dev/null @@ -1,52 +0,0 @@ -# Push and pop directories on directory stack -alias pu='pushd' -alias po='popd' - -# Basic directory operations -alias ...='cd ../..' -alias -- -='cd -' - -# Super user -alias _='sudo' -alias please='sudo' - -#alias g='grep -in' - -# Show history -if [ "$HIST_STAMPS" = "mm/dd/yyyy" ] -then - alias history='fc -fl 1' -elif [ "$HIST_STAMPS" = "dd.mm.yyyy" ] -then - alias history='fc -El 1' -elif [ "$HIST_STAMPS" = "yyyy-mm-dd" ] -then - alias history='fc -il 1' -else - alias history='fc -l 1' -fi - -alias afind='ack-grep -il' -# List direcory contents -alias lsa='ls -lah' -<<<<<<< HEAD -alias l='ls -la' -alias ll='ls -l' -alias la='ls -lA' -alias l=la -======= -alias l='ls -lah' -alias ll='ls -lh' -alias la='ls -lAh' ->>>>>>> blessed-master -alias sl=ls # often screw this up -# Git aliases -alias gita='git add -A' -alias gits='git st' -alias gitl='git l' -alias gitw='git who' -alias gitt='git tags' -# Aliases -alias ta='tmux attach -t' -alias tl='tmux list-session' -alias ts='tmux new-session' diff --git a/tools/install.sh.orig b/tools/install.sh.orig deleted file mode 100755 index 5f37f02aa..000000000 --- a/tools/install.sh.orig +++ /dev/null @@ -1,51 +0,0 @@ -set -e - -if [ ! -n "$ZSH" ]; then - ZSH=~/.oh-my-zsh -fi - -if [ -d "$ZSH" ]; then - echo "\033[0;33mYou already have Oh My Zsh installed.\033[0m You'll need to remove $ZSH if you want to install" - exit -fi - -echo "\033[0;34mCloning Oh My Zsh...\033[0m" -<<<<<<< HEAD -hash git >/dev/null && /usr/bin/env git clone https://github.com/cadusk/oh-my-zsh.git ~/.oh-my-zsh || { -======= -hash git >/dev/null && /usr/bin/env git clone https://github.com/robbyrussell/oh-my-zsh.git $ZSH || { ->>>>>>> blessed-master - echo "git not installed" - exit -} - -echo "\033[0;34mLooking for an existing zsh config...\033[0m" -if [ -f ~/.zshrc ] || [ -h ~/.zshrc ]; then - echo "\033[0;33mFound ~/.zshrc.\033[0m \033[0;32mBacking up to ~/.zshrc.pre-oh-my-zsh\033[0m"; - mv ~/.zshrc ~/.zshrc.pre-oh-my-zsh; -fi - -echo "\033[0;34mUsing the Oh My Zsh template file and adding it to ~/.zshrc\033[0m" -cp $ZSH/templates/zshrc.zsh-template ~/.zshrc -sed -i -e "/^ZSH=/ c\\ -ZSH=$ZSH -" ~/.zshrc - -echo "\033[0;34mCopying your current PATH and adding it to the end of ~/.zshrc for you.\033[0m" -sed -i -e "/export PATH=/ c\\ -export PATH=\"$PATH\" -" ~/.zshrc - -echo "\033[0;34mTime to change your default shell to zsh!\033[0m" -chsh -s `which zsh` - -echo "\033[0;32m"' __ __ '"\033[0m" -echo "\033[0;32m"' ____ / /_ ____ ___ __ __ ____ _____/ /_ '"\033[0m" -echo "\033[0;32m"' / __ \/ __ \ / __ `__ \/ / / / /_ / / ___/ __ \ '"\033[0m" -echo "\033[0;32m"'/ /_/ / / / / / / / / / / /_/ / / /_(__ ) / / / '"\033[0m" -echo "\033[0;32m"'\____/_/ /_/ /_/ /_/ /_/\__, / /___/____/_/ /_/ '"\033[0m" -echo "\033[0;32m"' /____/ ....is now installed!'"\033[0m" -echo "\n\n \033[0;32mPlease look over the ~/.zshrc file to select plugins, themes, and options.\033[0m" -echo "\n\n \033[0;32mp.s. Follow us at http://twitter.com/ohmyzsh.\033[0m" -/usr/bin/env zsh -. ~/.zshrc From cde788ed194603be4de5464433b835f3d098320c Mon Sep 17 00:00:00 2001 From: Carlos Cardoso Date: Sun, 23 Mar 2014 23:36:11 -0300 Subject: [PATCH 4/4] added git-fast to oh-my-zsh startup config --- templates/zshrc-linux.zsh | 2 +- templates/zshrc-mac.zsh | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/templates/zshrc-linux.zsh b/templates/zshrc-linux.zsh index e625e5ded..97ec10e11 100644 --- a/templates/zshrc-linux.zsh +++ b/templates/zshrc-linux.zsh @@ -33,7 +33,7 @@ DISABLE_VENV_CD="1" # Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*) # Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/ # Example format: plugins=(rails git textmate ruby lighthouse) -plugins=(git tmux debian python virtualenvwrapper) +plugins=(git gitfast tmux debian python virtualenvwrapper) # Customize to your needs... if [ -z "$LC_ALL" ]; then export LC_ALL=en_US.UTF-8; fi diff --git a/templates/zshrc-mac.zsh b/templates/zshrc-mac.zsh index 97282c898..2a1895e60 100644 --- a/templates/zshrc-mac.zsh +++ b/templates/zshrc-mac.zsh @@ -33,7 +33,7 @@ DISABLE_VENV_CD="1" # Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*) # Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/ # Example format: plugins=(rails git textmate ruby lighthouse) -plugins=(git postgres tmux python vim-override virtualenvwrapper) +plugins=(git gitfast postgres tmux python vim-override virtualenvwrapper) # User configuration if [ -e $HOME/bin ]; then export PATH="$HOME/bin:$PATH"; fi @@ -47,5 +47,8 @@ if [ -z "$LANG" ]; then export LANG=en_US.UTF-8; fi # Compilation flags # export ARCHFLAGS="-arch x86_64" +# MacOSX specific aliases +alias bu='brew update && brew upgrade' + source $ZSH/oh-my-zsh.sh unsetopt correctall