├── system
├── hushlogin.symlink
├── banner-plugin
│ └── banner.plugin.zsh
├── core-config-local-plugin
│ ├── functions
│ │ └── _c
│ ├── bin
│ │ └── c
│ └── core-config-local.plugin.zsh
└── colorize-plugin
│ └── colorize.plugin.zsh
├── fb
└── plugin
│ ├── bin
│ └── fbc
│ ├── fb.plugin.zsh
│ ├── functions
│ └── _fbc
│ └── README.md
├── hg
├── hgext.symlink
│ ├── hg-prompt
│ │ ├── docs
│ │ │ ├── .venv
│ │ │ ├── publish.sh
│ │ │ ├── wiki
│ │ │ │ ├── documentation
│ │ │ │ │ ├── index.mdown
│ │ │ │ │ ├── usage
│ │ │ │ │ │ └── index.mdown
│ │ │ │ │ ├── samples
│ │ │ │ │ │ └── index.mdown
│ │ │ │ │ └── keywords
│ │ │ │ │ │ └── index.mdown
│ │ │ │ ├── installation
│ │ │ │ │ └── index.mdown
│ │ │ │ ├── index.mdown
│ │ │ │ └── quickstart
│ │ │ │ │ └── index.mdown
│ │ │ ├── markdoc.yaml
│ │ │ └── static
│ │ │ │ └── media
│ │ │ │ └── css
│ │ │ │ ├── reset.css
│ │ │ │ ├── typography.css
│ │ │ │ ├── pygments.css
│ │ │ │ └── layout.css
│ │ ├── .hgignore
│ │ ├── .hgtags
│ │ ├── tests
│ │ │ ├── __init__.py
│ │ │ ├── test_none.py
│ │ │ ├── test_branch.py
│ │ │ ├── test_rev.py
│ │ │ ├── util.py
│ │ │ ├── test_tip.py
│ │ │ ├── test_node.py
│ │ │ └── test_update.py
│ │ ├── .hg_archival.txt
│ │ └── README
│ ├── crecord
│ │ ├── .hgignore
│ │ ├── .hg_archival.txt
│ │ └── crecord
│ │ │ ├── __init__.py
│ │ │ └── crecord_core.py
│ ├── qimportbz
│ │ ├── .hgignore
│ │ ├── .hg_archival.txt
│ │ ├── pb.py
│ │ ├── scp.py
│ │ └── bzhandler.py
│ └── hg-pbranch
│ │ ├── tut
│ │ ├── src
│ │ │ ├── pbranch
│ │ │ │ ├── _settings.rb
│ │ │ │ ├── _links.rextinc
│ │ │ │ ├── intro.rextile
│ │ │ │ ├── index.rextile
│ │ │ │ ├── config.rextile
│ │ │ │ ├── sanity.rextile
│ │ │ │ ├── pullupstream.rextile
│ │ │ │ ├── export.rextile
│ │ │ │ └── email.rextile
│ │ │ ├── _site.rb
│ │ │ ├── _header.xhtmlinc
│ │ │ ├── _settings.rb
│ │ │ ├── index.rextile
│ │ │ ├── printstyle.css
│ │ │ └── style.css
│ │ ├── buildall.sh
│ │ ├── build.sh
│ │ └── docbash.py
│ │ ├── .hgignore
│ │ ├── .hg_archival.txt
│ │ └── setupdev.sh
├── hgignore.symlink
└── hgrc.symlink
├── gist
└── plugin
│ └── gist.plugin.zsh
├── bin
├── subl
├── opendiff-w
├── headers
├── e
├── dot
└── mvim
├── git
├── plugin
│ ├── bin
│ │ ├── git-opendiff
│ │ ├── git-cherry-pick-merge
│ │ ├── git-undo
│ │ ├── git-unpushed
│ │ ├── git-copy-branch-name
│ │ ├── git-git
│ │ ├── git-cleanup-branches
│ │ ├── git-nuke
│ │ ├── git-hg-branch-diff
│ │ ├── git-branch-diff
│ │ ├── git-delete-local-merged
│ │ ├── git-credit
│ │ ├── git-hg-diff
│ │ ├── git-unpushed-stat
│ │ ├── git-promote-old
│ │ ├── git-up
│ │ └── git-rank-contributors
│ └── README.md
├── gitconfig.local.symlink.example
├── gitignore.symlink
└── gitconfig.symlink
├── go
└── plugin
│ └── go.plugin.zsh
├── sqlite
└── sqliterc.symlink
├── screen
└── screenrc.symlink
├── iterm2
├── install.sh
└── Wombat.itermcolors
├── starship
└── plugin
│ └── starship.plugin.zsh
├── rbenv
└── plugin
│ └── rbenv.plugin.zsh
├── ocaml
└── plugin
│ └── ocaml.plugin.zsh
├── ruby
├── gemrc.symlink
└── irbrc.symlink
├── vim
├── vim.symlink
│ ├── ftdetect
│ │ ├── javascript.vim
│ │ └── diff.vim
│ ├── colors
│ │ ├── native.vim
│ │ ├── wombat.vim
│ │ ├── wombat-zpao.vim
│ │ ├── Mustang.vim
│ │ ├── neon.vim
│ │ ├── BusyBee.vim
│ │ ├── darkZ.vim
│ │ ├── wombat256mod.vim
│ │ ├── desertEx.vim
│ │ ├── darkspectrum.vim
│ │ ├── argonaut.vim
│ │ ├── Clouds-Midnight.vim
│ │ └── liquidcarbon.vim
│ ├── .VimballRecord
│ └── doc
│ │ └── tags
└── gvimrc.symlink
├── pnpm
└── plugin
│ └── pnpm.plugin.zsh
├── z
└── plugin
│ └── z.plugin.zsh
├── homebrew
├── plugin
│ ├── homebrew.plugin.zsh
│ └── README.md
└── install.sh
├── script
├── install
└── bootstrap
├── Brewfile
├── .gitignore
├── conda
└── plugin
│ └── conda.plugin.zsh
├── macos
└── install.sh
├── LICENSE.md
├── zsh
└── zshrc.symlink
└── README.md
/system/hushlogin.symlink:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/fb/plugin/bin/fbc:
--------------------------------------------------------------------------------
1 | cd ~/FB/code/$1;
2 |
--------------------------------------------------------------------------------
/fb/plugin/fb.plugin.zsh:
--------------------------------------------------------------------------------
1 | alias fb="ssh fbdev"
2 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/docs/.venv:
--------------------------------------------------------------------------------
1 | markdoc
2 |
--------------------------------------------------------------------------------
/gist/plugin/gist.plugin.zsh:
--------------------------------------------------------------------------------
1 | alias gist="gist -p -o"
2 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/crecord/.hgignore:
--------------------------------------------------------------------------------
1 | syntax: glob
2 | *.pyc
3 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/qimportbz/.hgignore:
--------------------------------------------------------------------------------
1 | \.swp$
2 | \.pyc$
3 |
--------------------------------------------------------------------------------
/fb/plugin/functions/_fbc:
--------------------------------------------------------------------------------
1 | #compdef fbc
2 | _files -W ~/FB/code -/
3 |
--------------------------------------------------------------------------------
/bin/subl:
--------------------------------------------------------------------------------
1 | /Applications/Sublime Text.app/Contents/SharedSupport/bin/subl
--------------------------------------------------------------------------------
/fb/plugin/README.md:
--------------------------------------------------------------------------------
1 | # fb
2 |
3 | Handy things for working at FB.
4 |
--------------------------------------------------------------------------------
/git/plugin/bin/git-opendiff:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | /usr/bin/opendiff "$2" "$5" -merge "$1"
3 |
--------------------------------------------------------------------------------
/go/plugin/go.plugin.zsh:
--------------------------------------------------------------------------------
1 | export GOPATH=$HOME/.go
2 | export PATH="$GOPATH/bin:$PATH"
3 |
--------------------------------------------------------------------------------
/sqlite/sqliterc.symlink:
--------------------------------------------------------------------------------
1 | .mode column
2 | .explain ON
3 | .timer ON
4 | .header ON
5 |
6 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/src/pbranch/_settings.rb:
--------------------------------------------------------------------------------
1 |
2 | @crumbs += ['pbranch']
3 |
4 |
--------------------------------------------------------------------------------
/hg/hgignore.symlink:
--------------------------------------------------------------------------------
1 | ~$
2 | (swp|swo)$
3 | (^|/)\.DS_Store$
4 | rej$
5 | orig$
6 | (^|/)tags$
7 |
8 |
--------------------------------------------------------------------------------
/system/banner-plugin/banner.plugin.zsh:
--------------------------------------------------------------------------------
1 | if (( $+commands[archey] ))
2 | then
3 | archey
4 | fi
5 |
--------------------------------------------------------------------------------
/git/plugin/bin/git-cherry-pick-merge:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 |
3 | git cherry-pick -x $1 ||git cherry-pick -x -m1 $1
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/src/_site.rb:
--------------------------------------------------------------------------------
1 | @template_path = "#{INSTALL_PATH}/templates/standard"
2 |
3 |
--------------------------------------------------------------------------------
/screen/screenrc.symlink:
--------------------------------------------------------------------------------
1 | # detach screens if we lose a connection so -list doesn't lie
2 | autodetach on
3 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/.hgignore:
--------------------------------------------------------------------------------
1 | syntax: re
2 |
3 | ^tut/build/
4 | ^hg
5 | ^mercurial
6 | ^hgext
7 |
8 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/.hgignore:
--------------------------------------------------------------------------------
1 | syntax: glob
2 |
3 | .DS_Store
4 | *.pyc
5 | docs/.html
6 | docs/.tmp
7 |
--------------------------------------------------------------------------------
/iterm2/install.sh:
--------------------------------------------------------------------------------
1 | curl -L https://iterm2.com/shell_integration/install_shell_integration_and_utilities.sh | bash
2 |
--------------------------------------------------------------------------------
/starship/plugin/starship.plugin.zsh:
--------------------------------------------------------------------------------
1 | if [ -f `brew --prefix`/bin/starship ]; then
2 | eval "$(starship init zsh)"
3 | fi
4 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/.hgtags:
--------------------------------------------------------------------------------
1 | d390b5e2719169d39b522f5dcf0320ce81a08d57 0.1
2 | a6ec48f03985b7c2bb6b7fbe16c6bbec2d650783 0.2
3 |
--------------------------------------------------------------------------------
/git/plugin/bin/git-undo:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | #
3 | # Undo your last commit, but don't throw away your changes
4 |
5 | git reset --soft HEAD^
6 |
--------------------------------------------------------------------------------
/rbenv/plugin/rbenv.plugin.zsh:
--------------------------------------------------------------------------------
1 | # init according to man page
2 | if (( $+commands[rbenv] ))
3 | then
4 | eval "$(rbenv init -)"
5 | fi
6 |
--------------------------------------------------------------------------------
/ocaml/plugin/ocaml.plugin.zsh:
--------------------------------------------------------------------------------
1 | [[ ! -r $HOME/.opam/opam-init/init.zsh ]] || source $HOME/.opam/opam-init/init.zsh > /dev/null 2> /dev/null
2 |
--------------------------------------------------------------------------------
/ruby/gemrc.symlink:
--------------------------------------------------------------------------------
1 | ---
2 | :update_sources: true
3 | :verbose: true
4 | :backtrace: false
5 | :benchmark: false
6 | gem: --no-document
7 |
--------------------------------------------------------------------------------
/vim/vim.symlink/ftdetect/javascript.vim:
--------------------------------------------------------------------------------
1 | " extra JavaScript filetypes
2 | autocmd BufNewFile,BufRead *.{jsm} set filetype=javascript
3 |
4 |
--------------------------------------------------------------------------------
/git/gitconfig.local.symlink.example:
--------------------------------------------------------------------------------
1 | [user]
2 | name = AUTHORNAME
3 | email = AUTHOREMAIL
4 | [credential]
5 | helper = GIT_CREDENTIAL_HELPER
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/src/_header.xhtmlinc:
--------------------------------------------------------------------------------
1 |
2 | <%= bc = breadcrumbs(' > '); bc + ' > ' unless bc == '' %>
3 |
4 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/tests/__init__.py:
--------------------------------------------------------------------------------
1 | """Unit tests for hg-prompt.
2 |
3 | The tests require nose: pip install nose && nosetests --with-doctest -v
4 |
5 | """
--------------------------------------------------------------------------------
/pnpm/plugin/pnpm.plugin.zsh:
--------------------------------------------------------------------------------
1 | export PNPM_HOME="$HOME/Library/pnpm"
2 | case ":$PATH:" in
3 | *":$PNPM_HOME:"*) ;;
4 | *) export PATH="$PNPM_HOME:$PATH" ;;
5 | esac
6 |
--------------------------------------------------------------------------------
/bin/opendiff-w:
--------------------------------------------------------------------------------
1 | # opendiff returns immediately, without waiting for FileMerge to exit.
2 | # Piping the output makes opendiff wait for FileMerge.
3 | opendiff "$@" | cat
4 |
5 |
--------------------------------------------------------------------------------
/system/core-config-local-plugin/functions/_c:
--------------------------------------------------------------------------------
1 | #compdef c
2 | _files -W $PROJECTS -/
3 | _files -W $GOPATH/src/github.com -/
4 |
5 | # See further documentation in `functions/c`.
6 |
--------------------------------------------------------------------------------
/git/plugin/bin/git-unpushed:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | #
3 | # Show the diff of everything you haven't pushed yet.
4 |
5 | branch=$(git rev-parse --abbrev-ref HEAD)
6 | git diff origin/$branch..HEAD
7 |
--------------------------------------------------------------------------------
/bin/headers:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | #
3 | # https://github.com/rtomayko/dotfiles/blob/rtomayko/bin/headers
4 |
5 | curl -sv "$@" 2>&1 >/dev/null |
6 | grep -v "^\*" |
7 | grep -v "^}" |
8 | cut -c3-
--------------------------------------------------------------------------------
/z/plugin/z.plugin.zsh:
--------------------------------------------------------------------------------
1 | if (( $+commands[zoxide] )); then
2 | eval "$(zoxide init zsh)"
3 | else
4 | echo 'zoxide: command not found, please install it from https://github.com/ajeetdsouza/zoxide'
5 | fi
6 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/crecord/.hg_archival.txt:
--------------------------------------------------------------------------------
1 | repo: 582ec143d317c23ea35c4791d59e31761b79909d
2 | node: 4e2c6a7c659fac5ea0b0374e04b3e3370b68c687
3 | branch: default
4 | latesttag: null
5 | latesttagdistance: 93
6 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/.hg_archival.txt:
--------------------------------------------------------------------------------
1 | repo: befe377b74a844cb32d4e30ed76d0d59bf4acfec
2 | node: 7101664e391b8f37f9281f098be352a10f814d47
3 | branch: default
4 | latesttag: null
5 | latesttagdistance: 196
6 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/.hg_archival.txt:
--------------------------------------------------------------------------------
1 | repo: b7c33528742484da2d113c05286c9887f01639f3
2 | node: e16ee632ce6faa93c45cbbcc4320d64418bec737
3 | branch: default
4 | latesttag: 0.2
5 | latesttagdistance: 38
6 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/qimportbz/.hg_archival.txt:
--------------------------------------------------------------------------------
1 | repo: ea716d926c130c965d938c31bfc8af622e874b8f
2 | node: 6237bc0a91fafc276e4427f9fcdc09d9568bde5a
3 | branch: default
4 | latesttag: null
5 | latesttagdistance: 69
6 |
--------------------------------------------------------------------------------
/system/colorize-plugin/colorize.plugin.zsh:
--------------------------------------------------------------------------------
1 | # GRC colorizes nifty unix tools all over the place
2 | if (( $+commands[grc] )) && (( $+commands[brew] ))
3 | then
4 | source `brew --prefix`/etc/grc.zsh
5 | fi
6 |
--------------------------------------------------------------------------------
/git/gitignore.symlink:
--------------------------------------------------------------------------------
1 | .DS_Store
2 | *~
3 | *.swp
4 | *.sw*
5 | *.pyc
6 | *.rej
7 | *.orig
8 |
9 | # Some Mozilla ignores
10 | obj-*/
11 | configure
12 | .mozconfig*
13 |
14 | # tags
15 | tags
16 |
17 | .zed/
18 |
--------------------------------------------------------------------------------
/git/plugin/bin/git-copy-branch-name:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | #
3 | # Copy the current branch name to the clipboard.
4 |
5 | branch=$(git rev-parse --abbrev-ref HEAD)
6 | echo $branch
7 | echo $branch | tr -d '\n' | tr -d ' ' | pbcopy
8 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/src/pbranch/_links.rextinc:
--------------------------------------------------------------------------------
1 | [-mq]http://www.selenic.com/mercurial/wiki/index.cgi/MqExtension
2 | [-loom]https://launchpad.net/bzr-loom
3 | [-topgit]http://repo.or.cz/w/topgit.git?a=blob;f=README
4 |
5 |
--------------------------------------------------------------------------------
/git/plugin/bin/git-git:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | # For when you're an idiot and git git something, then it assumes you meant
3 | # git init something.
4 | # Thanks @jamessocol. https://twitter.com/jamessocol/status/586916405058138113
5 |
6 | git $@
7 |
--------------------------------------------------------------------------------
/git/plugin/bin/git-cleanup-branches:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | #
3 | # Cleanup branches merged to master. Essentially the same as `delete-local-merged`
4 | # TODO: pick 1
5 |
6 | git branch --merged master | grep -v "\* master" | xargs -n 1 git branch -d
7 |
--------------------------------------------------------------------------------
/git/plugin/bin/git-nuke:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | #
3 | # Nukes a branch locally and on the origin remote.
4 | #
5 | # $1 - Branch name.
6 | #
7 | # Examples
8 | #
9 | # git nuke add-git-nuke
10 |
11 | git branch -D $1
12 | git push origin :$1
13 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/buildall.sh:
--------------------------------------------------------------------------------
1 | #! /bin/bash
2 |
3 | ./build.sh pbranch/config pbranch/simple pbranch/email pbranch/export pbranch/insert pbranch/dist pbranch/graph pbranch/pullupstream pbranch/collab pbranch/octopus pbranch/sanity
4 |
5 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/docs/publish.sh:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env bash
2 |
3 | markdoc build
4 | rsync --delete -az .html/ ~/src/sjl.bitbucket.org/hg-prompt
5 | hg -R ~/src/sjl.bitbucket.org commit -Am 'hg-prompt: Update documentation.'
6 | hg -R ~/src/sjl.bitbucket.org push
7 |
--------------------------------------------------------------------------------
/homebrew/plugin/homebrew.plugin.zsh:
--------------------------------------------------------------------------------
1 | # shell environment, including $PATH
2 | eval "$(/opt/homebrew/bin/brew shellenv)"
3 |
4 | # zsh completions for installed packages
5 | if type brew &>/dev/null
6 | then
7 | FPATH="$(brew --prefix)/share/zsh/site-functions:${FPATH}"
8 | fi
9 |
--------------------------------------------------------------------------------
/git/plugin/README.md:
--------------------------------------------------------------------------------
1 | # git
2 |
3 | Local git stuff. Mostly this is a collection of extra executables that don't fit nicely into `.gitconfig#alias`.
4 |
5 | Git is handy in that any executable matching `git-*` will be available as a subcommand to `git`. Eg `git-branch-diff` will work as `git branch-diff`.
6 |
--------------------------------------------------------------------------------
/git/plugin/bin/git-hg-branch-diff:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 |
3 | # This creates a diff of a branch that is safe to post on bugzilla and can be
4 | # imported by mercurial.
5 | # In the future this might open $EDITOR to allow a patch message and add the
6 | # author field.
7 | git branch-diff -U8 | sed "/^index.*$/d"
8 |
--------------------------------------------------------------------------------
/git/plugin/bin/git-branch-diff:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 |
3 | # This will create a diff from the last point that master was merged into the
4 | # currently checked out branch.
5 | # This is essentially equivalent to hg pdiff.
6 | $base = git remote show origin | sed -n '/HEAD branch/s/.*: //p'
7 | git diff `git merge-base HEAD $base` $1
8 |
--------------------------------------------------------------------------------
/git/plugin/bin/git-delete-local-merged:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | #
3 | # Delete all local branches that have been merged into HEAD. Stolen from
4 | # our favorite @tekkub:
5 | #
6 | # https://plus.google.com/115587336092124934674/posts/dXsagsvLakJ
7 |
8 | git branch -d `git branch --merged | grep -v '^*' | grep -v 'master' | tr -d '\n'`
9 |
--------------------------------------------------------------------------------
/git/plugin/bin/git-credit:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | #
3 | # A very slightly quicker way to credit an author on the latest commit.
4 | #
5 | # $1 - The full name of the author.
6 | # $2 - The email address of the author.
7 | #
8 | # Examples
9 | #
10 | # git credit "Zach Holman" zach@example.com
11 | #
12 |
13 | git commit --amend --author "$1 <$2>" -C HEAD
14 |
--------------------------------------------------------------------------------
/script/install:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env bash
2 | #
3 | # Run all dotfiles installers.
4 |
5 | set -e
6 |
7 | cd "$(dirname $0)"/..
8 |
9 | # Run Homebrew through the Brewfile
10 | echo "› brew bundle"
11 | brew bundle
12 |
13 | # find the installers and run them iteratively
14 | find . -name install.sh | while read installer ; do sh -c "${installer}" ; done
15 |
--------------------------------------------------------------------------------
/vim/vim.symlink/ftdetect/diff.vim:
--------------------------------------------------------------------------------
1 | " when reading patches directly from a patch queue (.hg/patches/), they aren't
2 | " recognized as diffs, but they should be
3 |
4 | autocmd BufRead * call hgpatch_check()
5 |
6 | function! s:hgpatch_check()
7 | if getline(1) =~ "# HG changeset.*"
8 | set filetype=diff
9 | endif
10 | endfunction
11 |
12 |
--------------------------------------------------------------------------------
/homebrew/plugin/README.md:
--------------------------------------------------------------------------------
1 | # homebrew
2 |
3 | This just sets up the environment for homebrew if installed.
4 |
5 | Theoretically this could be done directly in `~/.zshrc` or `~/.zshenv` but opted to do it as a plugin for consistency.
6 |
7 | Note: This must be loaded ASAP as other plugins will expect that executables installed via homebew are available in `$PATH`.
8 |
--------------------------------------------------------------------------------
/git/plugin/bin/git-hg-diff:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 |
3 | # This creates a diff of that is safe to post on bugzilla and can be imported
4 | # by mercurial. This is different from hg-branch-diff in that it will just
5 | # perform a normal diff.
6 | # In the future this might open $EDITOR to allow a patch message and add the
7 | # author field.
8 | git diff -U8 | sed "/^index.*$/d"
9 |
--------------------------------------------------------------------------------
/homebrew/install.sh:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | #
3 | # Homebrew
4 | #
5 | # This installs some of the common dependencies needed (or at least desired)
6 | # using Homebrew.
7 |
8 | # Check for Homebrew
9 | if test ! $(which brew)
10 | then
11 |
12 | /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
13 |
14 | fi
15 |
16 | exit 0
17 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/setupdev.sh:
--------------------------------------------------------------------------------
1 | #! /bin/bash
2 |
3 | # Sets up links to files needed from a proper Mercurial sub-repository for development.
4 | # First clone a Mercurial repository to ./hg-repo.
5 | # Then do `make local` there.
6 |
7 | cp -f hg-repo/hg .
8 | ln -fs hg-repo/mercurial .
9 | ( cd hgext; ln -fs ../hg-repo/hgext/{__init__,graphlog,patchbomb,color,mq}.py . )
10 |
11 |
--------------------------------------------------------------------------------
/git/plugin/bin/git-unpushed-stat:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | #
3 | # Show the diffstat of everything you haven't pushed yet.
4 |
5 | branch=$(git rev-parse --abbrev-ref HEAD)
6 | count=$(git rev-list --count HEAD origin/$branch...HEAD)
7 |
8 | if [ "$count" -eq "1" ]
9 | then
10 | s=''
11 | else
12 | s='s'
13 | fi
14 |
15 | git diff --stat origin/$branch..HEAD
16 | echo " $count commit$s total"
17 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/docs/wiki/documentation/index.mdown:
--------------------------------------------------------------------------------
1 | Documentation
2 | =============
3 |
4 | ##[Usage](/documentation/usage/)##
5 |
6 | How the `hg prompt` command can be used.
7 |
8 | ##[Keywords](/documentation/keywords/)##
9 |
10 | Keywords available to use with the command.
11 |
12 | ##[Sample Prompts](/documentation/samples/)##
13 |
14 | Some sample prompts to get you started.
--------------------------------------------------------------------------------
/Brewfile:
--------------------------------------------------------------------------------
1 | tap "homebrew/core"
2 |
3 | brew "archey"
4 | brew "autojump"
5 | brew "colordiff"
6 | brew "coreutils"
7 | brew "dos2unix"
8 | brew "gist"
9 | brew "git"
10 | brew "git-extras"
11 | brew "git-lfs"
12 | brew "go"
13 | brew "grc"
14 | brew "htop"
15 | brew "hub"
16 | brew "lynx"
17 | brew "nvm"
18 | brew "rbenv"
19 | brew "starship"
20 | brew "tree"
21 | brew "wdiff"
22 | brew "wget"
23 | brew "z"
24 |
--------------------------------------------------------------------------------
/bin/e:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | #
3 | # Quick shortcut to an editor.
4 | #
5 | # This means that as I travel back and forth between editors, hey, I don't have
6 | # to re-learn any arcane commands. Neat.
7 | #
8 | # USAGE:
9 | #
10 | # $ e
11 | # # => opens the current directory in your editor
12 | #
13 | # $ e .
14 | # $ e /usr/local
15 | # # => opens the specified directory in your editor
16 | exec "$EDITOR" "${1:-.}"
17 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | vim/vim.symlink/.netrwhist
2 | vim/vim.symlink/bundle
3 |
4 | atom.symlink/.apm
5 | atom.symlink/.git-history
6 | atom.symlink/.node-gyp
7 | atom.symlink/.storage
8 | atom.symlink/blob-store
9 | atom.symlink/compile-cache/
10 | atom.symlink/packages
11 | atom.symlink/storage
12 | atom.symlink/themes
13 | atom.symlink/blob-store
14 | atom.symlink/recovery
15 |
16 | git/gitconfig.local.symlink
17 |
18 | # compiled plugin files
19 | *.zwc
20 | vim/vim.symlink/plugged
21 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/src/_settings.rb:
--------------------------------------------------------------------------------
1 | # Redirect to output path and enforce it exists.
2 | @html_path = '../doc/'
3 | @html_name = @html_path + html_name
4 | FileUtils.mkpath File.dirname( html_name )
5 |
6 | @head_nodes << ''
7 | @head_nodes << ''
8 |
9 | @crumbs << 'Tutorials'
10 |
11 |
--------------------------------------------------------------------------------
/bin/dot:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | #
3 | # dot
4 | #
5 | # `dot` handles installation, updates, things like that. Run it periodically
6 | # to make sure you're on the latest and greatest.
7 | export ZSH=$HOME/.dotfiles
8 |
9 | # Set macOS defaults
10 | $ZSH/macos/set-defaults.sh
11 |
12 | # Install homebrew
13 | $ZSH/homebrew/install.sh 2>&1
14 |
15 | # Upgrade homebrew
16 | echo "› brew update"
17 | brew update
18 |
19 | # Install software
20 | echo "› $ZSH/script/install"
21 | $ZSH/script/install
22 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/docs/markdoc.yaml:
--------------------------------------------------------------------------------
1 | wiki-name: "hg-prompt"
2 |
3 |
4 | static-dir: "static"
5 |
6 | hide-prefix: "."
7 | document-extensions: [.md, .mdown, .markdown]
8 | generate-listing: always
9 | listing-filename: "list.html"
10 |
11 | use-default-static: false
12 |
13 | markdown:
14 | safe_mode: false
15 | output_format: xhtml1
16 | extensions: [codehilite, def_list, toc]
17 |
18 | server:
19 | bind: '127.0.0.1'
20 | port: 8010
21 | server_name: 'sjl.bitbucket.org'
--------------------------------------------------------------------------------
/conda/plugin/conda.plugin.zsh:
--------------------------------------------------------------------------------
1 | # >>> conda initialize >>>
2 | # !! Contents within this block are managed by 'conda init' !!
3 | __conda_setup="$('$HOME/miniconda3/bin/conda' 'shell.zsh' 'hook' 2> /dev/null)"
4 | if [ $? -eq 0 ]; then
5 | eval "$__conda_setup"
6 | else
7 | if [ -f "$HOME/miniconda3/etc/profile.d/conda.sh" ]; then
8 | . "$HOME/miniconda3/etc/profile.d/conda.sh"
9 | else
10 | export PATH="$HOME/miniconda3/bin:$PATH"
11 | fi
12 | fi
13 | unset __conda_setup
14 | # <<< conda initialize <<<
15 |
--------------------------------------------------------------------------------
/macos/install.sh:
--------------------------------------------------------------------------------
1 | # The Brewfile handles Homebrew-based app and library installs, but there may
2 | # still be updates and installables in the Mac App Store. There's a nifty
3 | # command line interface to it that we can use to just install everything, so
4 | # yeah, let's do that.
5 |
6 | # zpao: Yea, we aren't going to do this. I don't want to install everything.
7 | # There's a homebrew extension (mas) that lets us install that way. It *should*
8 | # work but I'm writing this from a set up machine already.
9 |
10 | # echo "› sudo softwareupdate -i -a"
11 | # sudo softwareupdate -i -a
12 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/tests/test_none.py:
--------------------------------------------------------------------------------
1 | '''Test output without keywords.'''
2 |
3 | from nose import *
4 | from util import *
5 |
6 |
7 | @with_setup(setup_sandbox, teardown_sandbox)
8 | def test_blank():
9 | output = prompt(fs='')
10 | assert output == ''
11 |
12 |
13 | @with_setup(setup_sandbox, teardown_sandbox)
14 | def test_text():
15 | output = prompt(fs='test one two three')
16 | assert output == 'test one two three'
17 |
18 |
19 | @with_setup(setup_sandbox, teardown_sandbox)
20 | def test_invalid_keyword():
21 | output = prompt(fs='{invalidkeyword}')
22 | assert output == '{invalidkeyword}'
23 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/qimportbz/pb.py:
--------------------------------------------------------------------------------
1 | # std python modules
2 | import urllib2
3 | try:
4 | import cStringIO as StringIO
5 | except ImportError:
6 | import StringIO
7 | import os
8 |
9 | class Handler(urllib2.BaseHandler):
10 | def __init__(self, ui, passmgr):
11 | self.ui = ui
12 | self.passmgr = passmgr
13 |
14 | self.base = ui.config('qimportbz', 'pastebin',
15 | os.environ.get('PASTEBIN', "pastebin.mozilla.org"))
16 |
17 | # Change the request to the http to fetch the raw text
18 | def pb_open(self, req):
19 | url = "http://%s/?dl=%s" % (self.base, req.get_host())
20 | return self.parent.open(url)
21 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/src/index.rextile:
--------------------------------------------------------------------------------
1 | h1. Mercurial Tutorials
2 |
3 | "Patch branches":pbranch/index.htm (pbranch) is a way to develop a series of patches for submission into a main repo. This is for when the main repo does not want to track the detailed evolution of the patches, so you cannot use plain branching and merging. But during the patches' development, you do want to track the detailed evolution and want to collaborate with team members as naturally as on a normal branch, including exchange and reviewing of changesets. So stacks allow to develop patches as basically normal Mercurial branches, which later get thrown away (or archived) when the patches have been accepted.
4 |
5 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/docs/wiki/installation/index.mdown:
--------------------------------------------------------------------------------
1 | Installation
2 | ============
3 |
4 | Installing `hg-prompt` requires [Python][] 2.5+ and (obviously) Mercurial.
5 |
6 | [Python]: http://python.org/
7 |
8 | First, clone the repository:
9 |
10 | :::console
11 | $ hg clone http://bitbucket.org/sjl/hg-prompt/
12 |
13 | Edit the `[extensions]` section in your `~/.hgrc` file:
14 |
15 | :::cfg
16 | [extensions]
17 | prompt = (path to)/prompt.py
18 |
19 | Make sure everything is working:
20 |
21 | :::console
22 | $ hg prompt 'test'
23 | test
24 |
25 | Take a look at the [Quick Start][] guide to learn how to put some useful
26 | information into your shell prompt.
27 |
28 | [Quick Start]: /quickstart/
--------------------------------------------------------------------------------
/system/core-config-local-plugin/bin/c:
--------------------------------------------------------------------------------
1 | #!/bin/zsh
2 | #
3 | # This lets you quickly jump into a project directory.
4 | #
5 | # Type:
6 | #
7 | # c
8 | #
9 | # ...to autocomplete on all of your projects in the directories specified in
10 | # `functions/_c`. Typically I'm using it like:
11 | #
12 | # c holm/bo
13 | #
14 | # ...to quickly jump into holman/boom, for example.
15 | #
16 | # This also accounts for how Go structures its projects. For example, it will
17 | # autocomplete both on $PROJECTS, and also assume you want to autocomplete on
18 | # your Go projects in $GOPATH/src.
19 |
20 | if [ ! -z "$1" ] && [ -s "$GOPATH/src/github.com/$1" ]; then
21 | cd "$GOPATH/src/github.com/$1"
22 | else
23 | cd "$PROJECTS/$1"
24 | fi
25 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/docs/wiki/index.mdown:
--------------------------------------------------------------------------------
1 | hg-prompt
2 | =========
3 |
4 | `hg-prompt` is a Mercurial extension that adds an 'hg prompt' command to
5 | Mercurial for viewing repository information. It's designed to be used in a
6 | shell prompt.
7 |
8 | [Installation][]
9 | ----------------
10 |
11 | [Quick Start][]
12 | ---------------
13 |
14 | [Full Documentation][]
15 | ----------------------
16 |
17 | [Code][]
18 | --------
19 |
20 | [Installation]: /installation/
21 | [Quick Start]: /quickstart/
22 | [Full Documentation]: /documentation/
23 | [Code]: http://bitbucket.org/sjl
24 |
25 | Screenshot
26 | ----------
27 |
28 | 
29 |
--------------------------------------------------------------------------------
/git/plugin/bin/git-promote-old:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | #
3 | # Promotes a local topic branch to a remote tracking branch of the same name,
4 | # by pushing and then setting up the git config
5 | #
6 | # Thanks to ENTP:
7 | # http://hoth.entp.com/2008/11/10/improving-my-git-workflow
8 |
9 | curr_branch=$(git symbolic-ref -q HEAD | sed -e 's|^refs/heads/||')
10 |
11 | remote_branch=$(git branch -r | grep "origin/${curr_branch}")
12 | [ -z "${remote_branch}" ] && ( git push origin "${curr_branch}" )
13 |
14 | origin=$(git config --get "branch.${curr_branch}.remote")
15 | [ -z "${origin}" ] && ( git config --add "branch.${curr_branch}.remote" origin )
16 |
17 | merge=$(git config --get "branch.${curr_branch}.merge")
18 | [ -z "${merge}" ] && ( git config --add "branch.${curr_branch}.merge" "refs/heads/${curr_branch}" )
--------------------------------------------------------------------------------
/vim/gvimrc.symlink:
--------------------------------------------------------------------------------
1 | colorscheme flatlandia
2 | " set gfn=Inconsolata-dz:h10.00
3 | " set guifont=Fira\ Code:h12
4 | set guifont=Ubuntu\ Mono:h14
5 | set linespace=1
6 | set anti
7 | set lines=999 columns=90
8 | set guioptions=egmrt
9 |
10 | " C-TAB and C-SHIFT-TAB cycle tabs forward and backward
11 | nmap :tabnext
12 | imap :tabnext
13 | vmap :tabnext
14 | nmap :tabprevious
15 | imap :tabprevious
16 | vmap :tabprevious
17 |
18 | " C-# switches to tab
19 | nmap 1gt
20 | nmap 2gt
21 | nmap 3gt
22 | nmap 4gt
23 | nmap 5gt
24 | nmap 6gt
25 | nmap 7gt
26 | nmap 8gt
27 | nmap 9gt
28 |
29 | " NERDTreeTabs
30 | " don't open on startupa (already defaults to 0 on console)
31 | let g:nerdtree_tabs_open_on_gui_startup = 0
32 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/docs/static/media/css/reset.css:
--------------------------------------------------------------------------------
1 | /*
2 | Copyright (c) 2009, Yahoo! Inc. All rights reserved.
3 | Code licensed under the BSD License:
4 | http://developer.yahoo.net/yui/license.txt
5 | version: 2.7.0
6 | */
7 | html{color:#000;background:#FFF;}body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,code,form,fieldset,legend,input,button,textarea,p,blockquote,th,td{margin:0;padding:0;}table{border-collapse:collapse;border-spacing:0;}fieldset,img{border:0;}address,caption,cite,code,dfn,em,strong,th,var,optgroup{font-style:inherit;font-weight:inherit;}del,ins{text-decoration:none;}li{list-style:none;}caption,th{text-align:left;}h1,h2,h3,h4,h5,h6{font-size:100%;font-weight:normal;}q:before,q:after{content:'';}abbr,acronym{border:0;font-variant:normal;}sup{vertical-align:baseline;}sub{vertical-align:baseline;}legend{color:#000;}input,button,textarea,select,optgroup,option{font-family:inherit;font-size:inherit;font-style:inherit;font-weight:inherit;}input,button,textarea,select{*font-size:100%;}
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/build.sh:
--------------------------------------------------------------------------------
1 | #! /bin/bash
2 |
3 | homedir=$HOME
4 | rootdir=`pwd`
5 | workdir=/tmp/hg-tut-$USER
6 |
7 | export HGPATH=$rootdir/..
8 | export HGRCPATH=$workdir/.hgrc
9 | export HOME=$workdir
10 |
11 | rm -rf $workdir
12 | rm -rf build/
13 | mkdir -p $workdir
14 | mkdir -p build/ref/
15 | cp -r src build/src
16 |
17 | for f in $@; do
18 | mkdir -p build/bash/${f%/*}
19 | mkdir -p build/ref/${f%/*}
20 | mkdir -p build/src/${f%/*}
21 | ( cd $workdir; python $rootdir/docbash.py $rootdir/{src,build/src,build/ref}/$f.rextile $rootdir/build/bash/$f.sh )
22 | diff \
23 | -I "[ ]\+Message-Id: .*$" \
24 | -I "[ ]\+In-Reply-To: .*$" \
25 | -I "[ ]\+References: .*$" \
26 | -I "[ ]\+User-Agent: .*$" \
27 | -I "[ ]\+Date: .*$" \
28 | {src,build/ref}/$f.rextile
29 | if [ "$?" -ne "0" ]; then
30 | dis meld {src,build/ref}/$f.rextile
31 | fi
32 | done
33 |
34 | mkdir -p build/doc/
35 | ( cd build/src; rextile )
36 | find build/doc/ -name "*.htm" | xargs sed -e "s/^_//" -i
37 | cp -t build/doc/ src/*.css
38 |
39 |
--------------------------------------------------------------------------------
/git/plugin/bin/git-up:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | #
3 | # Usage: git-up
4 | # git-reup
5 | #
6 | # Like git-pull but show a short and sexy log of changes
7 | # immediately after merging (git-up) or rebasing (git-reup).
8 | #
9 | # Inspired by Kyle Neath's `git up' alias:
10 | # http://gist.github.com/249223
11 | #
12 | # Stolen from Ryan Tomayko
13 | # http://github.com/rtomayko/dotfiles/blob/rtomayko/bin/git-up
14 |
15 | set -e
16 |
17 | PULL_ARGS="$@"
18 |
19 | # when invoked as git-reup, run as `git pull --rebase'
20 | test "$(basename $0)" = "git-reup" &&
21 | PULL_ARGS="--rebase $PULL_ARGS"
22 |
23 | git pull $PULL_ARGS
24 |
25 | # show diffstat of all changes if we're pulling with --rebase. not
26 | # sure why git-pull only does this when merging.
27 | test "$(basename $0)" = "git-reup" && {
28 | echo "Diff:"
29 | git --no-pager diff --color --stat HEAD@{1}.. |
30 | sed 's/^/ /'
31 | }
32 |
33 | # show an abbreviated commit log of stuff that was just merged.
34 | echo "Log:"
35 | git log --color --pretty=oneline --abbrev-commit HEAD@{1}.. |
36 | sed 's/^/ /'
37 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/src/pbranch/intro.rextile:
--------------------------------------------------------------------------------
1 | h1. Introduction
2 |
3 | _Patch branches_ (pbranch) is a way to develop a stack of patches for submission into a main repo. This is for when the main repo does not want to track the detailed evolution of the patches, so you cannot use plain branching and merging. But during the patches' development, you do want to track the detailed evolution and want to collaborate with team members as naturally as on a normal branch, including exchange and reviewing of changesets. So stacks allow to develop patches as basically normal Mercurial branches, which later get thrown away (or archived) when the patches have been accepted.
4 |
5 | pbranch is thus an alternative for "mq":-mq. While mq is very useful for fairly short-lived, single-person patches, I find it lacking for long-term and/or team efforts. Versioned mq patch queues are hard to review (diffs of diffs) and merge, and we lack the usual merging niceness in Mercurial when updating later patches to changes in earlier ones.
6 |
7 | pbranch is based on ideas similar as those found in "bzr-loom":-loom, and especially the more recent "topgit":-topgit.
8 |
9 |
10 |
--------------------------------------------------------------------------------
/LICENSE.md:
--------------------------------------------------------------------------------
1 | The MIT License
2 |
3 | Copyright (c) Zach Holman, http://zachholman.com
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in
13 | all copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21 | THE SOFTWARE.
22 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/tests/test_branch.py:
--------------------------------------------------------------------------------
1 | '''Test output of {branch}.'''
2 |
3 | from nose import *
4 | from util import *
5 |
6 |
7 | @with_setup(setup_sandbox, teardown_sandbox)
8 | def test_default_branch():
9 | output = prompt(fs='{branch}')
10 | assert output == 'default'
11 |
12 | output = prompt(fs='{on {branch}}')
13 | assert output == 'on default'
14 |
15 |
16 | @with_setup(setup_sandbox, teardown_sandbox)
17 | def test_non_default_branch():
18 | hg_branch('test')
19 |
20 | output = prompt(fs='{branch}')
21 | assert output == 'test'
22 |
23 | output = prompt(fs='{on the {branch} branch}')
24 | assert output == 'on the test branch'
25 |
26 |
27 | @with_setup(setup_sandbox, teardown_sandbox)
28 | def test_quiet_filter():
29 | output = prompt(fs='{branch|quiet}')
30 | assert output == ''
31 |
32 | output = prompt(fs='{on {branch|quiet}}')
33 | assert output == ''
34 |
35 | hg_branch('test')
36 |
37 | output = prompt(fs='{branch|quiet}')
38 | assert output == 'test'
39 |
40 | output = prompt(fs='{on the {branch|quiet} branch}')
41 | assert output == 'on the test branch'
42 |
--------------------------------------------------------------------------------
/ruby/irbrc.symlink:
--------------------------------------------------------------------------------
1 | #!/usr/bin/ruby
2 | require 'irb/completion'
3 | require 'irb/ext/save-history'
4 | require 'rubygems'
5 |
6 | IRB.conf[:SAVE_HISTORY] = 1000
7 | IRB.conf[:HISTORY_FILE] = "#{ENV['HOME']}/.irb_history"
8 |
9 | IRB.conf[:PROMPT_MODE] = :SIMPLE
10 |
11 | IRB.conf[:AUTO_INDENT] = true
12 |
13 | class Object
14 | # list methods which aren't in superclass
15 | def local_methods(obj = self)
16 | (obj.methods - obj.class.superclass.instance_methods).sort
17 | end
18 |
19 | # print documentation
20 | #
21 | # ri 'Array#pop'
22 | # Array.ri
23 | # Array.ri :pop
24 | # arr.ri :pop
25 | def ri(method = nil)
26 | unless method && method =~ /^[A-Z]/ # if class isn't specified
27 | klass = self.kind_of?(Class) ? name : self.class.name
28 | method = [klass, method].compact.join('#')
29 | end
30 | puts `ri '#{method}'`
31 | end
32 | end
33 |
34 | # Copies the result of the last operation you ran in IRB to the system
35 | # clipboard (if you're on macOS).
36 | def cop
37 | last_value = IRB.CurrentContext.last_value
38 | %x[echo '#{last_value}' | pbcopy]
39 | "copied \`#{last_value}' to your clipboard"
40 | end
41 |
42 | def me
43 | User.find_by_login(ENV['USER'].strip)
44 | end
45 |
46 | def r
47 | reload!
48 | end
49 |
--------------------------------------------------------------------------------
/system/core-config-local-plugin/core-config-local.plugin.zsh:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env zsh
2 |
3 | ### ZSH
4 |
5 | export LSCOLORS="exfxcxdxbxegedabagacad"
6 | export CLICOLOR=true
7 |
8 | # pasting with tabs doesn't perform completion
9 | zstyle ':completion:*' insert-tab pending
10 |
11 | setopt nolistbeep
12 | setopt localoptions
13 | setopt localtraps
14 | setopt sharehistory
15 | setopt extendedhistory
16 | setopt promptsubst
17 | setopt completeinword
18 | setopt ignoreeof
19 | setopt completealiases
20 |
21 | bindkey '^[^[[D' backward-word
22 | bindkey '^[^[[C' forward-word
23 | bindkey '^[[5D' beginning-of-line
24 | bindkey '^[[5C' end-of-line
25 | bindkey '^[[3~' delete-char
26 | bindkey '^?' backward-delete-char
27 |
28 | for keycode in '[' '0'; do
29 | bindkey "^[${keycode}A" history-substring-search-up
30 | bindkey "^[${keycode}B" history-substring-search-down
31 | done
32 | unset keycode
33 |
34 |
35 | ### PATH
36 |
37 | # ./bin - pick up current bin if there is one
38 | # ~/z/bin - anything in my home directory and custom built (rare)
39 | # ~/bin - anything in my home directory
40 | # $ZSH/bin - anything in this repo
41 | export PATH="./bin:$HOME/z/bin:$HOME/bin:$ZSH/bin:$PATH"
42 |
43 |
44 | ### ALIASES
45 | alias ls="ls -a"
46 | alias ll="ls -lh"
47 |
48 |
49 | ### ENV
50 | export EDITOR=vim
51 |
--------------------------------------------------------------------------------
/hg/hgrc.symlink:
--------------------------------------------------------------------------------
1 | [defaults]
2 | export = -g
3 | branches = -a
4 | heads = -a
5 | qseries = -vs
6 | qnew = -U
7 |
8 | [ui]
9 | username = Paul O’Shannessy
10 | ignore = ~/.hgignore
11 | editor = vim
12 |
13 | [diff]
14 | git = 1
15 | unified = 8
16 | showfunc = True
17 | nodates = True
18 |
19 | [extdiff]
20 | cmd.opendiff = opendiff-w
21 | cmd.ksdiff = /usr/local/bin/ksdiff-wrapper
22 | opts.ksdiff = hg
23 |
24 | [merge-tools]
25 | filemerge.executable = opendiff-w
26 | filemerge.args = $local $other -ancestor $base -merge $output
27 |
28 | [hooks]
29 | post-push = hg phase --force --draft "mq()"
30 |
31 | [extensions]
32 | mq =
33 | rebase =
34 | purge =
35 | extdiff =
36 | convert =
37 | graphlog =
38 | bookmarks =
39 | color =
40 | # hgext.pager =
41 | #qimportbz = ~/.hgext/qimportbz
42 | #crecord = ~/.hgext/crecord/crecord
43 | #hggit = ~/.hgext/hg-git/hggit
44 | #hgext.pbranch = ~/.hgext/hg-pbranch/hgext/pbranch.py
45 | #prompt = ~/.hgext/hg-prompt/prompt.py
46 | # transplant =
47 |
48 | [transplant]
49 | # hg-transplant points to an executable in $PATH
50 | filter = hg-transplant
51 |
52 | [pager]
53 | pager = LESS='FSRX' less
54 | attend = annotate, cat, diff, export, glog, log, qdiff, outgoing, incoming, qseries
55 |
56 | [alias]
57 | qedit = !vim $(hg root)/.hg/patches/series
58 | qstatus = status --rev qtip^:qtip
59 | amend = commit --amend
60 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/tests/test_rev.py:
--------------------------------------------------------------------------------
1 | '''Test output of {node}.'''
2 |
3 | from nose import *
4 | from util import *
5 |
6 |
7 | def _parent_rev():
8 | opts = { 'template': '{rev}', 'rev': '.', 'date': None, 'user': None }
9 |
10 | _ui = get_sandbox_ui()
11 | _ui.pushbuffer()
12 | commands.log(_ui, get_sandbox_repo(), **opts)
13 |
14 | return _ui.popbuffer()
15 |
16 |
17 | @with_setup(setup_sandbox, teardown_sandbox)
18 | def test_nullrev():
19 | output = prompt(fs='{rev}')
20 | assert output == ''
21 |
22 | output = prompt(fs='{ at revision {rev}}')
23 | assert output == ''
24 |
25 |
26 | @with_setup(setup_sandbox, teardown_sandbox)
27 | def test_rev():
28 | hg_commit()
29 |
30 | output = prompt(fs='{rev}')
31 | assert output == _parent_rev()
32 |
33 | output = prompt(fs='{ at revision {rev}}')
34 | assert output == ' at revision %s' % _parent_rev()
35 |
36 | hg_commit()
37 | output = prompt(fs='{rev}')
38 | assert output == _parent_rev()
39 |
40 |
41 | @with_setup(setup_sandbox, teardown_sandbox)
42 | def test_merge_filter():
43 | hg_commit('one.txt')
44 | hg_commit('one.txt')
45 | rev_to_merge = _parent_rev()
46 |
47 | hg_update(0)
48 | hg_commit('two.txt')
49 | hg_merge(1)
50 |
51 | output = prompt(fs='{rev|merge}')
52 | assert output == rev_to_merge
53 |
54 | output = prompt(fs='{ merging with {rev|merge}}')
55 | assert output == ' merging with %s' % rev_to_merge
56 |
--------------------------------------------------------------------------------
/vim/vim.symlink/colors/native.vim:
--------------------------------------------------------------------------------
1 | "
2 | " Native Vim Color Scheme
3 | " =======================
4 | "
5 | " author: Armin Ronacher
6 | "
7 | set background=dark
8 |
9 | hi clear
10 | if exists("syntax_on")
11 | syntax reset
12 | endif
13 |
14 | let colors_name = "native"
15 |
16 | " Default Colors
17 | hi Normal guifg=#f2f2f2 guibg=#222222
18 | hi NonText guifg=#444444 guibg=#111111
19 | hi Cursor guibg=#aaaaaa
20 | hi lCursor guibg=#aaaaaa
21 |
22 | " Search
23 | hi Search guibg=peru guifg=wheat
24 | hi IncSearch cterm=NONE ctermfg=yellow ctermbg=green
25 | hi Search cterm=NONE ctermfg=grey ctermbg=blue
26 |
27 | " Window Elements
28 | hi StatusLine guifg=white guibg=#8090a0 gui=bold
29 | hi StatusLineNC guifg=#506070 guibg=#a0b0c0
30 | hi VertSplit guifg=#a0b0c0 guibg=#a0b0c0
31 | hi Folded guifg=#111111 guibg=#8090a0
32 | hi IncSearch guifg=slategrey guibg=khaki
33 |
34 | " Specials
35 | hi Todo guifg=#e50808 guibg=#520000 gui=bold
36 | hi Title guifg=#ffffff gui=bold
37 |
38 | " Strings
39 | hi String guifg=#ed9d13
40 | hi Constant guifg=#ed9d13
41 |
42 | " Syntax
43 | hi Number guifg=#3677a9
44 | hi Statement guifg=#6ab825 gui=bold
45 | hi Function guifg=#447fcf
46 | hi PreProc guifg=#cd2828 gui=bold
47 | hi Comment guifg=#999999 gui=italic
48 | hi Type guifg=#bbbbbb gui=bold
49 |
50 | " Diff
51 | hi DiffAdd ctermbg=4
52 | hi DiffChange ctermbg=5
53 | hi DiffDelete cterm=bold ctermfg=4 ctermbg=6
54 | hi DiffText cterm=bold ctermbg=1
55 |
56 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/README:
--------------------------------------------------------------------------------
1 | -*- markdown -*-
2 |
3 | hg-prompt
4 | =========
5 |
6 | hg-prompt adds an 'hg prompt' command to Mercurial for viewing repository information. It's designed to be used in a shell prompt.
7 |
8 |
9 | Requirements
10 | ------------
11 |
12 | hg-prompt requires Python 2.5+ and (obviously) Mercurial.
13 |
14 |
15 | Installing
16 | ----------
17 |
18 | Clone the repository:
19 |
20 | $ hg clone http://bitbucket.org/sjl/hg-prompt/
21 |
22 | Edit the `[extensions]` section in your `~/.hgrc` file:
23 |
24 | [extensions]
25 | prompt = (path to)/hg-prompt/prompt.py
26 |
27 |
28 | Documentation
29 | -------------
30 |
31 | The documentation for hg-prompt is at the [project page][project]. There's a [Quick Start guide][quickstart], [Full Usage Guide][usage], [Keyword List][keywords], and a few other things there.
32 |
33 | The documentation is stored in the `docs/` directory of the repository if you prefer to read it offline.
34 |
35 | [project]: http://sjl.bitbucket.org/hg-prompt/
36 | [quickstart]: http://sjl.bitbucket.org/hg-prompt/quickstart/
37 | [usage]: http://sjl.bitbucket.org/hg-prompt/documentation/usage/
38 | [keywords]: http://sjl.bitbucket.org/hg-prompt/documentation/keywords/
39 |
40 |
41 | Questions, Comments, Suggestions
42 | --------------------------------
43 |
44 | The code was kind of thrown together in a few nights after I got tired of chaining three or four hg runs together to get what I wanted. I'm sure it's not perfect, so if you've got a way to improve it please add an issue and let me know.
45 |
46 | Patches are also welcome!
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/src/pbranch/index.rextile:
--------------------------------------------------------------------------------
1 | h1. Patch Branches for Mercurial (pbranch)
2 |
3 |
4 |
5 | Needs Mercurial 1.5 now.
6 |
%(when)April 7, 2010%
7 |
8 | Supports Mercurial 1.4 with "octopus merges":octopus.htm now.
9 |
%(when)January 2, 2010%
10 |
11 |
12 |
13 |
14 | _Patch branches_ (pbranch) is a way to develop a series of patches for submission into a main repo. It is based on topic branches, one per patch, and is thus highly suitable for collaborative and/or long-term patch development and maintenance.
15 |
16 |
17 | h2. Documentation
18 |
19 | * "Introduction":intro.htm
20 |
21 | * "Configuration":config.htm
22 | * "Initialization and Simple Usage":simple.htm
23 | * "Submitting Patches by Email":email.htm
24 | * "Exporting Patches to Patch Queues (mq)":export.htm
25 | * "Distributing Changes To Patches":dist.htm
26 | * "Inserting and Deleting Patches":insert.htm
27 | * "Patch Graphs (Multiple Dependencies)":graph.htm
28 | * "Pulling And Merging From Upstream":pullupstream.htm
29 | * "Collaboration":collab.htm
30 | * "Octopus Merge Resolution":octopus.htm
31 | * "Sanity Checks":sanity.htm
32 |
33 | * "Blog":blog.htm
34 |
35 |
36 | h2. Getting The Code
37 |
38 | You can get the code from "this bitbucket.org repository":http://www.bitbucket.org/parren/hg-pbranch/. This is a clone of Mercurial with - tada! - patch branches. We also track issues there.
39 |
40 | To try it out, you need Mercurial 1.5 or later. Then, download the pbranch extension file and configure it as an extension in your @.hgrc@, like so:
41 |
42 | [extensions]
43 | pbranch = /path/to/pbranch.py
44 |
45 |
46 |
--------------------------------------------------------------------------------
/vim/vim.symlink/colors/wombat.vim:
--------------------------------------------------------------------------------
1 | " Maintainer: Lars H. Nielsen (dengmao@gmail.com)
2 | " Last Change: January 22 2007
3 |
4 | set background=dark
5 |
6 | hi clear
7 |
8 | if exists("syntax_on")
9 | syntax reset
10 | endif
11 |
12 | let colors_name = "wombat"
13 |
14 |
15 | " Vim >= 7.0 specific colors
16 | if version >= 700
17 | hi CursorLine guibg=#2d2d2d
18 | hi CursorColumn guibg=#2d2d2d
19 | hi MatchParen guifg=#f6f3e8 guibg=#857b6f gui=bold
20 | hi Pmenu guifg=#f6f3e8 guibg=#444444
21 | hi PmenuSel guifg=#000000 guibg=#cae682
22 | endif
23 |
24 | " General colors
25 | hi Cursor guifg=NONE guibg=#656565 gui=none
26 | hi Normal guifg=#f6f3e8 guibg=#242424 gui=none
27 | hi NonText guifg=#808080 guibg=#303030 gui=none
28 | hi LineNr guifg=#857b6f guibg=#000000 gui=none
29 | hi StatusLine guifg=#f6f3e8 guibg=#444444 gui=italic
30 | hi StatusLineNC guifg=#857b6f guibg=#444444 gui=none
31 | hi VertSplit guifg=#444444 guibg=#444444 gui=none
32 | hi Folded guibg=#384048 guifg=#a0a8b0 gui=none
33 | hi Title guifg=#f6f3e8 guibg=NONE gui=bold
34 | hi Visual guifg=#f6f3e8 guibg=#444444 gui=none
35 | hi SpecialKey guifg=#808080 guibg=#343434 gui=none
36 |
37 | " Syntax highlighting
38 | hi Comment guifg=#99968b gui=italic
39 | hi Todo guifg=#8f8f8f gui=italic
40 | hi Constant guifg=#e5786d gui=none
41 | hi String guifg=#95e454 gui=italic
42 | hi Identifier guifg=#cae682 gui=none
43 | hi Function guifg=#cae682 gui=none
44 | hi Type guifg=#cae682 gui=none
45 | hi Statement guifg=#8ac6f2 gui=none
46 | hi Keyword guifg=#8ac6f2 gui=none
47 | hi PreProc guifg=#e5786d gui=none
48 | hi Number guifg=#e5786d gui=none
49 | hi Special guifg=#e7f6da gui=none
50 |
51 |
52 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/docs/wiki/quickstart/index.mdown:
--------------------------------------------------------------------------------
1 | Quick Start
2 | ===========
3 |
4 | This guide will get you up and running so you can put some useful information
5 | into your shell prompt.
6 |
7 | If you haven't already [installed][install] it, do that now.
8 |
9 | [install]: /installation/
10 |
11 | A Simple (But Useful) Prompt
12 | ----------------------------
13 |
14 | Edit your `~/.bashrc` file to include something like this:
15 |
16 | :::bash
17 | hg_ps1() {
18 | hg prompt "{ on {branch}}{ at {bookmark}}{status}" 2> /dev/null
19 | }
20 |
21 | export PS1='\u at \h in \w$(hg_ps1)\n$ '
22 |
23 | `source ~/.bashrc` after to test it out. Make sure you're in a Mercurial
24 | repository or you won't see anything. This little prompt will give you
25 | something like this:
26 |
27 | :::console
28 | steve at myhost in ~/src/hg-prompt on default at feature-bookmark?
29 | $
30 |
31 | An Advanced Prompt
32 | ------------------
33 |
34 | How about something a little more interesting?
35 |
36 | :::bash
37 | hg_ps1() {
38 | hg prompt "{[+{incoming|count}]-->}{root|basename}{/{branch}}{-->[+{outgoing|count}]}{ at {bookmark}}{status}" 2> /dev/null
39 | }
40 |
41 | export PS1='$(hg_ps1)\n\u at \h in \w\n$ '
42 |
43 | And the result (this example assumes one incoming changeset and two outgoing):
44 |
45 | :::console
46 | [+1]-->hg-prompt/default-->[+2] at feature-bookmark
47 | steve at myhost in ~/src/hg-prompt
48 | $
49 |
50 | Learn More
51 | ----------
52 |
53 | From here you can take a look at the [full documentation][] to see all the
54 | interesting things `hg-prompt` can do.
55 |
56 | [full documentation]: /documentation/
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/docs/wiki/documentation/usage/index.mdown:
--------------------------------------------------------------------------------
1 | Usage
2 | =====
3 |
4 | The `hg prompt` command takes a single string as an argument and outputs it.
5 | Here's a simple (and useless) example:
6 |
7 | :::console
8 | $ hg prompt "test"
9 | test
10 |
11 | Keywords in curly braces can be used to output repository information:
12 |
13 | :::console
14 | $ hg prompt "currently on {branch}"
15 | currently on default
16 |
17 | Keywords also have an extended form:
18 |
19 | :::text
20 | {optional text{branch}more optional text}
21 |
22 | This form will output the text and the expanded keyword **only** if the
23 | keyword successfully expands. This can be useful for displaying extra text
24 | only if it's applicable:
25 |
26 | :::console
27 | $ hg prompt "currently on {branch} and at {bookmark}"
28 | currently on branch default and at
29 |
30 | $ hg prompt "currently on {branch} {and at {bookmark}}"
31 | currently on branch default
32 |
33 | $ hg bookmark my-book
34 |
35 | $ hg prompt "currently on {branch} {and at {bookmark}}"
36 | currently on branch default and at my-book
37 |
38 | You can give the `--angle-brackets` option to use angle brackets for keywords
39 | instead of curly brackets. This can come in handy when combining a simple
40 | prompt string with more complicated shell functionality (like color
41 | variables):
42 |
43 | :::console
44 | $ hg prompt "{currently on {branch}}"
45 | currently on default
46 |
47 | $ hg prompt --angle-brackets ">"
48 | currently on default
49 |
50 | Take a look at the [keywords][] documentation to see all the keywords
51 | `hg-prompt` supports.
52 |
53 | [keywords]: /documentation/keywords/
--------------------------------------------------------------------------------
/vim/vim.symlink/colors/wombat-zpao.vim:
--------------------------------------------------------------------------------
1 | " Maintainer: Lars H. Nielsen (dengmao@gmail.com)
2 | " Last Change: January 22 2007
3 | " Modified by: Paul O’Shannessy (paul@oshannessy.com)
4 |
5 | set background=dark
6 |
7 | hi clear
8 |
9 | if exists("syntax_on")
10 | syntax reset
11 | endif
12 |
13 | let colors_name = "wombat-zpao"
14 |
15 |
16 | " Vim >= 7.0 specific colors
17 | if version >= 700
18 | hi CursorLine guibg=#2d2d2d
19 | hi CursorColumn guibg=#2d2d2d
20 | hi MatchParen guifg=#f6f3e8 guibg=#857b6f gui=bold
21 | hi Pmenu guifg=#f6f3e8 guibg=#444444
22 | hi PmenuSel guifg=#000000 guibg=#cae682
23 | endif
24 |
25 | " General colors
26 | hi Cursor guifg=NONE guibg=#656565 gui=none
27 | hi Normal guifg=#f6f3e8 guibg=#242424 gui=none
28 | hi NonText guifg=#808080 guibg=#303030 gui=none
29 | hi LineNr guifg=#857b6f guibg=#000000 gui=none
30 | hi StatusLine guifg=#f6f3e8 guibg=#444444 gui=italic
31 | hi StatusLineNC guifg=#857b6f guibg=#444444 gui=none
32 | hi VertSplit guifg=#444444 guibg=#444444 gui=none
33 | hi Folded guibg=#384048 guifg=#a0a8b0 gui=none
34 | hi Title guifg=#f6f3e8 guibg=NONE gui=bold
35 | hi Visual guifg=#f6f3e8 guibg=#444444 gui=none
36 | hi SpecialKey guifg=#808080 guibg=#343434 gui=none
37 | hi ColorColumn guifg=NONE guibg=#444444 gui=none
38 |
39 | " Syntax highlighting
40 | hi Comment guifg=#99968b gui=italic
41 | hi Todo guifg=#8f8f8f gui=italic
42 | hi Constant guifg=#e5786d gui=none
43 | hi String guifg=#95e454 gui=italic
44 | hi Identifier guifg=#cae682 gui=none
45 | hi Function guifg=#cae682 gui=none
46 | hi Type guifg=#cae682 gui=none
47 | hi Statement guifg=#8ac6f2 gui=none
48 | hi Keyword guifg=#8ac6f2 gui=none
49 | hi PreProc guifg=#e5786d gui=none
50 | hi Number guifg=#e5786d gui=none
51 | hi Special guifg=#e7f6da gui=none
52 |
53 |
54 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/docs/static/media/css/typography.css:
--------------------------------------------------------------------------------
1 | html {
2 | font-family: "Helvetica Neue", Helvetica, Arial, Geneva, sans-serif;
3 | font-size: 10pt;
4 | }
5 |
6 | h1, h2, h3, h4, h5, h6 {
7 | font-weight: bold;
8 | }
9 |
10 | h1 {
11 | font-size: 2em;
12 | }
13 |
14 | h2 {
15 | font-size: 1.6em;
16 | }
17 |
18 | h3 {
19 | font-size: 1.3em;
20 | }
21 |
22 | h4 {
23 | font-size: 1.1em;
24 | font-weight: bold;
25 | }
26 |
27 | em {
28 | font-style: italic;
29 | }
30 |
31 | strong {
32 | font-weight: bold;
33 | }
34 |
35 | a {
36 | font-weight: bold;
37 | text-decoration: none;
38 | }
39 |
40 | table#files a:hover, table#subdirs a:hover, table#pages a:hover {
41 | color: #a00000;
42 | }
43 |
44 | p#footer a {
45 | text-decoration: none;
46 | }
47 |
48 | p code, ul code, ol code, dl code, blockquote code, tbody code, thead code {
49 | font-size: 8pt;
50 | }
51 |
52 | pre, code, tt, table#subdirs tr td.name, table#files tr td.name, table tr td.size {
53 | font-family: Monaco, "DejaVu Sans Mono", "Bitstream Vera Sans Mono", Menlo, Inconsolata, Consolas, "Courier New", Courier;
54 | }
55 |
56 | table#subdirs code, table#files code {
57 | font-size: 10pt;
58 | }
59 |
60 | table.codehilitetable div.linenodiv {
61 | color: #777;
62 | }
63 |
64 | blockquote {
65 | color: #222;
66 | font-style: italic;
67 | }
68 |
69 | pre {
70 | overflow-x: auto; /* Use horizontal scroller if needed; for Firefox 2, not needed in Firefox 3 */
71 | white-space: pre-wrap; /* css-3 */
72 | white-space: -moz-pre-wrap !important; /* Mozilla, since 1999 */
73 | white-space: -pre-wrap; /* Opera 4-6 */
74 | white-space: -o-pre-wrap; /* Opera 7 */
75 | /* width: 99%; */
76 | word-wrap: break-word; /* Internet Explorer 5.5+ */
77 | }
78 |
79 | table thead th {
80 | font-weight: bold;
81 | }
82 |
83 | .list-crumb {
84 | color: #777;
85 | font-variant: italic;
86 | }
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/tests/util.py:
--------------------------------------------------------------------------------
1 | """Utilities for writing unit tests for hg-prompt."""
2 |
3 | import os, shutil, sys
4 | from mercurial import cmdutil, commands, hg, ui
5 |
6 | pkg_path = os.path.realpath(__file__)
7 | sys.path =[os.path.split(os.path.split(pkg_path)[0])[0]] + sys.path
8 | from prompt import prompt as _prompt
9 |
10 | _ui = ui.ui()
11 | def prompt(fs=''):
12 | _ui.pushbuffer()
13 | _prompt(_ui, get_sandbox_repo(), fs=fs)
14 | output = _ui.popbuffer()
15 |
16 | print output
17 | return output
18 |
19 |
20 | sandbox_path = os.path.join(os.path.realpath('.'), 'sandbox')
21 |
22 | def setup_sandbox():
23 | os.mkdir(sandbox_path)
24 | os.chdir(sandbox_path)
25 |
26 | commands.init(_ui)
27 |
28 | def teardown_sandbox():
29 | os.chdir(os.path.realpath(os.path.join(sandbox_path, os.pardir)))
30 | shutil.rmtree(sandbox_path)
31 |
32 | def get_sandbox_repo():
33 | return hg.repository(_ui, sandbox_path)
34 |
35 | def get_sandbox_ui():
36 | return _ui
37 |
38 |
39 | # Mercurial command wrappers
40 |
41 | def hg_branch(branch='test'):
42 | commands.branch(_ui, get_sandbox_repo(), branch)
43 |
44 | def hg_update(rev):
45 | opts = { 'rev': str(rev), }
46 | commands.update(_ui, get_sandbox_repo(), **opts)
47 |
48 | def hg_merge(rev):
49 | opts = { 'rev': str(rev) }
50 | commands.merge(_ui, get_sandbox_repo(), **opts)
51 |
52 | def hg_commit(filename='text.txt'):
53 | with open(os.path.join(sandbox_path, filename), 'a') as test_file:
54 | test_file.writelines(['test', '.'])
55 |
56 | opts = { 'addremove': True, 'date': None, 'user': 'Prompt Tester',
57 | 'logfile': None, 'message': "Sandbox commit." }
58 | commands.commit(get_sandbox_ui(), get_sandbox_repo(), **opts)
59 |
60 | def hg_log():
61 | opts = { 'template': '{rev} {desc}\n', 'rev': None, 'date': None, 'user': None }
62 |
63 | _ui.pushbuffer()
64 | commands.log(_ui, get_sandbox_repo(), **opts)
65 | output = _ui.popbuffer()
66 |
67 | return output
68 |
69 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/tests/test_tip.py:
--------------------------------------------------------------------------------
1 | '''Test output of {tip}.'''
2 |
3 | from nose import *
4 | from util import *
5 |
6 |
7 | def _tip_rev():
8 | opts = { 'template': '{rev}', }
9 |
10 | _ui = get_sandbox_ui()
11 | _ui.pushbuffer()
12 | commands.tip(_ui, get_sandbox_repo(), **opts)
13 |
14 | return _ui.popbuffer()
15 |
16 | def _tip_node():
17 | opts = { 'template': '{node}', }
18 |
19 | _ui = get_sandbox_ui()
20 | _ui.pushbuffer()
21 | commands.tip(_ui, get_sandbox_repo(), **opts)
22 |
23 | return _ui.popbuffer()
24 |
25 |
26 | @with_setup(setup_sandbox, teardown_sandbox)
27 | def test_empty_repo():
28 | output = prompt(fs='{tip}')
29 | assert output == ''
30 |
31 | output = prompt(fs='{ the tip is at {tip}}')
32 | assert output == ''
33 |
34 |
35 | @with_setup(setup_sandbox, teardown_sandbox)
36 | def test_tip():
37 | hg_commit()
38 |
39 | output = prompt(fs='{tip}')
40 | assert output == _tip_rev()
41 |
42 | output = prompt(fs='{ the tip is {tip}}')
43 | assert output == ' the tip is %s' % _tip_rev()
44 |
45 | hg_commit()
46 | output = prompt(fs='{tip}')
47 | assert output == _tip_rev()
48 |
49 |
50 | @with_setup(setup_sandbox, teardown_sandbox)
51 | def test_node_filter():
52 | hg_commit()
53 |
54 | output = prompt(fs='{tip|node}')
55 | assert output == _tip_node()
56 |
57 | output = prompt(fs='{ the tip is {tip|node}}')
58 | assert output == ' the tip is %s' % _tip_node()
59 |
60 | hg_commit()
61 | output = prompt(fs='{tip|node}')
62 | assert output == _tip_node()
63 |
64 |
65 | @with_setup(setup_sandbox, teardown_sandbox)
66 | def test_short_filter():
67 | hg_commit()
68 |
69 | output = prompt(fs='{tip|node|short}')
70 | assert output == _tip_node()[:12]
71 |
72 | output = prompt(fs='{ the tip is {tip|node|short}}')
73 | assert output == ' the tip is %s' % _tip_node()[:12]
74 |
75 | hg_commit()
76 | output = prompt(fs='{tip|node|short}')
77 | assert output == _tip_node()[:12]
78 |
--------------------------------------------------------------------------------
/zsh/zshrc.symlink:
--------------------------------------------------------------------------------
1 | if [ -n "${ZSH_DEBUGRC+1}" ]; then
2 | zmodload zsh/zprof
3 | fi
4 |
5 | export LC_ALL=en_US.UTF-8
6 | export LANG=en_US.UTF-8
7 |
8 | # shortcut to this dotfiles path is $ZSH
9 | export ZSH=$HOME/.dotfiles
10 |
11 | export DOTFILES=$HOME/.dotfiles
12 |
13 | # your project folder that we can `c [tab]` to
14 | export PROJECTS=~/Code
15 |
16 | # Stash your environment variables in ~/.localrc. This means they'll stay out
17 | # of your main dotfiles repository (which may be public, like this one), but
18 | # you'll have access to them in your scripts.
19 | if [[ -a ~/.localrc ]]
20 | then
21 | source ~/.localrc
22 | fi
23 |
24 | if [[ ! -f ~/.zpm/zpm.zsh ]]; then
25 | git clone --recursive https://github.com/zpm-zsh/zpm ~/.zpm
26 | fi
27 | source ~/.zpm/zpm.zsh
28 |
29 | ### VSCode
30 | zpm if vscode load zpm-zsh/vscode
31 |
32 | ### iTerm2
33 | zpm if iterm load zpm-zsh/iterm
34 |
35 |
36 | # Load homebrew first since it adds to $PATH for lots of other uses
37 | zpm load @dir/homebrew,origin:$DOTFILES/homebrew/plugin
38 |
39 | # TODO fix ll alias. missing -a
40 | zpm load \
41 | zpm-zsh/core-config \
42 | @dir/core-config-local,origin:$DOTFILES/system/core-config-local-plugin \
43 | @dir/colorize,origin:$DOTFILES/system/colorize-plugin \
44 | zpm-zsh/ssh,async \
45 | zpm-zsh/undollar,async
46 |
47 | ### Plugins for local host
48 | zpm if-not ssh load \
49 | @dir/conda,origin:$DOTFILES/conda/plugin \
50 | @dir/fb,origin:$DOTFILES/fb/plugin \
51 | @dir/gist,origin:$DOTFILES/gist/plugin \
52 | @dir/git,origin:$DOTFILES/git/plugin \
53 | @dir/go,origin:$DOTFILES/go/plugin \
54 | @dir/ocaml,origin:$DOTFILES/ocaml/plugin \
55 | @dir/pnpm,origin:$DOTFILES/pnpm/plugin \
56 | @dir/rbenv,origin:$DOTFILES/rbenv/plugin \
57 | @dir/starship,origin:$DOTFILES/starship/plugin \
58 | ajeetdsouza/zoxide,async \
59 | zpm-zsh/colorize,async \
60 | zpm-zsh/clipboard,async \
61 | zpm-zsh/nvm,async \
62 | zpm-zsh/rust,async \
63 | zpm-zsh/zsh-history-substring-search,async
64 |
65 | if [ -n "${ZSH_DEBUGRC+1}" ]; then
66 | zprof
67 | fi
68 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/tests/test_node.py:
--------------------------------------------------------------------------------
1 | '''Test output of {node}.'''
2 |
3 | from nose import *
4 | from util import *
5 |
6 |
7 | def _parent_node():
8 | opts = { 'template': '{node}', 'rev': '.', 'date': None, 'user': None }
9 |
10 | _ui = get_sandbox_ui()
11 | _ui.pushbuffer()
12 | commands.log(_ui, get_sandbox_repo(), **opts)
13 |
14 | return _ui.popbuffer()
15 |
16 |
17 | @with_setup(setup_sandbox, teardown_sandbox)
18 | def test_node():
19 | output = prompt(fs='{node}')
20 | assert output == '0000000000000000000000000000000000000000'
21 |
22 | output = prompt(fs='{ at node {node}}')
23 | assert output == ' at node 0000000000000000000000000000000000000000'
24 |
25 | hg_commit()
26 | output = prompt(fs='{node}')
27 | assert output == _parent_node()
28 |
29 | hg_commit()
30 | output = prompt(fs='{node}')
31 | assert output == _parent_node()
32 |
33 | hg_update(0)
34 | output = prompt(fs='{node}')
35 | assert output == _parent_node()
36 |
37 |
38 | @with_setup(setup_sandbox, teardown_sandbox)
39 | def test_short_filter():
40 | output = prompt(fs='{node|short}')
41 | assert output == '0000000000000000000000000000000000000000'[:12]
42 |
43 | output = prompt(fs='{ at node {node|short}}')
44 | assert output == ' at node ' + '0000000000000000000000000000000000000000'[:12]
45 |
46 | hg_commit()
47 | output = prompt(fs='{node|short}')
48 | assert output == _parent_node()[:12]
49 |
50 | hg_commit()
51 | output = prompt(fs='{node|short}')
52 | assert output == _parent_node()[:12]
53 |
54 | hg_update(0)
55 | output = prompt(fs='{node|short}')
56 | assert output == _parent_node()[:12]
57 |
58 |
59 | @with_setup(setup_sandbox, teardown_sandbox)
60 | def test_merge_filter():
61 | hg_commit('one.txt')
62 | hg_commit('one.txt')
63 | node_to_merge = _parent_node()
64 |
65 | hg_update(0)
66 | hg_commit('two.txt')
67 | hg_merge(1)
68 |
69 | output = prompt(fs='{node|merge}')
70 | assert output == node_to_merge
71 |
72 | output = prompt(fs='{node|merge|short}')
73 | assert output == node_to_merge[:12]
74 |
--------------------------------------------------------------------------------
/vim/vim.symlink/colors/Mustang.vim:
--------------------------------------------------------------------------------
1 | " Maintainer: Henrique C. Alves (hcarvalhoalves@gmail.com)
2 | " Version: 1.0
3 | " Last Change: September 25 2008
4 |
5 | set background=dark
6 |
7 | hi clear
8 |
9 | if exists("syntax_on")
10 | syntax reset
11 | endif
12 |
13 | let colors_name = "mustang"
14 |
15 | " Vim >= 7.0 specific colors
16 | if version >= 700
17 | hi CursorLine guibg=#2d2d2d ctermbg=236
18 | hi CursorColumn guibg=#2d2d2d ctermbg=236
19 | hi MatchParen guifg=#d0ffc0 guibg=#2f2f2f gui=bold ctermfg=157 ctermbg=237 cterm=bold
20 | hi Pmenu guifg=#ffffff guibg=#444444 ctermfg=255 ctermbg=238
21 | hi PmenuSel guifg=#000000 guibg=#b1d631 ctermfg=0 ctermbg=148
22 | endif
23 |
24 | " General colors
25 | hi Cursor guifg=NONE guibg=#626262 gui=none ctermbg=241
26 | hi Normal guifg=#e2e2e5 guibg=#202020 gui=none ctermfg=253 ctermbg=234
27 | hi NonText guifg=#808080 guibg=#303030 gui=none ctermfg=244 ctermbg=235
28 | hi LineNr guifg=#808080 guibg=#000000 gui=none ctermfg=244 ctermbg=232
29 | hi StatusLine guifg=#d3d3d5 guibg=#444444 gui=italic ctermfg=253 ctermbg=238 cterm=italic
30 | hi StatusLineNC guifg=#939395 guibg=#444444 gui=none ctermfg=246 ctermbg=238
31 | hi VertSplit guifg=#444444 guibg=#444444 gui=none ctermfg=238 ctermbg=238
32 | hi Folded guibg=#384048 guifg=#a0a8b0 gui=none ctermbg=4 ctermfg=248
33 | hi Title guifg=#f6f3e8 guibg=NONE gui=bold ctermfg=254 cterm=bold
34 | hi Visual guifg=#faf4c6 guibg=#3c414c gui=none ctermfg=254 ctermbg=4
35 | hi SpecialKey guifg=#808080 guibg=#343434 gui=none ctermfg=244 ctermbg=236
36 |
37 | " Syntax highlighting
38 | hi Comment guifg=#808080 gui=italic ctermfg=244
39 | hi Todo guifg=#8f8f8f gui=italic ctermfg=245
40 | hi Boolean guifg=#b1d631 gui=none ctermfg=148
41 | hi String guifg=#b1d631 gui=italic ctermfg=148
42 | hi Identifier guifg=#b1d631 gui=none ctermfg=148
43 | hi Function guifg=#ffffff gui=bold ctermfg=255
44 | hi Type guifg=#7e8aa2 gui=none ctermfg=103
45 | hi Statement guifg=#7e8aa2 gui=none ctermfg=103
46 | hi Keyword guifg=#ff9800 gui=none ctermfg=208
47 | hi Constant guifg=#ff9800 gui=none ctermfg=208
48 | hi Number guifg=#ff9800 gui=none ctermfg=208
49 | hi Special guifg=#ff9800 gui=none ctermfg=208
50 | hi PreProc guifg=#faf4c6 gui=none ctermfg=230
51 | hi Todo guifg=#000000 guibg=#e6ea50 gui=italic
52 |
53 | " Code-specific colors
54 | hi pythonOperator guifg=#7e8aa2 gui=none ctermfg=103
55 |
56 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/src/pbranch/config.rextile:
--------------------------------------------------------------------------------
1 |
2 | h1. Configuration
3 |
4 | h5. .hgrc
5 |
6 | To use pbranch, you need to enable it as a Mercurial extension in an @hgrc@ file. It depends on the @graphlog@ extension, so you should have (and probably enable) the latter as well. We also enable mq here to show how pbranch interoperates with mq.
7 |
8 | $ cat >~/.hgrc <<-eof
9 | [extensions]
10 | hgext.pbranch =
11 | hgext.graphlog =
12 | hgext.mq =
13 | eof
14 |
15 | For this demo environment, I need a few more settings, though. In particular, I shall be using git-style diffs with no context and a one-line default log template to keep the demo output concise. I also turn off interactive merging so I can run the demo from a script:
16 |
17 | $ cat >>~/.hgrc <<-eof
18 | [defaults]
19 | pdiff = --git --unified 0
20 | pemail = --git --unified 0
21 | pexport = --git --unified 0
22 | diff = --git --unified 0
23 | commit = --date '0 0'
24 | pnew = --date '0 0'
25 | pmerge = --date '0 0'
26 | peditmessage = --date '0 0'
27 |
28 | [ui]
29 | username = john
30 | logtemplate = "{rev}\t{branches}: {desc|firstline} - {author|user}\n"
31 | merge = internal:merge
32 | editor = cat
33 | eof
34 |
35 | To check the setup, run:
36 |
37 | $ hg help pbranch
38 | pbranch extension - manages evolving patches as topic branches (an alternative to mq)
39 | _
40 | This extension lets you develop patches collaboratively in special topic
41 | branches of temporary clones of the main repository.
42 | _
43 | For more information:
44 | http://www.selenic.com/mercurial/wiki/index.cgi/PatchBranchExtension
45 | _
46 | list of commands:
47 | _
48 | pbackout backs out the current patch branch (undoes all its changes)
49 | pdiff prints the final diff for the current or given patch branch
50 | peditmessage edit the patch message
51 | pemail send patches by email
52 | pexport exports patches
53 | pgraph print an ASCII art rendering of the patch dependency graph
54 | pmerge merge pending heads from dependencies into patch branches
55 | pmessage print the patch message(s)
56 | pnew start a new patch branch
57 | pstatus print status of current (or given) patch branch
58 | reapply reverts the working copy of all files touched by REV to REV
59 | _
60 | use "hg -v help pbranch" to show builtin aliases and global options
61 |
62 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/docs/wiki/documentation/samples/index.mdown:
--------------------------------------------------------------------------------
1 | Sample Prompts
2 | ==============
3 |
4 | `hg-prompt` supports many keywords, but you probably don't want to use them
5 | all at once. Which keywords you'll find useful depends on the workflow(s) you
6 | commonly use.
7 |
8 | Here are some example prompts to get you started.
9 |
10 | A Basic Prompt
11 | --------------
12 |
13 | A very simple prompt could tell you:
14 |
15 | * Which named branch you're currently working on.
16 | * If there are any uncommitted changes in the working directory.
17 | * If you're at a revision that's not a branch tip (i.e. if running `hg update`
18 | would do something).
19 |
20 | To get a prompt like this you could add this to your `~/.bashrc` file:
21 |
22 | :::bash
23 | export PS1='\u in \w`hg prompt "{on {branch}}{status}{update}" 2>/dev/null` $'
24 |
25 | The result would look something like this:
26 |
27 | :::text
28 | username in ~/src $ cd project
29 | username in ~/src/project on feature-branch $ touch sample
30 | username in ~/src/project on feature-branch? $ hg add sample
31 | username in ~/src/project on feature-branch! $ hg commit -m 'Add a file.'
32 | username in ~/src/project on feature-branch $ hg update default
33 | username in ~/src/project on default $ hg update 0
34 | username in ~/src/project on default^ $
35 |
36 | The `2>/dev/null` part of the prompt command prevents errors from showing when
37 | you're not currently in a Mercurial repository.
38 |
39 | The keywords (`{branch}`, `{status}` and `{update}`) display the relevant
40 | information.
41 |
42 | The extra text in the `{branch}` keyword will only display if a branch exists,
43 | so you won't see the word "on" if you're not in a repository.
44 |
45 | A More Compact Basic Prompt
46 | ---------------------------
47 |
48 | Some people prefer a smaller, less obtrusive prompt. To get that kind of
49 | prompt you can omit some of the less important text:
50 |
51 | :::bash
52 | export PS1='\w`hg prompt "[{branch}{status}{update}]" 2>/dev/null` $'
53 |
54 | That will give you something like this:
55 |
56 | :::text
57 | ~/src $ cd project
58 | ~/src/project[feature-branch] $ touch sample
59 | ~/src/project[feature-branch?] $ hg add sample
60 | ~/src/project[feature-branch!] $ hg commit -m 'Add a file.'
61 | ~/src/project[feature-branch] $ hg update default
62 | ~/src/project[default] $ hg update 0
63 | ~/src/project[default^] $
64 |
--------------------------------------------------------------------------------
/bin/mvim:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 | #
3 | # This shell script passes all its arguments to the binary inside the
4 | # MacVim.app application bundle. If you make links to this script as view,
5 | # gvim, etc., then it will peek at the name used to call it and set options
6 | # appropriately.
7 | #
8 | # Based on a script by Wout Mertens and suggestions from Laurent Bihanic. This
9 | # version is the fault of Benji Fisher, 16 May 2005 (with modifications by Nico
10 | # Weber and Bjorn Winckler, Aug 13 2007).
11 | # First, check "All the Usual Suspects" for the location of the Vim.app bundle.
12 | # You can short-circuit this by setting the VIM_APP_DIR environment variable
13 | # or by un-commenting and editing the following line:
14 | # VIM_APP_DIR=/Applications
15 |
16 | if [ -z "$VIM_APP_DIR" ]
17 | then
18 | myDir="`dirname "$0"`"
19 | myAppDir="$myDir/../Applications"
20 | for i in ~/Applications ~/Applications/vim $myDir $myDir/vim $myAppDir $myAppDir/vim /Applications /Applications/vim /Applications/Utilities /Applications/Utilities/vim; do
21 | if [ -x "$i/MacVim.app" ]; then
22 | VIM_APP_DIR="$i"
23 | break
24 | fi
25 | done
26 | fi
27 | if [ -z "$VIM_APP_DIR" ]
28 | then
29 | echo "Sorry, cannot find MacVim.app. Try setting the VIM_APP_DIR environment variable to the directory containing MacVim.app."
30 | exit 1
31 | fi
32 | binary="$VIM_APP_DIR/MacVim.app/Contents/MacOS/Vim"
33 |
34 | # Next, peek at the name used to invoke this script, and set options
35 | # accordingly.
36 |
37 | name="`basename "$0"`"
38 | gui=
39 | opts=
40 |
41 | # GUI mode, implies forking
42 | case "$name" in m*|g*|rm*|rg*) gui=true ;; esac
43 |
44 | # Restricted mode
45 | case "$name" in r*) opts="$opts -Z";; esac
46 |
47 | # vimdiff, view, and ex mode
48 | case "$name" in
49 | *vimdiff)
50 | opts="$opts -dO"
51 | ;;
52 | *view)
53 | opts="$opts -R"
54 | ;;
55 | *ex)
56 | opts="$opts -e"
57 | ;;
58 | esac
59 |
60 | # Last step: fire up vim.
61 | # The program should fork by default when started in GUI mode, but it does
62 | # not; we work around this when this script is invoked as "gvim" or "rgview"
63 | # etc., but not when it is invoked as "vim -g".
64 | if [ "$gui" ]; then
65 | # Note: this isn't perfect, because any error output goes to the
66 | # terminal instead of the console log.
67 | # But if you use open instead, you will need to fully qualify the
68 | # path names for any filenames you specify, which is hard.
69 | exec "$binary" -g $opts ${1:+"$@"}
70 | else
71 | exec "$binary" $opts ${1:+"$@"}
72 | fi
73 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/qimportbz/scp.py:
--------------------------------------------------------------------------------
1 | import os
2 | import re
3 | try:
4 | import cStringIO as StringIO
5 | except ImportError:
6 | import StringIO
7 | import subprocess
8 | import sys
9 | import tempfile
10 | import urllib
11 | import urllib2
12 |
13 | def _relpath(filepath, start=os.curdir):
14 | """os.path.relpath is 2.6+, so don't rely on it being present.
15 | See the os.path.relpath docs for further reference."""
16 | path, filename = os.path.split(filepath)
17 | pathdrive, path = os.path.splitdrive(os.path.abspath(path))
18 | startdrive, start = os.path.splitdrive(os.path.abspath(start))
19 | prefix = os.path.commonprefix((path, start))
20 |
21 | # interesting question: is it possible to construct a relative path
22 | # on windows that specifies a location on a drive different than the
23 | # drive in which the cwd is?
24 | assert pathdrive == startdrive
25 |
26 | def splitparts(p): return filter(lambda s: s != '', p.split(os.sep))
27 | prefixlen = len(splitparts(prefix))
28 | pathparts = splitparts(path)[prefixlen:]
29 | startparts = splitparts(start)[prefixlen:]
30 |
31 | # walk from |start| to the LCA ...
32 | relpath = os.sep.join([ '..' ] * len(startparts))
33 |
34 | # then back down to |filepath|
35 | relpath = os.path.join(relpath, path)
36 |
37 | return os.path.join(relpath, filename)
38 |
39 |
40 | class Handler(urllib2.BaseHandler):
41 | def __init__(self, ui, passmgr):
42 | self.ui = ui
43 | self.passmgr = passmgr
44 | self.scp = ui.config('qimportbz', 'scp', os.environ.get('SCP', "scp"))
45 |
46 | def scp_escape(self, path):
47 | return re.sub(r'(?.
12 | ## This program is free software: you can redistribute it and/or modify
13 | ## it under the terms of the GNU General Public License as published by
14 | ## the Free Software Foundation, either version 3 of the License, or (at
15 | ## your option) any later version.
16 | ##
17 | ## This program is distributed in the hope that it will be useful,
18 | ## but WITHOUT ANY WARRANTY; without even the implied warranty of
19 | ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 | ## GNU General Public License for more details.
21 | ##
22 | ## You can find the GNU General Public License at:
23 | ## http://www.gnu.org/licenses/
24 |
25 | class String
26 | def obfuscate; gsub(/@/, " at the ").gsub(/\.(\w+)(>|$)/, ' dot \1s\2') end
27 | def htmlize; gsub("&", "&").gsub("<", "<").gsub(">", ">") end
28 | # Fix for invalid encodings http://stackoverflow.com/a/24037885
29 | def clean
30 | if RUBY_VERSION >= "2.1"
31 | scrub
32 | elsif RUBY_VERSION >= "1.9"
33 | encode("UTF-16be", :invalid => :replace).encode("UTF-8")
34 | else
35 | self
36 | end
37 | end
38 | end
39 |
40 | lines = {}
41 | verbose = ARGV.delete("-v")
42 | obfuscate = ARGV.delete("-o")
43 | htmlize = ARGV.delete("-h")
44 |
45 | author = nil
46 | state = :pre_author
47 | `git log -M -C -C -p --no-color`.clean.split("\n").each do |l|
48 | case
49 | when (state == :pre_author || state == :post_author) && l =~ /Author: (.*)$/
50 | author = $1
51 | state = :post_author
52 | lines[author] ||= 0
53 | when state == :post_author && l =~ /^\+\+\+/
54 | state = :in_diff
55 | when state == :in_diff && l =~ /^[\+\-]/
56 | lines[author] += 1
57 | when state == :in_diff && l =~ /^commit /
58 | state = :pre_author
59 | end
60 | end
61 |
62 | lines.sort_by { |a, c| -c }.each do |a, c|
63 | a = a.obfuscate if obfuscate
64 | a = a.htmlize if htmlize
65 | if verbose
66 | puts "#{a}: #{c} lines of diff"
67 | else
68 | puts a
69 | end
70 | end
71 |
--------------------------------------------------------------------------------
/git/gitconfig.symlink:
--------------------------------------------------------------------------------
1 | # Local/private config goes in the include
2 | [include]
3 | path = ~/.gitconfig.local
4 | [hub]
5 | protocol = https
6 | [alias]
7 | # shortcuts (literally just to type less)
8 | st = status -sb
9 | co = checkout
10 |
11 | # more functionality
12 | # add all files
13 | all = add -A
14 | # amend last commit and use last commit message
15 | amend = commit --amend --no-edit
16 | # amend but open editor
17 | amende = commit --amend
18 | # what has changed on this branch
19 | brlog = log master..
20 | brdiff = branch-diff
21 | # not terribly useful but interesting - count commits per person
22 | count = shortlog -sn
23 | # echo the current branch
24 | current-branch = rev-parse --abbrev-ref HEAD
25 | default-branch = !git remote show origin | sed -n '/HEAD branch/s/.*: //p'
26 | # log in tree format
27 | lg = log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --all
28 | # what hasn't been pushed to origin
29 | out = log --branches --not --remotes=origin
30 | # diff staging area
31 | staged = diff --staged
32 | # unstage changes but leave intact
33 | unstage = reset HEAD
34 | # push the current branch to origin, setting up a new remote branch and setting up tracking
35 | promote = !git push -u origin `git current-branch`
36 | # promote to upstream (my personal pattern for forking upstreams)
37 | promoteu = !git push -u upstream `git current-branch`
38 | [color]
39 | diff = auto
40 | status = auto
41 | branch = auto
42 | ui = true
43 | [core]
44 | excludesfile = ~/.gitignore
45 | editor = vim
46 | [apply]
47 | whitespace = nowarn
48 | [mergetool]
49 | keepBackup = false
50 | [difftool]
51 | prompt = false
52 | [help]
53 | autocorrect = 1
54 | [push]
55 | # See `git help config` (search for push.default)
56 | # for more information on different options of the below setting.
57 | #
58 | # Setting to git 2.0 default to suppress warning message
59 | default = simple
60 | [diff]
61 | tool = !opendiff "$2" "$5" -merge "$1"
62 | [filter "lfs"]
63 | clean = git-lfs clean -- %f
64 | smudge = git-lfs smudge -- %f
65 | required = true
66 | process = git-lfs filter-process
67 | [pull]
68 | ff = only
69 | [init]
70 | defaultBranch = trunk
71 |
--------------------------------------------------------------------------------
/vim/vim.symlink/colors/neon.vim:
--------------------------------------------------------------------------------
1 | " Vim color file
2 | " Maintainer: Tiza
3 | " Last Change: 2002/10/25 Fri 16:23.
4 | " version: 1.2
5 | " This color scheme uses a dark background.
6 |
7 | set background=dark
8 | hi clear
9 | if exists("syntax_on")
10 | syntax reset
11 | endif
12 |
13 | let colors_name = "neon"
14 |
15 | hi Normal guifg=#f0f0f0 guibg=#303030
16 |
17 | " Search
18 | hi IncSearch gui=UNDERLINE guifg=#80ffff guibg=#0060c0
19 | hi Search gui=NONE guifg=#ffffa8 guibg=#808000
20 | " hi Search gui=NONE guifg=#b0ffb0 guibg=#008000
21 |
22 | " Messages
23 | hi ErrorMsg gui=BOLD guifg=#ffa0ff guibg=NONE
24 | hi WarningMsg gui=BOLD guifg=#ffa0ff guibg=NONE
25 | hi ModeMsg gui=BOLD guifg=#a0d0ff guibg=NONE
26 | hi MoreMsg gui=BOLD guifg=#70ffc0 guibg=#8040ff
27 | hi Question gui=BOLD guifg=#e8e800 guibg=NONE
28 |
29 | " Split area
30 | hi StatusLine gui=NONE guifg=#000000 guibg=#c4c4c4
31 | hi StatusLineNC gui=NONE guifg=#707070 guibg=#c4c4c4
32 | hi VertSplit gui=NONE guifg=#707070 guibg=#c4c4c4
33 | hi WildMenu gui=NONE guifg=#000000 guibg=#ff80c0
34 |
35 | " Diff
36 | hi DiffText gui=NONE guifg=#ff78f0 guibg=#a02860
37 | hi DiffChange gui=NONE guifg=#e03870 guibg=#601830
38 | hi DiffDelete gui=NONE guifg=#a0d0ff guibg=#0020a0
39 | hi DiffAdd gui=NONE guifg=#a0d0ff guibg=#0020a0
40 |
41 | " Cursor
42 | hi Cursor gui=NONE guifg=#70ffc0 guibg=#8040ff
43 | hi lCursor gui=NONE guifg=#ffffff guibg=#8800ff
44 | hi CursorIM gui=NONE guifg=#ffffff guibg=#8800ff
45 |
46 | " Fold
47 | hi Folded gui=NONE guifg=#40f0f0 guibg=#006090
48 | hi FoldColumn gui=NONE guifg=#40c0ff guibg=#404040
49 |
50 | " Other
51 | hi Directory gui=NONE guifg=#c8c8ff guibg=NONE
52 | hi LineNr gui=NONE guifg=#707070 guibg=NONE
53 | hi NonText gui=BOLD guifg=#d84070 guibg=#383838
54 | hi SpecialKey gui=BOLD guifg=#8888ff guibg=NONE
55 | hi Title gui=BOLD guifg=fg guibg=NONE
56 | hi Visual gui=NONE guifg=#b0ffb0 guibg=#008000
57 | hi VisualNOS gui=NONE guifg=#ffe8c8 guibg=#c06800
58 |
59 | " Syntax group
60 | hi Comment gui=NONE guifg=#c0c0c0 guibg=NONE
61 | hi Constant gui=NONE guifg=#92d4ff guibg=NONE
62 | hi Error gui=BOLD guifg=#ffffff guibg=#8000ff
63 | hi Identifier gui=NONE guifg=#40f8f8 guibg=NONE
64 | hi Ignore gui=NONE guifg=bg guibg=NONE
65 | hi PreProc gui=NONE guifg=#ffa8ff guibg=NONE
66 | hi Special gui=NONE guifg=#ffc890 guibg=NONE
67 | hi Statement gui=NONE guifg=#dcdc78 guibg=NONE
68 | hi Todo gui=BOLD,UNDERLINE guifg=#ff80d0 guibg=NONE
69 | hi Type gui=NONE guifg=#60f0a8 guibg=NONE
70 | hi Underlined gui=UNDERLINE guifg=fg guibg=NONE
71 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/src/pbranch/sanity.rextile:
--------------------------------------------------------------------------------
1 |
2 | h1. Sanity Checks
3 |
4 | <%= toc %>
5 |
6 |
7 | h2. Initialization
8 |
9 | $ hg init sanity
10 | $ cd sanity
11 |
12 | $ cat >.hg/pgraph <<-eof
13 | a: b
14 | b: a
15 | eof
16 |
17 | $ hg pgraph
18 | abort: patch dependency cycle detected involving b and a
19 |
20 | $ cd ..
21 |
22 |
23 | h2. Empty Repos
24 |
25 | See "Issue 35":http://bitbucket.org/parren/hg-pbranch/issue/35/.
26 |
27 | $ hg init empty
28 | $ cd empty
29 |
30 | $ hg pnew one
31 | marked working directory as branch one
32 | $ hg pgraph -tns
33 | @ [one]
34 | |
35 | o default
36 |
37 | $ hg pnew two
38 | marked working directory as branch two
39 | $ hg up one
40 | 0 files updated, 0 files merged, 1 files removed, 0 files unresolved
41 | $ echo a >a
42 | $ hg ci -Ama
43 | adding a
44 | $ hg pgraph -tns
45 | o [two]
46 | | * needs merge with one
47 | | * needs update of diff base to tip of one
48 | @ [one]
49 | |
50 | o default
51 |
52 | $ hg pmerge
53 | $ hg pmerge two
54 | two: merging from one
55 | marked working directory as branch two
56 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
57 |
58 | $ cd ..
59 |
60 |
61 | h2. Editing Messages
62 |
63 | h3. Edit Non-Current Message
64 |
65 | $ hg init peditmsg
66 | $ cd peditmsg
67 |
68 | $ hg pnew one
69 | marked working directory as branch one
70 | $ hg pnew two
71 | marked working directory as branch two
72 |
73 | $ hg peditmessage two -t "zwei"
74 | $ hg peditmessage one -t "eins"
75 | created new head
76 |
77 | $ hg glog
78 | o 3 one: update patch description - john
79 | |
80 | | @ 2 two: update patch description - john
81 | | |
82 | | o 1 two: start new patch on one - john
83 | |/
84 | o 0 one: start new patch on default - john
85 |
86 | $ hg pgraph -m
87 | @ zwei
88 | |
89 | o eins
90 | |
91 | o default
92 |
93 |
94 | h3. Edit Already Modified Message
95 |
96 | See "Issue 31":http://bitbucket.org/parren/hg-pbranch/issue/31/.
97 |
98 | $ echo More >>.hgpatchinfo/two.desc
99 | $ cat .hgpatchinfo/two.desc
100 | zweiMore
101 |
102 | $ hg peditmessage # editor is set to "cat"
103 | zweiMore
104 |
105 | $ hg pmessage
106 | zweiMore
107 |
108 | $ cd ..
109 |
110 |
111 | h3. Use Custom Commit Message
112 |
113 | $ hg init custommsg
114 | $ cd custommsg
115 |
116 | $ hg pnew one
117 | marked working directory as branch one
118 |
119 | $ hg peditmessage -t "eins" -m "updated desc"
120 |
121 | $ hg log
122 | 1 one: updated desc - john
123 | 0 one: start new patch on default - john
124 |
125 | $ cd ..
126 |
127 |
128 |
--------------------------------------------------------------------------------
/vim/vim.symlink/colors/BusyBee.vim:
--------------------------------------------------------------------------------
1 | " Maintainer: Patrick J. Anderson
2 | " Version: 1.0.1
3 | " Last Change: February 23, 2009
4 | " Credits: This is a modification of Mustang.vim color scheme
5 |
6 | set background=dark
7 |
8 | hi clear
9 |
10 | if exists("syntax_on")
11 | syntax reset
12 | endif
13 |
14 | let colors_name = "busybee"
15 |
16 | " Vim >= 7.0 specific colors
17 | if version >= 700
18 | hi CursorLine guibg=#202020 ctermbg=234
19 | hi CursorColumn guibg=#202020 ctermbg=234
20 | hi MatchParen guifg=#d0ffc0 guibg=#202020 gui=bold ctermfg=157 ctermbg=237 cterm=bold
21 | hi Pmenu guifg=#ffffff guibg=#202020 ctermfg=255 ctermbg=238
22 | hi PmenuSel guifg=#000000 guibg=#b1d631 ctermfg=0 ctermbg=148
23 | endif
24 |
25 | " General colors
26 | hi Cursor guifg=NONE guibg=#626262 gui=none ctermbg=241
27 | hi Normal guifg=#e2e2e5 guibg=#202020 gui=none ctermfg=253 ctermbg=234
28 | hi NonText guifg=#808080 guibg=#202020 gui=none ctermfg=244 ctermbg=235
29 | hi LineNr guifg=#303030 guibg=#202020 gui=none ctermfg=244 ctermbg=232
30 | hi StatusLine guifg=#d3d3d5 guibg=#303030 gui=none ctermfg=253 ctermbg=238
31 | hi StatusLineNC guifg=#939395 guibg=#303030 gui=none ctermfg=246 ctermbg=238
32 | hi VertSplit guifg=#444444 guibg=#303030 gui=none ctermfg=238 ctermbg=238
33 | hi Folded guibg=#384048 guifg=#a0a8b0 gui=none ctermbg=4 ctermfg=248
34 | hi Title guifg=#f6f3e8 guibg=NONE gui=bold ctermfg=254 cterm=bold
35 | hi Visual guifg=#faf4c6 guibg=#3c414c gui=none ctermfg=254 ctermbg=4
36 | hi SpecialKey guifg=#808080 guibg=#343434 gui=none ctermfg=244 ctermbg=236
37 |
38 | " Syntax highlighting
39 | hi Comment guifg=#3f3f3f gui=italic ctermfg=244
40 | hi Todo guifg=#8f8f8f gui=none ctermfg=245
41 | hi Boolean guifg=#b1d631 gui=none ctermfg=148
42 | hi String guifg=#606060 gui=none ctermfg=148
43 | hi Identifier guifg=#b1d631 gui=none ctermfg=148
44 | hi Function guifg=#ffff00 gui=none ctermfg=255
45 | hi Type guifg=#7e8aa2 gui=none ctermfg=103
46 | hi Statement guifg=#7e8aa2 gui=none ctermfg=103
47 | hi Keyword guifg=#ff9800 gui=none ctermfg=208
48 | hi Constant guifg=#ff9800 gui=none ctermfg=208
49 | hi Number guifg=#ff9800 gui=none ctermfg=208
50 | hi Special guifg=#ff9800 gui=none ctermfg=208
51 | hi PreProc guifg=#faf4c6 gui=none ctermfg=230
52 | hi Todo guifg=#ff9f00 guibg=#202020 gui=none
53 |
54 | " Code-specific colors
55 | hi pythonImport guifg=#009000 gui=none ctermfg=255
56 | hi pythonException guifg=#f00000 gui=none ctermfg=200
57 | hi pythonOperator guifg=#7e8aa2 gui=none ctermfg=103
58 | hi pythonBuiltinFunction guifg=#009000 gui=none ctermfg=200
59 | hi pythonExClass guifg=#009000 gui=none ctermfg=200
60 |
61 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/tests/test_update.py:
--------------------------------------------------------------------------------
1 | '''Test output of {update}.'''
2 |
3 | from nose import *
4 | from util import *
5 |
6 |
7 | @with_setup(setup_sandbox, teardown_sandbox)
8 | def test_empty_repo():
9 | output = prompt(fs='{update}')
10 | assert output == ''
11 |
12 | output = prompt(fs='{ need to update? {update}}')
13 | assert output == ''
14 |
15 |
16 | @with_setup(setup_sandbox, teardown_sandbox)
17 | def test_single_branch():
18 | hg_commit()
19 |
20 | output = prompt(fs='{update}')
21 | assert output == ''
22 |
23 | output = prompt(fs='{ need to update? {update}}')
24 | assert output == ''
25 |
26 | hg_commit()
27 |
28 | output = prompt(fs='{update}')
29 | assert output == ''
30 |
31 | output = prompt(fs='{ need to update? {update}}')
32 | assert output == ''
33 |
34 | hg_update(0)
35 |
36 | output = prompt(fs='{update}')
37 | assert output == '^'
38 |
39 | output = prompt(fs='{ need to update? {update}}')
40 | assert output == ' need to update? ^'
41 |
42 |
43 | @with_setup(setup_sandbox, teardown_sandbox)
44 | def test_multiple_branches():
45 | hg_commit()
46 | hg_commit()
47 | hg_commit()
48 |
49 | hg_update(0)
50 | hg_commit('two.txt')
51 | hg_commit('two.txt')
52 |
53 | # @ 4
54 | # |
55 | # o 3
56 | # |
57 | # | o 2
58 | # | |
59 | # | o 1
60 | # |/
61 | # |
62 | # o 0
63 |
64 | hg_log()
65 |
66 | hg_update(4)
67 | output = prompt(fs='{update}')
68 | assert output == ''
69 |
70 | hg_update(3)
71 | output = prompt(fs='{update}')
72 | assert output == '^'
73 |
74 | # This test case matches the behavior of Mercurial, but it seems a bit
75 | # unintuitive to me.
76 | hg_update(2)
77 | output = prompt(fs='{update}')
78 | assert output == '^'
79 |
80 | hg_update(1)
81 | output = prompt(fs='{update}')
82 | assert output == '^'
83 |
84 | hg_update(0)
85 | output = prompt(fs='{update}')
86 | assert output == '^'
87 |
88 |
89 | @with_setup(setup_sandbox, teardown_sandbox)
90 | def test_multiple_named_branches():
91 | hg_commit()
92 | hg_commit()
93 | hg_commit()
94 |
95 | hg_update(0)
96 | hg_branch('test')
97 | hg_commit('two.txt')
98 | hg_commit('two.txt')
99 |
100 | # @ 4 (test)
101 | # |
102 | # o 3 (test)
103 | # |
104 | # | o 2 (default)
105 | # | |
106 | # | o 1 (default)
107 | # |/
108 | # |
109 | # o 0 (default)
110 |
111 | hg_log()
112 |
113 | hg_update(4)
114 | output = prompt(fs='{update}')
115 | assert output == ''
116 |
117 | hg_update(3)
118 | output = prompt(fs='{update}')
119 | assert output == '^'
120 |
121 | hg_update(2)
122 | output = prompt(fs='{update}')
123 | assert output == ''
124 |
125 | hg_update(1)
126 | output = prompt(fs='{update}')
127 | assert output == '^'
128 |
129 | hg_update(0)
130 | output = prompt(fs='{update}')
131 | assert output == '^'
132 |
133 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/docs/static/media/css/pygments.css:
--------------------------------------------------------------------------------
1 | .hll { background-color: #ffffcc }
2 | .c { color: #808080 } /* Comment */
3 | .err { color: #F00000; background-color: #F0A0A0 } /* Error */
4 | .k { color: #008000; font-weight: bold } /* Keyword */
5 | .o { color: #303030 } /* Operator */
6 | .cm { color: #808080 } /* Comment.Multiline */
7 | .cp { color: #507090 } /* Comment.Preproc */
8 | .c1 { color: #808080 } /* Comment.Single */
9 | .cs { color: #cc0000; font-weight: bold } /* Comment.Special */
10 | .gd { color: #A00000 } /* Generic.Deleted */
11 | .ge { font-style: italic } /* Generic.Emph */
12 | .gr { color: #FF0000 } /* Generic.Error */
13 | .gh { color: #000080; font-weight: bold } /* Generic.Heading */
14 | .gi { color: #00A000 } /* Generic.Inserted */
15 | .go { color: #808080 } /* Generic.Output */
16 | .gp { color: #c65d09; font-weight: bold } /* Generic.Prompt */
17 | .gs { font-weight: bold } /* Generic.Strong */
18 | .gu { color: #800080; font-weight: bold } /* Generic.Subheading */
19 | .gt { color: #0040D0 } /* Generic.Traceback */
20 | .kc { color: #008000; font-weight: bold } /* Keyword.Constant */
21 | .kd { color: #008000; font-weight: bold } /* Keyword.Declaration */
22 | .kn { color: #008000; font-weight: bold } /* Keyword.Namespace */
23 | .kp { color: #003080; font-weight: bold } /* Keyword.Pseudo */
24 | .kr { color: #008000; font-weight: bold } /* Keyword.Reserved */
25 | .kt { color: #303090; font-weight: bold } /* Keyword.Type */
26 | .m { color: #6000E0; font-weight: bold } /* Literal.Number */
27 | .s { background-color: #fff0f0 } /* Literal.String */
28 | .na { color: #0000C0 } /* Name.Attribute */
29 | .nb { color: #007020 } /* Name.Builtin */
30 | .nc { color: #B00060; font-weight: bold } /* Name.Class */
31 | .no { color: #003060; font-weight: bold } /* Name.Constant */
32 | .nd { color: #505050; font-weight: bold } /* Name.Decorator */
33 | .ni { color: #800000; font-weight: bold } /* Name.Entity */
34 | .ne { color: #F00000; font-weight: bold } /* Name.Exception */
35 | .nf { color: #0060B0; font-weight: bold } /* Name.Function */
36 | .nl { color: #907000; font-weight: bold } /* Name.Label */
37 | .nn { color: #0e84b5; font-weight: bold } /* Name.Namespace */
38 | .nt { color: #007000 } /* Name.Tag */
39 | .nv { color: #906030 } /* Name.Variable */
40 | .ow { color: #000000; font-weight: bold } /* Operator.Word */
41 | .w { color: #bbbbbb } /* Text.Whitespace */
42 | .mf { color: #6000E0; font-weight: bold } /* Literal.Number.Float */
43 | .mh { color: #005080; font-weight: bold } /* Literal.Number.Hex */
44 | .mi { color: #0000D0; font-weight: bold } /* Literal.Number.Integer */
45 | .mo { color: #4000E0; font-weight: bold } /* Literal.Number.Oct */
46 | .sb { background-color: #fff0f0 } /* Literal.String.Backtick */
47 | .sc { color: #0040D0 } /* Literal.String.Char */
48 | .sd { color: #D04020 } /* Literal.String.Doc */
49 | .s2 { background-color: #fff0f0 } /* Literal.String.Double */
50 | .se { color: #606060; font-weight: bold; background-color: #fff0f0 } /* Literal.String.Escape */
51 | .sh { background-color: #fff0f0 } /* Literal.String.Heredoc */
52 | .si { background-color: #e0e0e0 } /* Literal.String.Interpol */
53 | .sx { color: #D02000; background-color: #fff0f0 } /* Literal.String.Other */
54 | .sr { color: #000000; background-color: #fff0ff } /* Literal.String.Regex */
55 | .s1 { background-color: #fff0f0 } /* Literal.String.Single */
56 | .ss { color: #A06000 } /* Literal.String.Symbol */
57 | .bp { color: #007020 } /* Name.Builtin.Pseudo */
58 | .vc { color: #306090 } /* Name.Variable.Class */
59 | .vg { color: #d07000; font-weight: bold } /* Name.Variable.Global */
60 | .vi { color: #3030B0 } /* Name.Variable.Instance */
61 | .il { color: #0000D0; font-weight: bold } /* Literal.Number.Integer.Long */
62 |
--------------------------------------------------------------------------------
/vim/vim.symlink/colors/darkZ.vim:
--------------------------------------------------------------------------------
1 | " darkZ 1.1 (Vim color file)
2 | " Create by ☆andy☆
3 | " QQ24375048
4 |
5 | if version > 580
6 | hi clear
7 | if exists("syntax_on")
8 | syntax reset
9 | endif
10 | endif
11 |
12 | set cursorline
13 | let g:colors_name="darkZ"
14 |
15 | hi Normal guifg=#DFD6C1 guibg=gray16 gui=none
16 |
17 | hi Cursor guifg=black guibg=yellow gui=none
18 | hi ErrorMsg guifg=white guibg=red gui=none
19 | hi VertSplit guifg=gray40 guibg=gray40 gui=none
20 | hi Folded guifg=DarkSlateGray3 guibg=grey30 gui=none
21 | hi FoldColumn guifg=tan guibg=grey30 gui=none
22 | hi IncSearch guifg=#b0ffff guibg=#2050d0
23 | hi LineNr guifg=gray40 gui=none
24 | hi ModeMsg guifg=SkyBlue gui=none
25 | hi MoreMsg guifg=SeaGreen gui=none
26 | hi NonText guifg=cyan gui=none
27 | hi Question guifg=springgreen gui=none
28 | hi Search guifg=white guibg=#445599 gui=bold
29 | hi SpecialKey guifg=cyan gui=none
30 | hi StatusLine guifg=black guibg=Pink gui=bold
31 | hi StatusLineNC guifg=grey guibg=gray40 gui=none
32 | hi Title guifg=#ff4400 gui=none gui=bold
33 | hi Visual guifg=gray17 guibg=tan1 gui=none
34 | hi WarningMsg guifg=salmon gui=none
35 | hi Pmenu guifg=white guibg=#445599 gui=none
36 | hi PmenuSel guifg=#445599 guibg=gray
37 | hi WildMenu guifg=gray guibg=gray17 gui=none
38 | hi MatchParen guifg=black guibg=orange2 gui=bold
39 | hi DiffAdd guifg=black guibg=wheat1
40 | hi DiffChange guifg=black guibg=skyblue1
41 | hi DiffText guifg=black guibg=hotpink1 gui=none
42 | hi DiffDelete guibg=gray45 guifg=black gui=none
43 | hi CursorLine guibg=gray24
44 | hi CursorColumn guibg=gray24
45 |
46 | hi Comment guifg=gray55 gui=italic
47 | hi Constant guifg=#FF77FF gui=none
48 | hi Identifier guifg=#6FDEF8 gui=none
49 | hi Function guifg=#82EF2A gui=none
50 | hi Statement guifg=#FCFC63 gui=none
51 | hi PreProc guifg=#82EF2A gui=none
52 | hi Type guifg=#33AFF3 gui=none
53 | hi Special guifg=orange gui=none
54 | hi Ignore guifg=red gui=none
55 | hi Todo guifg=red guibg=yellow2 gui=none
56 |
57 | hi SpecialKey ctermfg=red
58 | hi NonText cterm=bold ctermfg=darkblue
59 | hi Directory ctermfg=darkcyan
60 | hi ErrorMsg cterm=bold ctermfg=7 ctermbg=1
61 | hi IncSearch cterm=NONE ctermfg=yellow ctermbg=green
62 | hi Search cterm=NONE ctermfg=white ctermbg=grey
63 | hi MoreMsg ctermfg=darkgreen
64 | hi ModeMsg cterm=NONE ctermfg=brown
65 | hi LineNr ctermfg=3
66 | hi Question ctermfg=green
67 | hi StatusLine cterm=bold,reverse
68 | hi StatusLineNC cterm=reverse
69 | hi VertSplit cterm=reverse
70 | hi Title ctermfg=5
71 | hi Visual cterm=reverse
72 | hi VisualNOS cterm=bold,underline
73 | hi WarningMsg ctermfg=1
74 | hi WildMenu ctermfg=0 ctermbg=3
75 | hi Folded ctermfg=darkgrey ctermbg=NONE
76 | hi FoldColumn ctermfg=darkgrey ctermbg=NONE
77 | hi DiffAdd ctermbg=4
78 | hi DiffChange ctermbg=5
79 | hi DiffDelete cterm=bold ctermfg=4 ctermbg=6
80 | hi DiffText cterm=bold ctermbg=1
81 |
82 | hi Comment ctermfg=darkcyan
83 | hi Constant ctermfg=brown
84 | hi Special ctermfg=5
85 | hi Identifier ctermfg=6
86 | hi Statement ctermfg=3
87 | hi PreProc ctermfg=5
88 | hi Type ctermfg=2
89 | hi Underlined cterm=underline ctermfg=5
90 | hi Ignore ctermfg=darkgrey
91 | hi Error cterm=bold ctermfg=7 ctermbg=1
92 |
93 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/docs/static/media/css/layout.css:
--------------------------------------------------------------------------------
1 | /* @override http://localhost:8008/media/css/layout.css */
2 | body, html {
3 | background-color: #226F89;
4 | margin: 0;
5 | padding: 0;
6 | }
7 |
8 | div#breadcrumbs {
9 | border-bottom: 4px dashed #265565;
10 | border-right: 1px solid #265565;
11 | padding: 0em 1.5em;
12 | background-color: #fff;
13 | width: 55em;
14 | margin: 0em 0em 0em -1.5em;
15 | }
16 | div#breadcrumbs p {
17 | margin: 0.5em auto;
18 | }
19 | div#content {
20 | background-color: #fff;
21 | height: 100%;
22 | margin: 0 auto 3em;
23 | overflow: hidden;
24 | padding: 0em 1.5em 0em 1.5em;
25 | width: 55em;
26 | border-left: 1px solid #265565;
27 | border-right: 1px solid #265565;
28 | }
29 |
30 | h1 {
31 | margin: 0.3em 0;
32 | padding: 0.1em 0;
33 | }
34 | h2, h3, h4, h5, h6 {
35 | margin-top: 1em;
36 | margin-bottom: 0.4em;
37 | }
38 | p, ul, blockquote {
39 | line-height: 1.8em;
40 | margin-top: 0;
41 | margin-bottom: 1em;
42 | }
43 | a {
44 | color: #133C4C;
45 | }
46 | a:hover {
47 | color: #F14800;
48 | }
49 |
50 | p#footer {
51 | background-color: #fff;
52 | border-top: 4px dashed #265565;
53 | width: 55em;
54 | padding: 0.75em 1.5em;
55 | text-align: center;
56 | color: #666;
57 | margin-left: -1.5em;
58 | margin-bottom: 0em;
59 | }
60 |
61 | ul {
62 | padding-left: 1.5em;
63 | }
64 | ul li {
65 | list-style-type: disc;
66 | margin-left: 1.5em;
67 | margin-top: 0.4em;
68 | }
69 |
70 | div.toc ul {
71 | padding: 0;
72 | }
73 | div.toc ul li {
74 | list-style-type: none;
75 | margin: 0;
76 | }
77 | div.toc > ul > li {
78 | list-style-type: none;
79 | margin: 0;
80 | }
81 | div.toc > ul ul {
82 | margin: 0 3em;
83 | }
84 |
85 | code {
86 | background-color: #f6f6f6;
87 | border: 1px solid #999;
88 | padding: 2px;
89 | white-space: nowrap;
90 | }
91 | pre code {
92 | border: none;
93 | padding: 0;
94 | background: none;
95 | white-space: pre-wrap;
96 | }
97 | a code {
98 | background: none;
99 | border: none;
100 | margin: 0;
101 | padding: 0;
102 | text-decoration: inherit;
103 | }
104 | a.code {
105 | background-color: #3f3f3f;
106 | }
107 |
108 | dt {
109 | font-weight: bold;
110 | margin-top: 1em;
111 | }
112 | dd {
113 | line-height: 1.8em;
114 | margin-left: 1.5em;
115 | }
116 | blockquote p {
117 | margin: 0;
118 | }
119 |
120 | img {
121 | background-color: #f6f6f6;
122 | border: 1px solid #999;
123 | padding: 1em;
124 | display: block;
125 | margin: 0 auto;
126 | }
127 |
128 | table {
129 | margin: 1em;
130 | }
131 | table thead {
132 | background-color: #f6f6f6;
133 | }
134 | table thead th {
135 | border: 1px solid #999;
136 | padding: 0.5em 1em;
137 | }
138 | table tbody tr td {
139 | border: 1px solid #999;
140 | padding: 0.5em 1em;
141 | }
142 |
143 | pre, blockquote, table.codehilitetable {
144 | background-color: #f6f6f6;
145 | border: 1px solid #999;
146 | display: block;
147 | line-height: 1.5em;
148 | margin-left: 1.5em;
149 | margin-right: 1.5em;
150 | padding: 0.5em;
151 | padding-left: 1em;
152 | }
153 | pre, table.codehilitetable {
154 | margin-bottom: 1em;
155 | }
156 | table.codehilitetable div.linenodiv {
157 | border-right: 1px solid #ccc;
158 | margin-right: 1em;
159 | padding-right: 1em;
160 | }
161 | table.codehilitetable pre {
162 | background: none;
163 | border: none;
164 | margin: 0;
165 | padding: 0;
166 | }
167 |
168 | table#pages tr, table#subdirs tr, table#files tr {
169 | border-top: 1px solid #999;
170 | border-bottom: 1px solid #999;
171 | }
172 | table tr td.name a {
173 | display: block;
174 | padding: 0.5em 1em;
175 | }
176 | table tr td.name a:hover {
177 | background-color: #f6f6f6;
178 | }
179 | table tr td.size {
180 | padding: 0.5em 1em;
181 | width: 40px;
182 | }
183 |
--------------------------------------------------------------------------------
/script/bootstrap:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env bash
2 | #
3 | # bootstrap installs things.
4 |
5 | cd "$(dirname "$0")/.."
6 | DOTFILES_ROOT=$(pwd -P)
7 |
8 | set -e
9 |
10 | echo ''
11 |
12 | info () {
13 | printf "\r [ \033[00;34m..\033[0m ] $1\n"
14 | }
15 |
16 | user () {
17 | printf "\r [ \033[0;33m??\033[0m ] $1\n"
18 | }
19 |
20 | success () {
21 | printf "\r\033[2K [ \033[00;32mOK\033[0m ] $1\n"
22 | }
23 |
24 | fail () {
25 | printf "\r\033[2K [\033[0;31mFAIL\033[0m] $1\n"
26 | echo ''
27 | exit
28 | }
29 |
30 | setup_gitconfig () {
31 | if ! [ -f git/gitconfig.local.symlink ]
32 | then
33 | info 'setup gitconfig'
34 |
35 | git_credential='cache'
36 | if [ "$(uname -s)" == "Darwin" ]
37 | then
38 | git_credential='osxkeychain'
39 | fi
40 |
41 | user ' - What is your github author name?'
42 | read -e git_authorname
43 | user ' - What is your github author email?'
44 | read -e git_authoremail
45 |
46 | sed -e "s/AUTHORNAME/$git_authorname/g" -e "s/AUTHOREMAIL/$git_authoremail/g" -e "s/GIT_CREDENTIAL_HELPER/$git_credential/g" git/gitconfig.local.symlink.example > git/gitconfig.local.symlink
47 |
48 | success 'gitconfig'
49 | fi
50 | }
51 |
52 |
53 | link_file () {
54 | local src=$1 dst=$2
55 |
56 | local overwrite= backup= skip=
57 | local action=
58 |
59 | if [ -f "$dst" -o -d "$dst" -o -L "$dst" ]
60 | then
61 |
62 | if [ "$overwrite_all" == "false" ] && [ "$backup_all" == "false" ] && [ "$skip_all" == "false" ]
63 | then
64 |
65 | local currentSrc="$(readlink $dst)"
66 |
67 | if [ "$currentSrc" == "$src" ]
68 | then
69 |
70 | skip=true;
71 |
72 | else
73 |
74 | user "File already exists: $dst ($(basename "$src")), what do you want to do?\n\
75 | [s]kip, [S]kip all, [o]verwrite, [O]verwrite all, [b]ackup, [B]ackup all?"
76 | read -n 1 action
77 |
78 | case "$action" in
79 | o )
80 | overwrite=true;;
81 | O )
82 | overwrite_all=true;;
83 | b )
84 | backup=true;;
85 | B )
86 | backup_all=true;;
87 | s )
88 | skip=true;;
89 | S )
90 | skip_all=true;;
91 | * )
92 | ;;
93 | esac
94 |
95 | fi
96 |
97 | fi
98 |
99 | overwrite=${overwrite:-$overwrite_all}
100 | backup=${backup:-$backup_all}
101 | skip=${skip:-$skip_all}
102 |
103 | if [ "$overwrite" == "true" ]
104 | then
105 | rm -rf "$dst"
106 | success "removed $dst"
107 | fi
108 |
109 | if [ "$backup" == "true" ]
110 | then
111 | mv "$dst" "${dst}.backup"
112 | success "moved $dst to ${dst}.backup"
113 | fi
114 |
115 | if [ "$skip" == "true" ]
116 | then
117 | success "skipped $src"
118 | fi
119 | fi
120 |
121 | if [ "$skip" != "true" ] # "false" or empty
122 | then
123 | ln -s "$1" "$2"
124 | success "linked $1 to $2"
125 | fi
126 | }
127 |
128 | install_dotfiles () {
129 | info 'installing dotfiles'
130 |
131 | local overwrite_all=false backup_all=false skip_all=false
132 |
133 | for src in $(find -H "$DOTFILES_ROOT" -maxdepth 2 -name '*.symlink' -not -path '*.git*')
134 | do
135 | dst="$HOME/.$(basename "${src%.*}")"
136 | link_file "$src" "$dst"
137 | done
138 | }
139 |
140 | setup_gitconfig
141 | install_dotfiles
142 |
143 | # If we're on a Mac, let's install and setup homebrew.
144 | if [ "$(uname -s)" == "Darwin" ]
145 | then
146 | info "installing dependencies"
147 | if source bin/dot > /tmp/dotfiles-dot 2>&1
148 | then
149 | success "dependencies installed"
150 | else
151 | fail "error installing dependencies"
152 | fi
153 | fi
154 |
155 | echo ''
156 | echo ' All installed!'
157 |
--------------------------------------------------------------------------------
/vim/vim.symlink/colors/wombat256mod.vim:
--------------------------------------------------------------------------------
1 | " Vim color file
2 | " Original Maintainer: Lars H. Nielsen (dengmao@gmail.com)
3 | " Last Change: 2010-07-23
4 | "
5 | " Modified version of wombat for 256-color terminals by
6 | " David Liang (bmdavll@gmail.com)
7 | " based on version by
8 | " Danila Bespalov (danila.bespalov@gmail.com)
9 |
10 | set background=dark
11 |
12 | if version > 580
13 | hi clear
14 | if exists("syntax_on")
15 | syntax reset
16 | endif
17 | endif
18 |
19 | let colors_name = "wombat256mod"
20 |
21 |
22 | " General colors
23 | hi Normal ctermfg=252 ctermbg=234 cterm=none guifg=#e3e0d7 guibg=#242424 gui=none
24 | hi Cursor ctermfg=234 ctermbg=228 cterm=none guifg=#242424 guibg=#eae788 gui=none
25 | hi Visual ctermfg=251 ctermbg=239 cterm=none guifg=#c3c6ca guibg=#554d4b gui=none
26 | hi VisualNOS ctermfg=251 ctermbg=236 cterm=none guifg=#c3c6ca guibg=#303030 gui=none
27 | hi Search ctermfg=177 ctermbg=241 cterm=none guifg=#d787ff guibg=#636066 gui=none
28 | hi Folded ctermfg=103 ctermbg=237 cterm=none guifg=#a0a8b0 guibg=#3a4046 gui=none
29 | hi Title ctermfg=230 cterm=bold guifg=#ffffd7 gui=bold
30 | hi StatusLine ctermfg=230 ctermbg=238 cterm=none guifg=#ffffd7 guibg=#444444 gui=italic
31 | hi VertSplit ctermfg=238 ctermbg=238 cterm=none guifg=#444444 guibg=#444444 gui=none
32 | hi StatusLineNC ctermfg=241 ctermbg=238 cterm=none guifg=#857b6f guibg=#444444 gui=none
33 | hi LineNr ctermfg=241 ctermbg=232 cterm=none guifg=#857b6f guibg=#080808 gui=none
34 | hi SpecialKey ctermfg=241 ctermbg=235 cterm=none guifg=#626262 guibg=#2b2b2b gui=none
35 | hi WarningMsg ctermfg=203 guifg=#ff5f55
36 | hi ErrorMsg ctermfg=196 ctermbg=236 cterm=bold guifg=#ff2026 guibg=#3a3a3a gui=bold
37 |
38 | " Vim >= 7.0 specific colors
39 | if version >= 700
40 | hi CursorLineY ctermbg=236 cterm=none guibg=#32322f
41 | hi MatchParen ctermfg=228 ctermbg=101 cterm=bold guifg=#eae788 guibg=#857b6f gui=bold
42 | hi Pmenu ctermfg=230 ctermbg=238 guifg=#ffffd7 guibg=#444444
43 | hi PmenuSel ctermfg=232 ctermbg=192 guifg=#080808 guibg=#cae982
44 | endif
45 |
46 | " Vim >= 7.3 features
47 | if version >= 703
48 | hi ColorColumn ctermfg=230 ctermbg=238 cterm=none guifg=#ffffd7 guibg=#444444 gui=italic
49 | end
50 |
51 | " Diff highlighting
52 | hi DiffAdd ctermbg=17 guibg=#2a0d6a
53 | hi DiffDelete ctermfg=234 ctermbg=60 cterm=none guifg=#242424 guibg=#3e3969 gui=none
54 | hi DiffText ctermbg=53 cterm=none guibg=#73186e gui=none
55 | hi DiffChange ctermbg=237 guibg=#382a37
56 |
57 | "hi CursorIM
58 | "hi Directory
59 | "hi IncSearch
60 | "hi Menu
61 | "hi ModeMsg
62 | "hi MoreMsg
63 | "hi PmenuSbar
64 | "hi PmenuThumb
65 | "hi Question
66 | "hi Scrollbar
67 | "hi SignColumn
68 | "hi SpellBad
69 | "hi SpellCap
70 | "hi SpellLocal
71 | "hi SpellRare
72 | "hi TabLine
73 | "hi TabLineFill
74 | "hi TabLineSel
75 | "hi Tooltip
76 | "hi User1
77 | "hi User9
78 | "hi WildMenu
79 |
80 |
81 | " Syntax highlighting
82 | hi Keyword ctermfg=111 cterm=none guifg=#88b8f6 gui=none
83 | hi Statement ctermfg=111 cterm=none guifg=#88b8f6 gui=none
84 | hi Constant ctermfg=173 cterm=none guifg=#e5786d gui=none
85 | hi Number ctermfg=173 cterm=none guifg=#e5786d gui=none
86 | hi PreProc ctermfg=173 cterm=none guifg=#e5786d gui=none
87 | hi Function ctermfg=192 cterm=none guifg=#cae982 gui=none
88 | hi Identifier ctermfg=192 cterm=none guifg=#cae982 gui=none
89 | hi Type ctermfg=186 cterm=none guifg=#d4d987 gui=none
90 | hi Special ctermfg=229 cterm=none guifg=#eadead gui=none
91 | hi String ctermfg=113 cterm=none guifg=#95e454 gui=italic
92 | hi Comment ctermfg=246 cterm=none guifg=#9c998e gui=italic
93 | hi Todo ctermfg=101 cterm=none guifg=#857b6f gui=italic
94 |
95 |
96 | " Links
97 | hi! link FoldColumn Folded
98 | hi! link CursorColumn CursorLine
99 | hi! link NonText LineNr
100 |
101 | " vim:set ts=4 sw=4 noet:
102 |
--------------------------------------------------------------------------------
/vim/vim.symlink/.VimballRecord:
--------------------------------------------------------------------------------
1 | markdown-1.1.0.vba: call delete('/Users/zach/.vim/ftdetect/markdown.vim')|call delete('/Users/zach/.vim/snippets/markdown.snippets')|call delete('/Users/zach/.vim/syntax/markdown.vim')
2 | command-t-0.8.vba: call delete('/Users/zach/.vim/ruby/command-t/controller.rb')|call delete('/Users/zach/.vim/ruby/command-t/extconf.rb')|call delete('/Users/zach/.vim/ruby/command-t/finder.rb')|call delete('/Users/zach/.vim/ruby/command-t/match_window.rb')|call delete('/Users/zach/.vim/ruby/command-t/prompt.rb')|call delete('/Users/zach/.vim/ruby/command-t/scanner.rb')|call delete('/Users/zach/.vim/ruby/command-t/settings.rb')|call delete('/Users/zach/.vim/ruby/command-t/stub.rb')|call delete('/Users/zach/.vim/ruby/command-t/vim/screen.rb')|call delete('/Users/zach/.vim/ruby/command-t/vim/window.rb')|call delete('/Users/zach/.vim/ruby/command-t/vim.rb')|call delete('/Users/zach/.vim/ruby/command-t/ext.c')|call delete('/Users/zach/.vim/ruby/command-t/match.c')|call delete('/Users/zach/.vim/ruby/command-t/matcher.c')|call delete('/Users/zach/.vim/ruby/command-t/ext.h')|call delete('/Users/zach/.vim/ruby/command-t/match.h')|call delete('/Users/zach/.vim/ruby/command-t/matcher.h')|call delete('/Users/zach/.vim/ruby/command-t/ruby_compat.h')|call delete('/Users/zach/.vim/ruby/command-t/depend')|call delete('/Users/zach/.vim/doc/command-t.txt')|call delete('/Users/zach/.vim/plugin/command-t.vim')
3 | command-t-1.0b.vba: call delete('/Users/pao/.vim/ruby/command-t/controller.rb')|call delete('/Users/pao/.vim/ruby/command-t/extconf.rb')|call delete('/Users/pao/.vim/ruby/command-t/finder.rb')|call delete('/Users/pao/.vim/ruby/command-t/match_window.rb')|call delete('/Users/pao/.vim/ruby/command-t/prompt.rb')|call delete('/Users/pao/.vim/ruby/command-t/scanner.rb')|call delete('/Users/pao/.vim/ruby/command-t/settings.rb')|call delete('/Users/pao/.vim/ruby/command-t/stub.rb')|call delete('/Users/pao/.vim/ruby/command-t/vim/screen.rb')|call delete('/Users/pao/.vim/ruby/command-t/vim/window.rb')|call delete('/Users/pao/.vim/ruby/command-t/vim.rb')|call delete('/Users/pao/.vim/ruby/command-t/ext.c')|call delete('/Users/pao/.vim/ruby/command-t/match.c')|call delete('/Users/pao/.vim/ruby/command-t/matcher.c')|call delete('/Users/pao/.vim/ruby/command-t/ext.h')|call delete('/Users/pao/.vim/ruby/command-t/match.h')|call delete('/Users/pao/.vim/ruby/command-t/matcher.h')|call delete('/Users/pao/.vim/ruby/command-t/ruby_compat.h')|call delete('/Users/pao/.vim/ruby/command-t/depend')|call delete('/Users/pao/.vim/doc/command-t.txt')|call delete('/Users/pao/.vim/plugin/command-t.vim')
4 | command-t-1.2.1.vba: call delete('/Users/pao/.vim/ruby/command-t/controller.rb')|call delete('/Users/pao/.vim/ruby/command-t/extconf.rb')|call delete('/Users/pao/.vim/ruby/command-t/finder/buffer_finder.rb')|call delete('/Users/pao/.vim/ruby/command-t/finder/file_finder.rb')|call delete('/Users/pao/.vim/ruby/command-t/finder.rb')|call delete('/Users/pao/.vim/ruby/command-t/match_window.rb')|call delete('/Users/pao/.vim/ruby/command-t/prompt.rb')|call delete('/Users/pao/.vim/ruby/command-t/scanner/buffer_scanner.rb')|call delete('/Users/pao/.vim/ruby/command-t/scanner/file_scanner.rb')|call delete('/Users/pao/.vim/ruby/command-t/scanner.rb')|call delete('/Users/pao/.vim/ruby/command-t/settings.rb')|call delete('/Users/pao/.vim/ruby/command-t/stub.rb')|call delete('/Users/pao/.vim/ruby/command-t/vim/path_utilities.rb')|call delete('/Users/pao/.vim/ruby/command-t/vim/screen.rb')|call delete('/Users/pao/.vim/ruby/command-t/vim/window.rb')|call delete('/Users/pao/.vim/ruby/command-t/vim.rb')|call delete('/Users/pao/.vim/ruby/command-t/ext.c')|call delete('/Users/pao/.vim/ruby/command-t/match.c')|call delete('/Users/pao/.vim/ruby/command-t/matcher.c')|call delete('/Users/pao/.vim/ruby/command-t/ext.h')|call delete('/Users/pao/.vim/ruby/command-t/match.h')|call delete('/Users/pao/.vim/ruby/command-t/matcher.h')|call delete('/Users/pao/.vim/ruby/command-t/ruby_compat.h')|call delete('/Users/pao/.vim/ruby/command-t/depend')|call delete('/Users/pao/.vim/doc/command-t.txt')|call delete('/Users/pao/.vim/plugin/command-t.vim')
5 |
--------------------------------------------------------------------------------
/vim/vim.symlink/colors/desertEx.vim:
--------------------------------------------------------------------------------
1 | " Vim color file
2 | " Maintainer: Mingbai
3 | " Last Change: 2006-12-24 20:09:09
4 |
5 | set background=dark
6 | if version > 580
7 | " no guarantees for version 5.8 and below, but this makes it stop
8 | " complaining
9 | hi clear
10 | if exists("syntax_on")
11 | syntax reset
12 | endif
13 | endif
14 | let g:colors_name="desertEx"
15 |
16 | hi Normal guifg=gray guibg=grey17 gui=none
17 |
18 | " AlignCtrl default
19 | " AlignCtrl =P0 guifg guibg gui
20 | " Align
21 |
22 | " highlight groups
23 | hi Cursor guifg=black guibg=yellow gui=none
24 | hi ErrorMsg guifg=white guibg=red gui=none
25 | hi VertSplit guifg=gray40 guibg=gray40 gui=none
26 | hi Folded guifg=DarkSlateGray3 guibg=grey30 gui=none
27 | hi FoldColumn guifg=tan guibg=grey30 gui=none
28 | hi IncSearch guifg=#b0ffff guibg=#2050d0
29 | hi LineNr guifg=burlywood3 gui=none
30 | hi ModeMsg guifg=SkyBlue gui=none
31 | hi MoreMsg guifg=SeaGreen gui=none
32 | hi NonText guifg=cyan gui=none
33 | hi Question guifg=springgreen gui=none
34 | hi Search guifg=gray80 guibg=#445599 gui=none
35 | hi SpecialKey guifg=cyan gui=none
36 | hi StatusLine guifg=black guibg=#c2bfa5 gui=bold
37 | hi StatusLineNC guifg=grey guibg=gray40 gui=none
38 | hi Title guifg=indianred gui=none
39 | hi Visual guifg=gray17 guibg=tan1 gui=none
40 | hi WarningMsg guifg=salmon gui=none
41 | hi Pmenu guifg=white guibg=#445599 gui=none
42 | hi PmenuSel guifg=#445599 guibg=gray
43 | hi WildMenu guifg=gray guibg=gray17 gui=none
44 | hi MatchParen guifg=cyan guibg=NONE gui=bold
45 | hi DiffAdd guifg=black guibg=wheat1
46 | hi DiffChange guifg=black guibg=skyblue1
47 | hi DiffText guifg=black guibg=hotpink1 gui=none
48 | hi DiffDelete guibg=gray45 guifg=black gui=none
49 |
50 |
51 |
52 | " syntax highlighting groups
53 | hi Comment guifg=PaleGreen3 gui=italic
54 | hi Constant guifg=salmon gui=none
55 | hi Identifier guifg=Skyblue gui=none
56 | hi Function guifg=Skyblue gui=none
57 | hi Statement guifg=lightgoldenrod2 gui=none
58 | hi PreProc guifg=PaleVioletRed2 gui=none
59 | hi Type guifg=tan1 gui=none
60 | hi Special guifg=aquamarine2 gui=none
61 | hi Ignore guifg=grey40 gui=none
62 | hi Todo guifg=orangered guibg=yellow2 gui=none
63 |
64 | " color terminal definitions
65 | hi SpecialKey ctermfg=darkgreen
66 | hi NonText cterm=bold ctermfg=darkblue
67 | hi Directory ctermfg=darkcyan
68 | hi ErrorMsg cterm=bold ctermfg=7 ctermbg=1
69 | hi IncSearch cterm=NONE ctermfg=yellow ctermbg=green
70 | hi Search cterm=NONE ctermfg=grey ctermbg=blue
71 | hi MoreMsg ctermfg=darkgreen
72 | hi ModeMsg cterm=NONE ctermfg=brown
73 | hi LineNr ctermfg=3
74 | hi Question ctermfg=green
75 | hi StatusLine cterm=bold,reverse
76 | hi StatusLineNC cterm=reverse
77 | hi VertSplit cterm=reverse
78 | hi Title ctermfg=5
79 | hi Visual cterm=reverse
80 | hi VisualNOS cterm=bold,underline
81 | hi WarningMsg ctermfg=1
82 | hi WildMenu ctermfg=0 ctermbg=3
83 | hi Folded ctermfg=darkgrey ctermbg=NONE
84 | hi FoldColumn ctermfg=darkgrey ctermbg=NONE
85 | hi DiffAdd ctermbg=4
86 | hi DiffChange ctermbg=5
87 | hi DiffDelete cterm=bold ctermfg=4 ctermbg=6
88 | hi DiffText cterm=bold ctermbg=1
89 | hi Comment ctermfg=darkcyan
90 | hi Constant ctermfg=brown
91 | hi Special ctermfg=5
92 | hi Identifier ctermfg=6
93 | hi Statement ctermfg=3
94 | hi PreProc ctermfg=5
95 | hi Type ctermfg=2
96 | hi Underlined cterm=underline ctermfg=5
97 | hi Ignore ctermfg=darkgrey
98 | hi Error cterm=bold ctermfg=7 ctermbg=1
99 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # holman does dotfiles
2 |
3 | Your dotfiles are how you personalize your system. These are mine.
4 |
5 | I was a little tired of having long alias files and everything strewn about
6 | (which is extremely common on other dotfiles projects, too). That led to this
7 | project being much more topic-centric. I realized I could split a lot of things
8 | up into the main areas I used (Ruby, git, system libraries, and so on), so I
9 | structured the project accordingly.
10 |
11 | If you're interested in the philosophy behind why projects like these are
12 | awesome, you might want to [read my post on the
13 | subject](http://zachholman.com/2010/08/dotfiles-are-meant-to-be-forked/).
14 |
15 | ## topical
16 |
17 | Everything's built around topic areas. If you're adding a new area to your
18 | forked dotfiles — say, "Java" — you can simply add a `java` directory and put
19 | files in there. Anything with an extension of `.zsh` will get automatically
20 | included into your shell. Anything with an extension of `.symlink` will get
21 | symlinked without extension into `$HOME` when you run `script/bootstrap`.
22 |
23 | ## what's inside
24 |
25 | A lot of stuff. Seriously, a lot of stuff. Check them out in the file browser
26 | above and see what components may mesh up with you.
27 | [Fork it](https://github.com/holman/dotfiles/fork), remove what you don't
28 | use, and build on what you do use.
29 |
30 | ## components
31 |
32 | There's a few special files in the hierarchy.
33 |
34 | - **bin/**: Anything in `bin/` will get added to your `$PATH` and be made
35 | available everywhere.
36 | - **Brewfile**: This is a list of applications for [Homebrew Cask](http://caskroom.io) to install: things like Chrome and 1Password and Adium and stuff. Might want to edit this file before running any initial setup.
37 | - **topic/\*.zsh**: Any files ending in `.zsh` get loaded into your
38 | environment.
39 | - **topic/path.zsh**: Any file named `path.zsh` is loaded first and is
40 | expected to setup `$PATH` or similar.
41 | - **topic/completion.zsh**: Any file named `completion.zsh` is loaded
42 | last and is expected to setup autocomplete.
43 | - **topic/install.sh**: Any file named `install.sh` is executed when you run `script/install`. To avoid being loaded automatically, its extension is `.sh`, not `.zsh`.
44 | - **topic/\*.symlink**: Any file ending in `*.symlink` gets symlinked into
45 | your `$HOME`. This is so you can keep all of those versioned in your dotfiles
46 | but still keep those autoloaded files in your home directory. These get
47 | symlinked in when you run `script/bootstrap`.
48 |
49 | ## install
50 |
51 | Run this:
52 |
53 | ```sh
54 | git clone https://github.com/holman/dotfiles.git ~/.dotfiles
55 | cd ~/.dotfiles
56 | script/bootstrap
57 | ```
58 |
59 | This will symlink the appropriate files in `.dotfiles` to your home directory.
60 | Everything is configured and tweaked within `~/.dotfiles`.
61 |
62 | The main file you'll want to change right off the bat is `zsh/zshrc.symlink`,
63 | which sets up a few paths that'll be different on your particular machine.
64 |
65 | `dot` is a simple script that installs some dependencies, sets sane macOS
66 | defaults, and so on. Tweak this script, and occasionally run `dot` from
67 | time to time to keep your environment fresh and up-to-date. You can find
68 | this script in `bin/`.
69 |
70 | ## bugs
71 |
72 | I want this to work for everyone; that means when you clone it down it should
73 | work for you even though you may not have `rbenv` installed, for example. That
74 | said, I do use this as *my* dotfiles, so there's a good chance I may break
75 | something if I forget to make a check for a dependency.
76 |
77 | If you're brand-new to the project and run into any blockers, please
78 | [open an issue](https://github.com/holman/dotfiles/issues) on this repository
79 | and I'd love to get it fixed for you!
80 |
81 | ## thanks
82 |
83 | I forked [Ryan Bates](http://github.com/ryanb)' excellent
84 | [dotfiles](http://github.com/ryanb/dotfiles) for a couple years before the
85 | weight of my changes and tweaks inspired me to finally roll my own. But Ryan's
86 | dotfiles were an easy way to get into bash customization, and then to jump ship
87 | to zsh a bit later. A decent amount of the code in these dotfiles stem or are
88 | inspired from Ryan's original project.
89 |
--------------------------------------------------------------------------------
/vim/vim.symlink/colors/darkspectrum.vim:
--------------------------------------------------------------------------------
1 | " Vim color file
2 | "
3 | " Author: Brian Mock
4 | "
5 | " Note: Based on Oblivion color scheme for gedit (gtk-source-view)
6 | "
7 | " cool help screens
8 | " :he group-name
9 | " :he highlight-groups
10 | " :he cterm-colors
11 |
12 | hi clear
13 |
14 | set background=dark
15 | if version > 580
16 | " no guarantees for version 5.8 and below, but this makes it stop
17 | " complaining
18 | hi clear
19 | if exists("syntax_on")
20 | syntax reset
21 | endif
22 | endif
23 | let g:colors_name="darkspectrum"
24 |
25 | hi Normal guifg=#efefef guibg=#2A2A2A
26 |
27 | " highlight groups
28 | hi Cursor guibg=#ffffff guifg=#000000
29 | hi CursorLine guibg=#000000
30 | "hi CursorLine guibg=#3e4446
31 | hi CursorColumn guibg=#464646
32 |
33 | "hi DiffText guibg=#4e9a06 guifg=#FFFFFF gui=bold
34 | "hi DiffChange guibg=#4e9a06 guifg=#FFFFFF gui=bold
35 | "hi DiffAdd guibg=#204a87 guifg=#FFFFFF gui=bold
36 | "hi DiffDelete guibg=#5c3566 guifg=#FFFFFF gui=bold
37 |
38 | hi DiffAdd guifg=#ffcc7f guibg=#a67429 gui=none
39 | hi DiffChange guifg=#7fbdff guibg=#425c78 gui=none
40 | hi DiffText guifg=#8ae234 guibg=#4e9a06 gui=none
41 | "hi DiffDelete guifg=#252723 guibg=#000000 gui=none
42 | hi DiffDelete guifg=#000000 guibg=#000000 gui=none
43 | "hi ErrorMsg
44 |
45 | hi Number guifg=#fce94f
46 |
47 | hi Folded guibg=#000000 guifg=#FFFFFF gui=bold
48 | hi vimFold guibg=#000000 guifg=#FFFFFF gui=bold
49 | hi FoldColumn guibg=#000000 guifg=#FFFFFF gui=bold
50 |
51 | hi LineNr guifg=#535353 guibg=#202020
52 | hi NonText guifg=#535353 guibg=#202020
53 | hi Folded guifg=#535353 guibg=#202020 gui=bold
54 | hi FoldeColumn guifg=#535353 guibg=#202020 gui=bold
55 | "hi VertSplit guibg=#ffffff guifg=#ffffff gui=none
56 |
57 | hi VertSplit guibg=#3C3C3C guifg=#3C3C3C gui=none
58 | hi StatusLine guifg=#FFFFFF guibg=#3C3C3C gui=none
59 | hi StatusLineNC guifg=#808080 guibg=#3C3C3C gui=none
60 |
61 | hi ModeMsg guifg=#fce94f
62 | hi MoreMsg guifg=#fce94f
63 | hi Visual guifg=#FFFFFF guibg=#3465a4 gui=none
64 | hi VisualNOS guifg=#FFFFFF guibg=#204a87 gui=none
65 | hi IncSearch guibg=#FFFFFF guifg=#ef5939
66 | hi Search guibg=#ad7fa8 guifg=#FFFFFF
67 | hi SpecialKey guifg=#8ae234
68 |
69 | hi Title guifg=#ef5939
70 | hi WarningMsg guifg=#ef5939
71 | hi Number guifg=#fcaf3e
72 |
73 | hi MatchParen guibg=#ad7fa8 guifg=#FFFFFF
74 | hi Comment guifg=#8a8a8a
75 | hi Constant guifg=#ef5939 gui=none
76 | hi String guifg=#fce94f
77 | hi Identifier guifg=#729fcf
78 | hi Statement guifg=#ffffff gui=bold
79 | hi PreProc guifg=#ffffff gui=bold
80 | hi Type guifg=#8ae234 gui=bold
81 | hi Special guifg=#e9b96e
82 | hi Underlined guifg=#ad7fa8 gui=underline
83 | hi Directory guifg=#729fcf
84 | hi Ignore guifg=#555753
85 | hi Todo guifg=#FFFFFF guibg=#ef5939 gui=bold
86 | hi Function guifg=#ad7fa8
87 |
88 | "hi WildMenu guibg=#2e3436 guifg=#ffffff gui=bold
89 | "hi WildMenu guifg=#7fbdff guibg=#425c78 gui=none
90 | hi WildMenu guifg=#ffffff guibg=#3465a4 gui=none
91 |
92 | hi Pmenu guibg=#000000 guifg=#c0c0c0
93 | hi PmenuSel guibg=#3465a4 guifg=#ffffff
94 | hi PmenuSbar guibg=#444444 guifg=#444444
95 | hi PmenuThumb guibg=#888888 guifg=#888888
96 |
97 | hi cppSTLType guifg=#729fcf gui=bold
98 |
99 | hi spellBad guisp=#fcaf3e
100 | hi spellCap guisp=#73d216
101 | hi spellRare guisp=#ad7fa8
102 | hi spellLocal guisp=#729fcf
103 |
104 | hi link cppSTL Function
105 | hi link Error Todo
106 | hi link Character Number
107 | hi link rubySymbol Number
108 | hi link htmlTag htmlEndTag
109 | "hi link htmlTagName htmlTag
110 | hi link htmlLink Underlined
111 | hi link pythonFunction Identifier
112 | hi link Question Type
113 | hi link CursorIM Cursor
114 | hi link VisualNOS Visual
115 | hi link xmlTag Identifier
116 | hi link xmlTagName Identifier
117 | hi link shDeref Identifier
118 | hi link shVariable Function
119 | hi link rubySharpBang Special
120 | hi link perlSharpBang Special
121 | hi link schemeFunc Statement
122 | "hi link shSpecialVariables Constant
123 | "hi link bashSpecialVariables Constant
124 |
125 | " tabs (non gui)
126 | hi TabLine guifg=#A3A3A3 guibg=#202020 gui=none
127 | hi TabLineFill guifg=#535353 guibg=#202020 gui=none
128 | hi TabLineSel guifg=#FFFFFF gui=bold
129 | "hi TabLineSel guifg=#FFFFFF guibg=#000000 gui=bold
130 | " vim: sw=4 ts=4
131 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/src/printstyle.css:
--------------------------------------------------------------------------------
1 |
2 | /* Main stuff */
3 |
4 | body
5 | {
6 | font-family: Serif;
7 | }
8 |
9 | ul
10 | {
11 | list-style-type: square;
12 | padding-left: 1.5em;
13 | }
14 |
15 | ul.spaced > li
16 | {
17 | margin-bottom: 1ex;
18 | }
19 |
20 | pre
21 | {
22 | padding-top: 1ex;
23 | padding-bottom: 1ex;
24 | margin-left: 1.5em;
25 | }
26 |
27 | td
28 | {
29 | vertical-align: top;
30 | }
31 |
32 | .when
33 | {
34 | font-size: x-small;
35 | }
36 |
37 | .nofirefox
38 | {
39 | display: none;
40 | }
41 |
42 |
43 | /* No navigation */
44 |
45 | .nav
46 | {
47 | display: none;
48 | }
49 |
50 |
51 | /* No TOC */
52 |
53 | .contents
54 | {
55 | display: none;
56 | }
57 |
58 | div.toc
59 | {
60 | display: none;
61 | }
62 |
63 |
64 | /* News */
65 |
66 | div.news
67 | {
68 | float: right;
69 | width: 12em;
70 | margin-left: 1em;
71 | margin-bottom: 1em;
72 | padding-left: 1em;
73 | padding-right: 1em;
74 | border: solid 1px #EEE6D4;
75 | }
76 |
77 | div.news h2, div.news h3
78 | {
79 | margin-left: auto;
80 | float: none;
81 | width: auto;
82 | margin-top: auto;
83 | font-size: medium;
84 | text-align: left;
85 | }
86 |
87 | div.news h2
88 | {
89 | margin-top: 0;
90 | font-size: medium;
91 | font-weight: normal;
92 | display: none;
93 | }
94 |
95 | div.news h3
96 | {
97 | }
98 |
99 |
100 | /* Footer */
101 |
102 | div.footer
103 | {
104 | margin-top: 4em;
105 | font-size: x-small;
106 | }
107 |
108 |
109 | /* Java */
110 |
111 | span.j-bkg /* background */
112 | {
113 | }
114 |
115 | span.j-lin /* line numbers */
116 | {
117 | }
118 |
119 | span.j-blk /* block comment */
120 | {
121 | font-style: italic;
122 | color: Gray;
123 | }
124 |
125 | span.j-cmt /* line comment */
126 | {
127 | font-style: italic;
128 | color: Gray;
129 | }
130 |
131 | span.j-key /* keyword */
132 | {
133 | font-weight:bold;
134 | color: maroon;
135 | }
136 |
137 | span.j-str /* string constants */
138 | {
139 | font-style: italic;
140 | color: navy;
141 | }
142 |
143 | span.j-chr /* char constants */
144 | {
145 | font-style: italic;
146 | color: navy;
147 | }
148 |
149 | span.j-num /* number constants */
150 | {
151 | }
152 |
153 | span.j-sym /* symbols, punctuation */
154 | {
155 | }
156 |
157 | span.j-typ /* primitive types */
158 | {
159 | font-weight:bold;
160 | color: maroon;
161 | }
162 |
163 | span.j-def /* default; all the rest */
164 | {
165 | }
166 |
167 | span.j-jdoc /* javadoc */
168 | {
169 | font-style: italic;
170 | color: gray;
171 | }
172 |
173 | span.j-jdoc-key /* javadoc keyword */
174 | {
175 | font-style: italic;
176 | font-weight: bold;
177 | color: gray;
178 | }
179 |
180 | span.j-jdoc-html /* javadoc html tag */
181 | {
182 | font-style: italic;
183 | color: gray;
184 | }
185 |
186 | span.j-jdoc-link /* javadoc link */
187 | {
188 | font-style: italic;
189 | color: gray;
190 | }
191 |
192 | span.j-undef /* undefined */
193 | {
194 | }
195 |
196 | span.j-hl /* highlight */
197 | {
198 | }
199 |
200 | /******************** Excel */
201 |
202 | table.xl
203 | {
204 | border-collapse:collapse;
205 | }
206 |
207 | table.xl td
208 | {
209 | border: solid 1px lightgray;
210 | text-align: left;
211 | vertical-align: top;
212 | }
213 |
214 | table.xl td.xl-row, table.xl thead td
215 | {
216 | background-color: #ECECEC;
217 | border-color: gray;
218 | text-align: center;
219 | padding-left: 2px;
220 | padding-right: 2px;
221 | }
222 |
223 | table.xl td.xl-num, table.xl td.xl-date
224 | {
225 | text-align: right;
226 | }
227 |
228 | span.xl-exp
229 | {
230 | font-size: x-small;
231 | font-family: monospace;
232 | color: maroon;
233 | }
234 |
235 | span.xl-name
236 | {
237 | font-size: x-small;
238 | font-style: italic;
239 | color: #6495ED;
240 | }
241 |
242 | td.xl-r1, span.xl-r1
243 | {
244 | background-color: #E0FFFF;
245 | }
246 |
247 | td.xl-r2, span.xl-r2
248 | {
249 | background-color: #FFE0FF;
250 | }
251 |
252 | td.xl-r3, span.xl-r3
253 | {
254 | background-color: #FFFFE0;
255 | }
256 |
257 | td.xl-r4, span.xl-r4
258 | {
259 | background-color: #E0FFE0;
260 | }
261 |
262 | td.xl-r5, span.xl-r5
263 | {
264 | background-color: #E0E0FF;
265 | }
266 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/qimportbz/bzhandler.py:
--------------------------------------------------------------------------------
1 | # std python modules
2 | import urllib2
3 | try:
4 | import cStringIO as StringIO
5 | except ImportError:
6 | import StringIO
7 | import os
8 | import re
9 |
10 | # qimportbz modules
11 | import bz
12 |
13 | # Patch list
14 | delayed_imports = []
15 |
16 | # (Patch * path) list
17 | imported_patches = []
18 |
19 | class ObjectResponse(object):
20 | def __init__(self, obj):
21 | self.obj = obj
22 |
23 | def read(self):
24 | return self.obj
25 |
26 | class Handler(urllib2.BaseHandler):
27 | def __init__(self, ui, passmgr):
28 | self.ui = ui
29 | self.passmgr = passmgr
30 |
31 | self.base = ui.config('qimportbz', 'bugzilla',
32 | os.environ.get('BUGZILLA', "bugzilla.mozilla.org"))
33 |
34 | self.autoChoose = ui.config('qimportbz', 'auto_choose_all', False)
35 |
36 | # Change the request to the https for the bug XML
37 | def bz_open(self, req):
38 | num = int(req.get_host())
39 | if num in bz.cache:
40 | bug = bz.cache[num]
41 | # strip the /
42 | attachid = req.get_selector()[1:]
43 | if attachid:
44 | return ObjectResponse(bug.get_patch(attachid))
45 |
46 | return ObjectResponse(bug)
47 |
48 | # Normal case, return a stream of text
49 | url = "https://%s/show_bug.cgi?ctype=xml&id=%s" % (self.base, num)
50 | self.ui.status("Fetching...")
51 | return self.parent.open(url)
52 |
53 | # Once the XML is fetched, parse and decide what to return
54 | def bz_response(self, req, res):
55 | patch = None
56 | # Check if we're doing a cached lookup - no ui in this case since we're
57 | # working around mq's limitations
58 | data = res.read()
59 | if isinstance(data, bz.Bug):
60 | bug = data
61 | elif isinstance(data, bz.Patch):
62 | patch = data
63 | else: # network read
64 | self.ui.status(" done\n")
65 | self.ui.status("Parsing...")
66 | try:
67 | bug = bz.Bug(self.ui, data)
68 | # TODO: update syntax when mercurial requires Python 2.6
69 | except bz.PermissionError, e:
70 | self.ui.warn(" %s\n" % e.msg)
71 | return
72 | self.ui.status(" done\n")
73 |
74 | attachid = req.get_selector()[1:]
75 | if not patch and attachid:
76 | patch = bug.get_patch(attachid)
77 |
78 | if not patch:
79 | patches = [p for p in bug.patches if not p.obsolete]
80 | if len(patches) == 0:
81 | patches = bug.patches
82 | if len(patches) == 0:
83 | self.ui.warn("No patches found for this bug\n")
84 | return
85 |
86 | if len(patches) > 1:
87 | self.ui.warn("Only obsolete patches found\n")
88 | else:
89 | if 'y' != self.ui.prompt("Only found one patch and it is obsolete. Import anyways? [Default is 'y']", default='y'):
90 | return
91 | if len(patches) == 1:
92 | patch = patches[0]
93 | elif len(patches) > 0:
94 | for i, p in enumerate(patches):
95 | flags = p.joinFlags(False)
96 | self.ui.write("%s: %s%s\n" % (i + 1, p.desc, "\n %s" % flags if flags else ""))
97 | choicestr = ' '.join([str(n) for n in xrange(1,len(patches)+1)])
98 | choicestr = choicestr if self.autoChoose else self.ui.prompt("Which patches do you want to import? [Default is '1', use '1-%d' for all]" % len(patches), default="1")
99 | for choice in (s.strip() for t in choicestr.split(',') for s in t.split()):
100 | try:
101 | m = re.match(r'(\d+)-(\d+)$', choice)
102 | if m:
103 | delayed_imports.extend([ patches[p] for p in xrange(int(m.group(1)) - 1, int(m.group(2))) ])
104 | else:
105 | if int(choice) <= 0:
106 | raise IndexError()
107 | delayed_imports.append(patches[int(choice) - 1])
108 | except (ValueError, IndexError):
109 | self.ui.warn("Invalid patch number = '%s'\n" % choice)
110 | continue
111 | if not patch and len(delayed_imports) > 0:
112 | patch = delayed_imports.pop(0)
113 |
114 | # and finally return the response
115 | if patch:
116 | imported_patches.append((patch, req.get_full_url()))
117 | return PatchResponse(patch)
118 |
119 | # interface reverse engineered from urllib.addbase
120 | class PatchResponse(object):
121 | def __init__(self, p):
122 | self.patch = p
123 | # utf-8: convert from internal (16/32-bit) Unicode to 8-bit encoding.
124 | # NB: Easier output to deal with, as most (code) patches are ASCII only.
125 | self.fp = StringIO.StringIO(unicode(p).encode('utf-8'))
126 | self.read = self.fp.read
127 | self.readline = self.fp.readline
128 | self.close = self.fp.close
129 |
130 | def fileno(self):
131 | return None
132 |
--------------------------------------------------------------------------------
/vim/vim.symlink/colors/argonaut.vim:
--------------------------------------------------------------------------------
1 | " Vim color file
2 | " Converted from Textmate theme [ Argonaut ] using Coloration v0.2.5 (http://github.com/sickill/coloration)
3 |
4 | set background=dark
5 | highlight clear
6 |
7 | if exists("syntax_on")
8 | syntax reset
9 | endif
10 |
11 | let g:colors_name = "[ Argonaut ]"
12 |
13 | hi Cursor guifg=NONE guibg=#ff2200 gui=NONE
14 | hi Visual guifg=NONE guibg=#002f53 gui=NONE
15 | hi CursorLine guifg=NONE guibg=#000c16 gui=NONE
16 | hi CursorColumn guifg=NONE guibg=#000c16 gui=NONE
17 | hi LineNr guifg=#606268 guibg=#0e111d gui=NONE
18 | hi VertSplit guifg=#2d3039 guibg=#2d3039 gui=NONE
19 | hi MatchParen guifg=#ffffff guibg=NONE gui=bold
20 | hi StatusLine guifg=#b2b2b2 guibg=#2d3039 gui=bold
21 | hi StatusLineNC guifg=#b2b2b2 guibg=#2d3039 gui=NONE
22 | hi Pmenu guifg=NONE guibg=NONE gui=NONE
23 | hi PmenuSel guifg=NONE guibg=#002f53 gui=NONE
24 | hi IncSearch guifg=NONE guibg=#5e6068 gui=NONE
25 | hi Search guifg=NONE guibg=#5e6068 gui=NONE
26 | hi Directory guifg=#a4ed2d guibg=NONE gui=bold
27 | hi Folded guifg=#00a6ff guibg=#0e111d gui=NONE
28 |
29 | hi Normal guifg=#b2b2b2 guibg=#0e111d gui=NONE
30 | hi Boolean guifg=#a4ed2d guibg=NONE gui=bold
31 | hi Character guifg=#a4ed2d guibg=NONE gui=bold
32 | hi Comment guifg=#00a6ff guibg=NONE gui=NONE
33 | hi Conditional guifg=#ffffff guibg=NONE gui=bold
34 | hi Constant guifg=#a4ed2d guibg=NONE gui=bold
35 | hi Define guifg=#ffffff guibg=NONE gui=bold
36 | hi ErrorMsg guifg=#ffffff guibg=#990000 gui=NONE
37 | hi WarningMsg guifg=#ffffff guibg=#990000 gui=NONE
38 | hi Float guifg=#d70000 guibg=NONE gui=NONE
39 | hi Function guifg=#ffca00 guibg=NONE gui=bold
40 | hi Identifier guifg=#ffffff guibg=NONE gui=bold
41 | hi Keyword guifg=#ffffff guibg=NONE gui=bold
42 | hi Label guifg=#6497c5 guibg=NONE gui=NONE
43 | hi NonText guifg=#ffb500 guibg=#000c16 gui=NONE
44 | hi Number guifg=#d70000 guibg=NONE gui=NONE
45 | hi Operator guifg=#ffffff guibg=NONE gui=bold
46 | hi PreProc guifg=#ffffff guibg=NONE gui=bold
47 | hi Special guifg=#b2b2b2 guibg=NONE gui=NONE
48 | hi SpecialKey guifg=#ffb500 guibg=#000c16 gui=NONE
49 | hi Statement guifg=#ffffff guibg=NONE gui=bold
50 | hi StorageClass guifg=#ffffff guibg=NONE gui=bold
51 | hi String guifg=#6497c5 guibg=NONE gui=NONE
52 | hi Tag guifg=#0065d3 guibg=NONE gui=NONE
53 | hi Title guifg=#b2b2b2 guibg=NONE gui=bold
54 | hi Todo guifg=#00a6ff guibg=NONE gui=inverse,bold
55 | hi Type guifg=NONE guibg=NONE gui=NONE
56 | hi Underlined guifg=NONE guibg=NONE gui=underline
57 | hi rubyClass guifg=#ffffff guibg=NONE gui=bold
58 | hi rubyFunction guifg=#ffca00 guibg=NONE gui=bold
59 | hi rubyInterpolationDelimiter guifg=NONE guibg=NONE gui=NONE
60 | hi rubySymbol guifg=#a4ed2d guibg=NONE gui=bold
61 | hi rubyConstant guifg=#7a88f6 guibg=NONE gui=bold
62 | hi rubyStringDelimiter guifg=#6497c5 guibg=NONE gui=NONE
63 | hi rubyBlockParameter guifg=NONE guibg=NONE gui=NONE
64 | hi rubyInstanceVariable guifg=#0068c5 guibg=NONE gui=NONE
65 | hi rubyInclude guifg=#ffffff guibg=NONE gui=bold
66 | hi rubyGlobalVariable guifg=#0068c5 guibg=NONE gui=NONE
67 | hi rubyRegexp guifg=#6497c5 guibg=NONE gui=NONE
68 | hi rubyRegexpDelimiter guifg=#6497c5 guibg=NONE gui=NONE
69 | hi rubyEscape guifg=#a4ed2d guibg=NONE gui=bold
70 | hi rubyControl guifg=#ffffff guibg=NONE gui=bold
71 | hi rubyClassVariable guifg=NONE guibg=NONE gui=NONE
72 | hi rubyOperator guifg=#ffffff guibg=NONE gui=bold
73 | hi rubyException guifg=#ffffff guibg=NONE gui=bold
74 | hi rubyPseudoVariable guifg=#0068c5 guibg=NONE gui=NONE
75 | hi rubyRailsUserClass guifg=#7a88f6 guibg=NONE gui=bold
76 | hi rubyRailsARAssociationMethod guifg=#815db3 guibg=NONE gui=NONE
77 | hi rubyRailsARMethod guifg=#815db3 guibg=NONE gui=NONE
78 | hi rubyRailsRenderMethod guifg=#815db3 guibg=NONE gui=NONE
79 | hi rubyRailsMethod guifg=#815db3 guibg=NONE gui=NONE
80 | hi erubyDelimiter guifg=NONE guibg=NONE gui=NONE
81 | hi erubyComment guifg=#00a6ff guibg=NONE gui=NONE
82 | hi erubyRailsMethod guifg=#815db3 guibg=NONE gui=NONE
83 | hi htmlTag guifg=NONE guibg=NONE gui=NONE
84 | hi htmlEndTag guifg=NONE guibg=NONE gui=NONE
85 | hi htmlTagName guifg=NONE guibg=NONE gui=NONE
86 | hi htmlArg guifg=NONE guibg=NONE gui=NONE
87 | hi htmlSpecialChar guifg=#a4ed2d guibg=NONE gui=bold
88 | hi javaScriptFunction guifg=#ffffff guibg=NONE gui=bold
89 | hi javaScriptRailsFunction guifg=#815db3 guibg=NONE gui=NONE
90 | hi javaScriptBraces guifg=NONE guibg=NONE gui=NONE
91 | hi yamlKey guifg=#0065d3 guibg=NONE gui=NONE
92 | hi yamlAnchor guifg=#0068c5 guibg=NONE gui=NONE
93 | hi yamlAlias guifg=#0068c5 guibg=NONE gui=NONE
94 | hi yamlDocumentHeader guifg=NONE guibg=#090c15 gui=NONE
95 | hi cssURL guifg=NONE guibg=NONE gui=NONE
96 | hi cssFunctionName guifg=#815db3 guibg=NONE gui=NONE
97 | hi cssColor guifg=#a4ed2d guibg=NONE gui=bold
98 | hi cssPseudoClassId guifg=NONE guibg=NONE gui=NONE
99 | hi cssClassName guifg=NONE guibg=NONE gui=NONE
100 | hi cssValueLength guifg=#d70000 guibg=NONE gui=NONE
101 | hi cssCommonAttr guifg=#06960e guibg=NONE gui=NONE
102 | hi cssBraces guifg=NONE guibg=NONE gui=NONE
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/docbash.py:
--------------------------------------------------------------------------------
1 | #! /usr/bin/env python
2 |
3 | from __future__ import with_statement
4 | from subprocess import Popen, PIPE, STDOUT
5 | import sys, re, cgi
6 |
7 | def unformat(line):
8 | res = line.strip("\n")
9 | if res.startswith("\t"):
10 | res = res[1:]
11 | return res.strip(" $")
12 |
13 | class Runner:
14 |
15 | def __init__(self):
16 | self.HGCALL = re.compile("(^|; )hg ")
17 | self.shell = Popen("/bin/bash", stdin=PIPE, stdout=PIPE, stderr=STDOUT)
18 |
19 | def run(self, cmdlines, script):
20 |
21 | def localhg(cmd):
22 | (res, _subs) = self.HGCALL.subn('$HGPATH/hg ', cmd)
23 | return res
24 |
25 | cmds = [l.strip("\n") for l in cmdlines]
26 | cmds = [localhg(l) for l in cmds]
27 |
28 | for l in cmds:
29 | script.write("%s\n" % l)
30 |
31 | cmd = "\n".join(cmds) + "\necho\necho ,,,,\n"
32 | self.shell.stdin.write(cmd)
33 | self.shell.stdin.flush()
34 | outlines = []
35 | stdout = self.shell.stdout
36 | l = None
37 | while True:
38 | l = stdout.readline()
39 | if l == ",,,,\n": break
40 | outlines.append(l.rstrip())
41 | while outlines and not outlines[-1]:
42 | del outlines[-1]
43 | return ["%s\n" % l for l in outlines]
44 |
45 | def close(self):
46 | self.shell.communicate("exit\n")
47 |
48 | def run(srcname, tgtname, actname, scriptname):
49 | runner = Runner()
50 | with open(tgtname, "w") as tgt:
51 | code = 0
52 | input = 1
53 | have = [False, False]
54 | def startinput():
55 | if not have[code]:
56 | tgt.write('\n')
57 | have[code] = True
58 | have[input] = True
59 | elif not have[input]:
60 | tgt.write('')
61 | have[input] = True
62 | def startoutput():
63 | tgt.write('')
64 | have[input] = False
65 | def stoptranscript():
66 | if have[code]:
67 | tgt.write('
\n\n')
68 | have[:] = [False, False]
69 | with open(actname, "w") as act:
70 | with open(srcname) as src:
71 | with open(scriptname, "w") as script:
72 | line = src.readline()
73 | while line:
74 | if line.startswith("\t$ "):
75 | cmdlines = [line]
76 | line = src.readline()
77 | if cmdlines[0].endswith("eof\n"):
78 | while line and not line.endswith("eof\n"):
79 | cmdlines.append(line)
80 | line = src.readline()
81 | cmdlines.append(line)
82 | line = src.readline()
83 | wantlines = []
84 | while line.startswith("\t") and not line.startswith("\t$ "):
85 | wantlines.append(line)
86 | line = src.readline()
87 | scriptlines = [unformat(l) for l in cmdlines]
88 | if scriptlines and scriptlines[0] == "EXIT":
89 | print "EXITING"
90 | return
91 | havelines = runner.run(scriptlines, script)
92 |
93 | startinput()
94 | for l in cmdlines:
95 | act.write(l)
96 | if l == "\n":
97 | tgt.write(l)
98 | else:
99 | tgt.write(cgi.escape(l[1:]))
100 |
101 | if havelines:
102 | startoutput()
103 | for l in havelines:
104 | if l == "\n":
105 | l = "_\n"
106 | act.write("\t")
107 | act.write(l)
108 | tgt.write(cgi.escape(l))
109 | else:
110 | stoptranscript()
111 | tgt.write(line)
112 | act.write(line)
113 | line = src.readline()
114 | stoptranscript()
115 | runner.close()
116 |
117 |
118 | srcname = sys.argv[1]
119 | tgtname = sys.argv[2]
120 | actname= sys.argv[3]
121 | scriptname = sys.argv[4]
122 |
123 | print "Input: %s" % srcname
124 | print "Target: %s" % tgtname
125 | print "Actual: %s" % actname
126 | print "Script: %s" % scriptname
127 |
128 | run(srcname, tgtname, actname, scriptname)
129 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/crecord/crecord/__init__.py:
--------------------------------------------------------------------------------
1 | # crecord.py
2 | #
3 | # Copyright 2008 Mark Edgington
4 | #
5 | # This software may be used and distributed according to the terms of
6 | # the GNU General Public License, incorporated herein by reference.
7 | #
8 | # Much of this extension is based on Bryan O'Sullivan's record extension.
9 |
10 | '''text-gui based change selection during commit or qrefresh'''
11 | from mercurial.i18n import _
12 | from mercurial import commands, extensions, util
13 |
14 | from crecord_core import dorecord
15 |
16 | def crecord(ui, repo, *pats, **opts):
17 | '''interactively select changes to commit
18 |
19 | If a list of files is omitted, all changes reported by :hg:`status`
20 | will be candidates for recording.
21 |
22 | See :hg:`help dates` for a list of formats valid for -d/--date.
23 |
24 | You will be shown a list of patch hunks from which you can select
25 | those you would like to apply to the commit.
26 |
27 | This command is not available when committing a merge.'''
28 |
29 | dorecord(ui, repo, commands.commit, *pats, **opts)
30 |
31 |
32 | def qcrecord(ui, repo, patch, *pats, **opts):
33 | '''interactively record a new patch
34 |
35 | See :hg:`help qnew` & :hg:`help crecord` for more information and
36 | usage.
37 | '''
38 |
39 | try:
40 | mq = extensions.find('mq')
41 | except KeyError:
42 | raise util.Abort(_("'mq' extension not loaded"))
43 |
44 | def committomq(ui, repo, *pats, **opts):
45 | mq.new(ui, repo, patch, *pats, **opts)
46 |
47 | opts = opts.copy()
48 | opts['force'] = True # always 'qnew -f'
49 | dorecord(ui, repo, committomq, *pats, **opts)
50 |
51 |
52 | def qcrefresh(ui, repo, *pats, **opts):
53 | """interactively update the current patch
54 |
55 | If any file patterns are provided, the refreshed patch will
56 | contain only the modifications that match those patterns; the
57 | remaining modifications will remain in the working directory.
58 |
59 | If -s/--short is specified, files currently included in the patch
60 | will be refreshed just like matched files and remain in the patch.
61 |
62 | hg add/remove/copy/rename work as usual, though you might want to
63 | use git-style patches (-g/--git or [diff] git=1) to track copies
64 | and renames. See the diffs help topic for more information on the
65 | git diff format.
66 |
67 | See :hg:`help qrefresh` & :hg:`help crecord` for more information and
68 | usage.
69 | """
70 |
71 | # Note: if the record operation (or subsequent refresh) fails partway
72 | # through, the top applied patch will be emptied and the working directory
73 | # will contain all of its changes.
74 |
75 | try:
76 | mq = extensions.find('mq')
77 | except KeyError:
78 | raise util.Abort(_("'mq' extension not loaded"))
79 |
80 | def refreshmq(ui, repo, *pats, **opts):
81 | mq.refresh(ui, repo, *pats, **opts)
82 |
83 | # Cannot use the simple pattern '*' because it will resolve relative to the
84 | # current working directory
85 | clearopts = { 'exclude': ["re:."], 'message': "" }
86 |
87 | mq.refresh(ui, repo, **clearopts)
88 |
89 | # if message wasn't specified in commandline, initialize from existing patch header
90 | if not opts.get('message',''):
91 | patchname = repo.mq.applied[-1].name
92 | patchmsg_lines = mq.patchheader(repo.mq.join(patchname), repo.mq.plainmode).message
93 | opts['message'] = '\n'.join(patchmsg_lines)
94 |
95 | dorecord(ui, repo, refreshmq, *pats, **opts)
96 |
97 |
98 | cmdtable = {
99 | "crecord":
100 | (crecord,
101 |
102 | # add commit options
103 | commands.table['^commit|ci'][1],
104 |
105 | _('hg crecord [OPTION]... [FILE]...')),
106 | }
107 |
108 |
109 | def extsetup():
110 | try:
111 | keyword = extensions.find('keyword')
112 | keyword.restricted += ' crecord qcrecord qcrefresh'
113 | try:
114 | keyword.recordextensions += ' crecord'
115 | keyword.recordcommands += ' crecord qcrecord qcrefresh'
116 | except AttributeError:
117 | pass
118 | except KeyError:
119 | pass
120 |
121 | try:
122 | mq = extensions.find('mq')
123 | except KeyError:
124 | return
125 |
126 | qnew = '^qnew'
127 | if not qnew in mq.cmdtable:
128 | # backwards compatible with pre 301633755dec
129 | qnew = 'qnew'
130 |
131 | qrefresh = '^qrefresh'
132 | if not qrefresh in mq.cmdtable:
133 | # backwards compatible?
134 | qrefresh = 'qrefresh'
135 |
136 | qcmdtable = {
137 | "qcrecord":
138 | (qcrecord,
139 |
140 | # add qnew options, except '--force'
141 | [opt for opt in mq.cmdtable[qnew][1] if opt[1] != 'force'],
142 |
143 | _('hg qcrecord [OPTION]... PATCH [FILE]...')),
144 |
145 | "qcrefresh":
146 | (qcrefresh,
147 |
148 | # same options as qrefresh
149 | mq.cmdtable[qrefresh][1],
150 |
151 | _('hg qcrefresh [-I] [-X] [-e] [-m TEXT] [-l FILE] [-s] [FILE]...')),
152 | }
153 |
154 | cmdtable.update(qcmdtable)
155 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/src/pbranch/pullupstream.rextile:
--------------------------------------------------------------------------------
1 |
2 | h1. Pulling And Merging From Upstream
3 |
4 | <%= toc %>
5 |
6 |
7 | This continues the example from "multiple graphs":graph.htm.
8 |
9 |
10 | h2. Pulling And Merging
11 |
12 | Work continues upstream:
13 |
14 | $ cd graph-upstream
15 | $ echo a >def-1
16 | $ hg commit --add --message "def-1"
17 | adding def-1
18 | $ cd ..
19 |
20 | We want to pull and merge this work so as to base our patches on latest upstream:
21 |
22 | $ cd graph-forkjoin
23 | $ hg pgraph --status
24 | created graph description from current tips
25 | o p_join
26 | |\
27 | o | p_fork2
28 | | |
29 | | o p_fork1
30 | |/
31 | o p_root
32 | |
33 | @ default
34 |
35 | So we pull:
36 |
37 | $ hg pull ../graph-upstream
38 | pulling from ../graph-upstream
39 | searching for changes
40 | adding changesets
41 | adding manifests
42 | adding file changes
43 | added 1 changesets with 1 changes to 1 files (+1 heads)
44 | (run 'hg heads' to see heads)
45 |
46 | and the situation in the repository is as follows:
47 |
48 | $ hg glog
49 | o 8 : def-1 - john
50 | |
51 | | o 7 p_join: merge of .p_join - john
52 | | |\
53 | | | o 6 .p_join: merge of p_fork2 - john
54 | | | |\
55 | | | | o 5 .p_join: update patch dependencies - john
56 | | | | |
57 | | | o | 4 p_fork2: start new patch on p_root - john
58 | | | | |
59 | | o---+ 3 p_join: start new patch on p_fork1 - john
60 | | / /
61 | | | o 2 p_fork1: start new patch on p_root - john
62 | | |/
63 | | o 1 p_root: start new patch on default - john
64 | |/
65 | @ 0 : def-0 - john
66 |
67 | To ripple the change in _dev-1_ through to all our patch branches, we need a lot of merges:
68 |
69 | $ hg pgraph --status
70 | o p_join
71 | |\ * needs merge with default (through .p_join, p_fork2, p_root)
72 | | | * needs merge with default (through .p_join, p_fork1, p_root)
73 | o | p_fork2
74 | | | * needs merge with default (through p_root)
75 | | o p_fork1
76 | |/ * needs merge with default (through p_root)
77 | o p_root
78 | | * needs merge with default
79 | | * needs update of diff base to tip of default
80 | @ default
81 |
82 | We can do this in a single sweep by merging all pending heads:
83 |
84 | $ hg pmerge --all
85 | updating to default
86 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved
87 | p_root: merging from default
88 | marked working directory as branch p_root
89 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
90 | p_fork1: merging from p_root
91 | marked working directory as branch p_fork1
92 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
93 | updating to p_root
94 | 0 files updated, 0 files merged, 2 files removed, 0 files unresolved
95 | p_fork2: merging from p_root
96 | marked working directory as branch p_fork2
97 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
98 | created new head
99 | .p_join: merging from p_fork2
100 | marked working directory as branch .p_join
101 | 3 files updated, 0 files merged, 0 files removed, 0 files unresolved
102 | updating to p_fork1
103 | 1 files updated, 0 files merged, 3 files removed, 0 files unresolved
104 | .p_join: merging from p_fork1
105 | marked working directory as branch .p_join
106 | merging .hgpatchinfo/p_fork1.dep
107 | 3 files updated, 1 files merged, 0 files removed, 0 files unresolved
108 | p_join: merging from .p_join
109 | marked working directory as branch p_join
110 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
111 |
112 |
113 | h2. Reviewing Merges
114 |
115 | This merge orgy resulted in a fairly complicated graph:
116 |
117 | $ hg glog
118 | @ 14 p_join: merge of .p_join - john
119 | |\
120 | | o 13 .p_join: merge of p_fork1 - john
121 | | |\
122 | | | o 12 .p_join: merge of p_fork2 - john
123 | | | |\
124 | | | | o 11 p_fork2: merge of p_root - john
125 | | | | |\
126 | | o-----+ 10 p_fork1: merge of p_root - john
127 | | | | | |
128 | | | | | o 9 p_root: merge of default - john
129 | | | | | |\
130 | | | | | | o 8 : def-1 - john
131 | | | | | | |
132 | o---+ | | | 7 p_join: merge of .p_join - john
133 | | | | | | |
134 | | | o | | | 6 .p_join: merge of p_fork2 - john
135 | | | |\| | |
136 | | | o | | | 5 .p_join: update patch dependencies - john
137 | | |/ / / /
138 | | | o / / 4 p_fork2: start new patch on p_root - john
139 | | | |/ /
140 | o | / / 3 p_join: start new patch on p_fork1 - john
141 | |/ / /
142 | o / / 2 p_fork1: start new patch on p_root - john
143 | |/ /
144 | o / 1 p_root: start new patch on default - john
145 | |/
146 | o 0 : def-0 - john
147 |
148 | To review a merge, we can diff it and check that it didn't do anything except what the patch is supposed to do. So we look at the patch:
149 |
150 | $ hg pdiff p_root
151 | # HG changeset patch
152 | # User john
153 | # Date 0 0
154 | _
155 | diff --git a/p_root b/p_root
156 | new file mode 100644
157 | --- /dev/null
158 | +++ b/p_root
159 | @@ -0,0 +1,1 @@
160 | +a
161 |
162 | and compare with the merge diff:
163 |
164 | $ hg diff --change 9 -X .hgpatchinfo
165 | diff --git a/p_root b/p_root
166 | new file mode 100644
167 | --- /dev/null
168 | +++ b/p_root
169 | @@ -0,0 +1,1 @@
170 | +a
171 |
172 | This works because pbranch always uses the base branch as the first parent of the merge.
173 |
174 |
--------------------------------------------------------------------------------
/vim/vim.symlink/colors/Clouds-Midnight.vim:
--------------------------------------------------------------------------------
1 | " Vim color file
2 | " Converted from Textmate theme Clouds Midnight using Coloration v0.2.4 (http://github.com/sickill/coloration)
3 |
4 | set background=dark
5 | highlight clear
6 |
7 | if exists("syntax_on")
8 | syntax reset
9 | endif
10 |
11 | let g:colors_name = "Clouds Midnight"
12 |
13 | hi Cursor guifg=NONE guibg=#7da5dc gui=NONE
14 | hi Visual guifg=NONE guibg=#000000 gui=NONE
15 | hi CursorLine guifg=NONE guibg=#1f1f1f gui=NONE
16 | hi CursorColumn guifg=NONE guibg=#1f1f1f gui=NONE
17 | hi ColorColumn guifg=NONE guibg=#1f1f1f gui=NONE
18 | hi LineNr guifg=#565656 guibg=#191919 gui=NONE
19 | hi VertSplit guifg=#303030 guibg=#303030 gui=NONE
20 | hi MatchParen guifg=#927c5d guibg=NONE gui=NONE
21 | hi StatusLine guifg=#929292 guibg=#303030 gui=bold
22 | hi StatusLineNC guifg=#929292 guibg=#303030 gui=NONE
23 | hi Pmenu guifg=NONE guibg=NONE gui=NONE
24 | hi PmenuSel guifg=NONE guibg=#000000 gui=NONE
25 | hi IncSearch guifg=NONE guibg=#413a2f gui=NONE
26 | hi Search guifg=NONE guibg=#413a2f gui=NONE
27 | hi Directory guifg=NONE guibg=NONE gui=NONE
28 | hi Folded guifg=#3c403b guibg=#191919 gui=NONE
29 |
30 | hi Normal guifg=#929292 guibg=#191919 gui=NONE
31 | hi Boolean guifg=#39946a guibg=NONE gui=NONE
32 | hi Character guifg=NONE guibg=NONE gui=NONE
33 | hi Comment guifg=#3c403b guibg=NONE gui=NONE
34 | hi Conditional guifg=#927c5d guibg=NONE gui=NONE
35 | hi Constant guifg=NONE guibg=NONE gui=NONE
36 | hi Define guifg=#927c5d guibg=NONE gui=NONE
37 | hi ErrorMsg guifg=#ffffff guibg=#e92e2e gui=NONE
38 | hi WarningMsg guifg=#ffffff guibg=#e92e2e gui=NONE
39 | hi Float guifg=#46a609 guibg=NONE gui=NONE
40 | hi Function guifg=NONE guibg=NONE gui=NONE
41 | hi Identifier guifg=#e92e2e guibg=NONE gui=NONE
42 | hi Keyword guifg=#927c5d guibg=NONE gui=NONE
43 | hi Label guifg=#5d90cd guibg=NONE gui=NONE
44 | hi NonText guifg=#333333 guibg=NONE gui=NONE
45 | hi Number guifg=#46a609 guibg=NONE gui=NONE
46 | hi Operator guifg=#4b4b4b guibg=NONE gui=NONE
47 | hi PreProc guifg=#927c5d guibg=NONE gui=NONE
48 | hi Special guifg=#929292 guibg=NONE gui=NONE
49 | hi SpecialKey guifg=#bfbfbf guibg=#1f1f1f gui=NONE
50 | hi Statement guifg=#927c5d guibg=NONE gui=NONE
51 | hi StorageClass guifg=#e92e2e guibg=NONE gui=NONE
52 | hi String guifg=#5d90cd guibg=NONE gui=NONE
53 | hi Tag guifg=#606060 guibg=NONE gui=NONE
54 | hi Title guifg=#929292 guibg=NONE gui=bold
55 | hi Todo guifg=#3c403b guibg=NONE gui=inverse,bold
56 | hi Type guifg=NONE guibg=NONE gui=NONE
57 | hi Underlined guifg=NONE guibg=NONE gui=underline
58 | hi rubyClass guifg=#927c5d guibg=NONE gui=NONE
59 | hi rubyFunction guifg=NONE guibg=NONE gui=NONE
60 | hi rubyInterpolationDelimiter guifg=NONE guibg=NONE gui=NONE
61 | hi rubySymbol guifg=NONE guibg=NONE gui=NONE
62 | hi rubyConstant guifg=NONE guibg=NONE gui=NONE
63 | hi rubyStringDelimiter guifg=#5d90cd guibg=NONE gui=NONE
64 | hi rubyBlockParameter guifg=NONE guibg=NONE gui=NONE
65 | hi rubyInstanceVariable guifg=NONE guibg=NONE gui=NONE
66 | hi rubyInclude guifg=#927c5d guibg=NONE gui=NONE
67 | hi rubyGlobalVariable guifg=NONE guibg=NONE gui=NONE
68 | hi rubyRegexp guifg=#5d90cd guibg=NONE gui=NONE
69 | hi rubyRegexpDelimiter guifg=#5d90cd guibg=NONE gui=NONE
70 | hi rubyEscape guifg=NONE guibg=NONE gui=NONE
71 | hi rubyControl guifg=#927c5d guibg=NONE gui=NONE
72 | hi rubyClassVariable guifg=NONE guibg=NONE gui=NONE
73 | hi rubyOperator guifg=#4b4b4b guibg=NONE gui=NONE
74 | hi rubyException guifg=#927c5d guibg=NONE gui=NONE
75 | hi rubyPseudoVariable guifg=NONE guibg=NONE gui=NONE
76 | hi rubyRailsUserClass guifg=NONE guibg=NONE gui=NONE
77 | hi rubyRailsARAssociationMethod guifg=#e92e2e guibg=NONE gui=NONE
78 | hi rubyRailsARMethod guifg=#e92e2e guibg=NONE gui=NONE
79 | hi rubyRailsRenderMethod guifg=#e92e2e guibg=NONE gui=NONE
80 | hi rubyRailsMethod guifg=#e92e2e guibg=NONE gui=NONE
81 | hi erubyDelimiter guifg=#e92e2e guibg=NONE gui=NONE
82 | hi erubyComment guifg=#3c403b guibg=NONE gui=NONE
83 | hi erubyRailsMethod guifg=#e92e2e guibg=NONE gui=NONE
84 | hi htmlTag guifg=NONE guibg=NONE gui=NONE
85 | hi htmlEndTag guifg=NONE guibg=NONE gui=NONE
86 | hi htmlTagName guifg=NONE guibg=NONE gui=NONE
87 | hi htmlArg guifg=NONE guibg=NONE gui=NONE
88 | hi htmlSpecialChar guifg=#a165ac guibg=NONE gui=NONE
89 | hi javaScriptFunction guifg=#e92e2e guibg=NONE gui=NONE
90 | hi javaScriptRailsFunction guifg=#e92e2e guibg=NONE gui=NONE
91 | hi javaScriptBraces guifg=NONE guibg=NONE gui=NONE
92 | hi yamlKey guifg=#606060 guibg=NONE gui=NONE
93 | hi yamlAnchor guifg=NONE guibg=NONE gui=NONE
94 | hi yamlAlias guifg=NONE guibg=NONE gui=NONE
95 | hi yamlDocumentHeader guifg=#5d90cd guibg=NONE gui=NONE
96 | hi cssURL guifg=NONE guibg=NONE gui=NONE
97 | hi cssFunctionName guifg=#e92e2e guibg=NONE gui=NONE
98 | hi cssColor guifg=#a165ac guibg=NONE gui=NONE
99 | hi cssPseudoClassId guifg=#606060 guibg=NONE gui=NONE
100 | hi cssClassName guifg=#e92e2e guibg=NONE gui=NONE
101 | hi cssValueLength guifg=#46a609 guibg=NONE gui=NONE
102 | hi cssCommonAttr guifg=#a165ac guibg=NONE gui=NONE
103 | hi cssBraces guifg=NONE guibg=NONE gui=NONE
104 |
--------------------------------------------------------------------------------
/iterm2/Wombat.itermcolors:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Ansi 0 Color
6 |
7 | Blue Component
8 | 0.0
9 | Green Component
10 | 0.0
11 | Red Component
12 | 0.0
13 |
14 | Ansi 1 Color
15 |
16 | Blue Component
17 | 0.35380584001541138
18 | Green Component
19 | 0.37975850701332092
20 | Red Component
21 | 1
22 |
23 | Ansi 10 Color
24 |
25 | Blue Component
26 | 0.56091833114624023
27 | Green Component
28 | 0.97338253259658813
29 | Red Component
30 | 0.86515980958938599
31 |
32 | Ansi 11 Color
33 |
34 | Blue Component
35 | 0.69898539781570435
36 | Green Component
37 | 0.89980232715606689
38 | Red Component
39 | 0.93448394536972046
40 |
41 | Ansi 12 Color
42 |
43 | Blue Component
44 | 1
45 | Green Component
46 | 0.78056418895721436
47 | Red Component
48 | 0.64889204502105713
49 |
50 | Ansi 13 Color
51 |
52 | Blue Component
53 | 1
54 | Green Component
55 | 0.66839390993118286
56 | Red Component
57 | 0.86788153648376465
58 |
59 | Ansi 14 Color
60 |
61 | Blue Component
62 | 0.97686588764190674
63 | Green Component
64 | 1
65 | Red Component
66 | 0.71730226278305054
67 |
68 | Ansi 15 Color
69 |
70 | Blue Component
71 | 0.99982929229736328
72 | Green Component
73 | 1
74 | Red Component
75 | 0.99987733364105225
76 |
77 | Ansi 2 Color
78 |
79 | Blue Component
80 | 0.41247016191482544
81 | Green Component
82 | 0.91209155321121216
83 | Red Component
84 | 0.69528472423553467
85 |
86 | Ansi 3 Color
87 |
88 | Blue Component
89 | 0.61240488290786743
90 | Green Component
91 | 0.84966868162155151
92 | Red Component
93 | 0.92030984163284302
94 |
95 | Ansi 4 Color
96 |
97 | Blue Component
98 | 0.96645122766494751
99 | Green Component
100 | 0.66428118944168091
101 | Red Component
102 | 0.36596208810806274
103 |
104 | Ansi 5 Color
105 |
106 | Blue Component
107 | 1
108 | Green Component
109 | 0.4175935685634613
110 | Red Component
111 | 0.91076451539993286
112 |
113 | Ansi 6 Color
114 |
115 | Blue Component
116 | 0.96741926670074463
117 | Green Component
118 | 1
119 | Red Component
120 | 0.51017588376998901
121 |
122 | Ansi 7 Color
123 |
124 | Blue Component
125 | 0.80998730659484863
126 | Green Component
127 | 0.85460180044174194
128 | Red Component
129 | 0.87252241373062134
130 |
131 | Ansi 8 Color
132 |
133 | Blue Component
134 | 0.19356094300746918
135 | Green Component
136 | 0.19360662996768951
137 | Red Component
138 | 0.19357019662857056
139 |
140 | Ansi 9 Color
141 |
142 | Blue Component
143 | 0.501872718334198
144 | Green Component
145 | 0.54845702648162842
146 | Red Component
147 | 0.96163845062255859
148 |
149 | Background Color
150 |
151 | Blue Component
152 | 0.09135911613702774
153 | Green Component
154 | 0.091378688812255859
155 | Red Component
156 | 0.091364338994026184
157 |
158 | Bold Color
159 |
160 | Blue Component
161 | 1
162 | Green Component
163 | 1
164 | Red Component
165 | 1
166 |
167 | Cursor Color
168 |
169 | Blue Component
170 | 0.73333334922790527
171 | Green Component
172 | 0.73333334922790527
173 | Red Component
174 | 0.73333334922790527
175 |
176 | Cursor Text Color
177 |
178 | Blue Component
179 | 1
180 | Green Component
181 | 1
182 | Red Component
183 | 1
184 |
185 | Foreground Color
186 |
187 | Blue Component
188 | 0.80998730659484863
189 | Green Component
190 | 0.85460180044174194
191 | Red Component
192 | 0.87252241373062134
193 |
194 | Selected Text Color
195 |
196 | Blue Component
197 | 0.7527463436126709
198 | Green Component
199 | 0.73378461599349976
200 | Red Component
201 | 0.7153552770614624
202 |
203 | Selection Color
204 |
205 | Blue Component
206 | 0.22383280098438263
207 | Green Component
208 | 0.23080787062644958
209 | Red Component
210 | 0.27125817537307739
211 |
212 |
213 |
214 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-prompt/docs/wiki/documentation/keywords/index.mdown:
--------------------------------------------------------------------------------
1 | Keywords
2 | ========
3 |
4 | There a number of keywords available. If you have any suggestions for more
5 | please [let me know][issues].
6 |
7 | [issues]: http://bitbucket.org/sjl/issues
8 |
9 | Some of the keywords support filters. These filters can be combined when it
10 | makes sense. If in doubt, try it!
11 |
12 | [TOC]
13 |
14 | ##bookmark##
15 | : Display the current bookmark (requires the [bookmarks][] extension).
16 |
17 | ##branch##
18 | : Display the current branch.
19 |
20 | |quiet
21 | : Display the current branch only if it is not the default branch.
22 |
23 | ##closed##
24 | : Display `X` if working on a closed branch (i.e. if committing now would
25 | reopen the branch).
26 |
27 | ##count##
28 | : Display the number of revisions in the given revset (the revset `all()`
29 | will be used if none is given).
30 |
31 | See `hg help revsets` for more information.
32 |
33 | |REVSET
34 | : The revset to count.
35 |
36 | ##incoming##
37 | : Display nothing, but if the default path contains incoming changesets the
38 | extra text will be expanded.
39 |
40 | For example: `{incoming changes{incoming}}` will expand to
41 | `incoming changes` if there are changes, otherwise nothing.
42 |
43 | Checking for incoming changesets is an expensive operation, so `hg-prompt`
44 | will cache the results in `.hg/prompt/cache/` and refresh them every 15
45 | minutes.
46 |
47 | |count
48 | : Display the number of incoming changesets (if greater than 0).
49 |
50 | ##node##
51 | : Display the (full) changeset hash of the current parent.
52 |
53 | |short
54 | : Display the hash as the short, 12-character form.
55 |
56 | |merge
57 | : Display the hash of the changeset you're merging with.
58 |
59 | ##outgoing##
60 | : Display nothing, but if the current repository contains outgoing
61 | changesets (to default) the extra text will be expanded.
62 |
63 | For example: `{outgoing changes{outgoing}}` will expand to
64 | `outgoing changes` if there are changes, otherwise nothing.
65 |
66 | Checking for outgoing changesets is an expensive operation, so `hg-prompt`
67 | will cache the results in `.hg/prompt/cache/` and refresh them every 15
68 | minutes.
69 |
70 | |count
71 | : Display the number of outgoing changesets (if greater than 0).
72 |
73 | ##patch##
74 | : Display the topmost currently-applied patch (requires the [mq][]
75 | extension).
76 |
77 | |count
78 | : Display the number of patches in the queue.
79 |
80 | |applied
81 | : Display the number of currently applied patches in the queue.
82 |
83 | |unapplied
84 | : Display the number of currently unapplied patches in the queue.
85 |
86 | |quiet
87 | : Display a number only if there are any patches in the queue.
88 |
89 | ##patches##
90 | : Display a list of the current patches in the queue. It will look like
91 | this:
92 |
93 | :::console
94 | $ hg prompt '{patches}'
95 | bottom-patch -> middle-patch -> top-patch
96 |
97 | |reverse
98 | : Display the patches in reverse order (i.e. topmost first).
99 |
100 | |hide_applied
101 | : Do not display applied patches.
102 |
103 | |hide_unapplied
104 | : Do not display unapplied patches.
105 |
106 | |join(SEP)
107 | : Display SEP between each patch, instead of the default ` -> `.
108 |
109 | |pre_applied(STRING)
110 | : Display STRING immediately before each applied patch. Useful for
111 | adding color codes.
112 |
113 | |post_applied(STRING)
114 | : Display STRING immediately after each applied patch. Useful for
115 | resetting color codes.
116 |
117 | |pre_unapplied(STRING)
118 | : Display STRING immediately before each unapplied patch. Useful for
119 | adding color codes.
120 |
121 | |post_unapplied(STRING)
122 | : Display STRING immediately after each unapplied patch. Useful for
123 | resetting color codes.
124 |
125 | ##queue##
126 | : Display the name of the current MQ queue.
127 |
128 | ##rev##
129 | : Display the repository-local changeset number of the current parent.
130 |
131 | |merge
132 | : Display the repository-local changeset number of the changeset you're
133 | merging with.
134 |
135 | ##root##
136 | : Display the full path to the root of the current repository, without a
137 | trailing slash.
138 |
139 | |basename
140 | : Display the directory name of the root of the current repository. For
141 | example, if the repository is in `/home/u/myrepo` then this keyword
142 | would expand to `myrepo`.
143 |
144 | ##status##
145 | : Display `!` if the repository has any changed/added/removed files,
146 | otherwise `?` if it has any untracked (but not ignored) files, otherwise
147 | nothing.
148 |
149 | |modified
150 | : Display `!` if the current repository contains files that have been
151 | modified, added, removed, or deleted, otherwise nothing.
152 |
153 | |unknown
154 | : Display `?` if the current repository contains untracked files,
155 | otherwise nothing.
156 |
157 | ##tags##
158 | : Display the tags of the current parent, separated by a space.
159 |
160 | |quiet
161 | Display the tags of the current parent, excluding the tag "tip".
162 |
163 | |SEP
164 | : Display the tags of the current parent, separated by `SEP`.
165 |
166 | ##task##
167 | : Display the current task (requires the [tasks][] extension).
168 |
169 | ##tip##
170 | : Display the repository-local changeset number of the current tip.
171 |
172 | |node
173 | : Display the (full) changeset hash of the current tip.
174 |
175 | |short
176 | : Display a short form of the changeset hash of the current tip (must be
177 | used with the **|node** filter)
178 |
179 | ##update##
180 | : Display `^` if the current parent is not the tip of the current branch,
181 | otherwise nothing. In effect, this lets you see if running `hg update`
182 | would do something.
183 |
184 | [bookmarks]: http://mercurial.selenic.com/wiki/BookmarksExtension
185 | [tasks]: http://bitbucket.org/alu/hgtasks/wiki/Home
186 | [mq]: http://mercurial.selenic.com/wiki/MqExtension
187 |
--------------------------------------------------------------------------------
/vim/vim.symlink/colors/liquidcarbon.vim:
--------------------------------------------------------------------------------
1 | " File: liquidcarbon.vim
2 | " Author: Jeet Sukumaran
3 | " Description: Vim color file
4 | " Last Modified: October 06, 2010
5 |
6 | " Initialization and Setup {{{1
7 | " ============================================================================
8 | set background=dark
9 | highlight clear
10 | if exists("syntax_on")
11 | syntax reset
12 | endif
13 | let colors_name = "liquidcarbon"
14 | " 1}}}
15 |
16 | " Normal Color {{{1
17 | " ============================================================================
18 | if exists("g:liquidcarbon_high_contrast") && g:liquidcarbon_high_contrast
19 | hi Normal guifg=#bdcdcd guibg=#202020
20 | hi CursorLine guifg=NONE guibg=#292929 gui=NONE
21 | hi ColorColumn guifg=NONE guibg=#292929
22 | else
23 | hi Normal guifg=#bdcdcd guibg=#303030
24 | hi CursorLine guifg=NONE guibg=#3a3a3a gui=NONE
25 | hi ColorColumn guifg=NONE guibg=#3a3a3a
26 | endif
27 |
28 | " 1}}}
29 |
30 | " Core Highlights {{{1
31 | " ============================================================================
32 | hi Cursor guifg=bg guibg=fg gui=NONE
33 | hi CursorIM guifg=bg guibg=fg gui=NONE
34 | hi lCursor guifg=bg guibg=fg gui=NONE
35 | hi DiffAdd guifg=#000000 guibg=#3cb371 gui=NONE
36 | hi DiffChange guifg=#000000 guibg=#4f94cd gui=NONE
37 | hi DiffDelete guifg=#000000 guibg=#8b3626 gui=NONE
38 | hi DiffText guifg=#000000 guibg=#8ee5ee gui=NONE
39 | hi Directory guifg=#1e90ff guibg=bg gui=NONE
40 | hi ErrorMsg guifg=#ff6a6a guibg=NONE gui=bold
41 | hi FoldColumn guifg=#68838b guibg=#4B4B4B gui=bold
42 | hi Folded guifg=#68838b guibg=#4B4B4B gui=NONE
43 | hi IncSearch guifg=#ffffff guibg=#ff4500 gui=bold
44 | hi LineNr guifg=#767676 guibg=#000000 gui=NONE
45 | hi MatchParen guifg=#fff000 guibg=#000000 gui=bold
46 | hi ModeMsg guifg=#000000 guibg=#00ff00 gui=bold
47 | hi MoreMsg guifg=#2e8b57 guibg=bg gui=bold
48 | hi NonText guifg=#9ac0cd guibg=bg gui=NONE
49 | hi Pmenu guifg=#0000ff guibg=#c0c8cf gui=bold
50 | hi PmenuSel guifg=#c0c8cf guibg=#0000ff gui=bold
51 | hi PmenuSbar guifg=#ffffff guibg=#c1cdc1 gui=NONE
52 | hi PmenuThumb guifg=#ffffff guibg=#838b83 gui=NONE
53 | hi Question guifg=#00ee00 guibg=NONE gui=bold
54 | hi Search guifg=#000000 guibg=#fff68f gui=bold
55 | hi SignColumn guifg=#ffffff guibg=#cdcdb4 gui=NONE
56 | hi SpecialKey guifg=#666666 guibg=NONE gui=NONE
57 | hi SpellBad guisp=#ee2c2c gui=undercurl
58 | hi SpellCap guisp=#0000ff gui=undercurl
59 | hi SpellLocal guisp=#008b8b gui=undercurl
60 | hi SpellRare guisp=#ff00ff gui=undercurl
61 | hi StatusLine guifg=#ddeeff guibg=#445566 gui=NONE
62 | hi StatusLineNC guifg=#999999 guibg=#445566 gui=italic
63 | hi TabLine guifg=fg guibg=#d3d3d3 gui=underline
64 | hi TabLineFill guifg=fg guibg=bg gui=reverse
65 | hi TabLineSel guifg=fg guibg=bg gui=bold
66 | hi Title guifg=#009acd guibg=bg gui=bold
67 | hi VertSplit guifg=#445566 guibg=#445566
68 | hi Visual guifg=#000000 guibg=#90ccff gui=NONE
69 | hi WarningMsg guifg=#ee9a00 guibg=bg gui=NONE
70 | hi WildMenu guifg=#000000 guibg=#87ceeb gui=NONE
71 | " 1}}}
72 |
73 | " Syntax {{{1
74 | " ============================================================================
75 |
76 | " General {{{2
77 | " -----------------------------------------------------------------------------
78 | hi Comment guifg=#809090 guibg=NONE gui=italic
79 | hi Constant guifg=#cdad00 guibg=NONE gui=NONE
80 | hi String guifg=#559b70 guibg=NONE gui=NONE
81 | hi Boolean guifg=#cd69c9 guibg=NONE gui=NONE
82 | hi Identifier guifg=#9f79ee guibg=NONE gui=NONE
83 | hi Function guifg=#92a5de guibg=NONE gui=NONE
84 | hi Statement guifg=#009acd guibg=NONE gui=NONE
85 | hi PreProc guifg=#009acd guibg=NONE gui=NONE
86 | hi Keyword guifg=#7ac5cd guibg=NONE gui=NONE
87 | hi Type guifg=#4169e1 guibg=NONE gui=NONE
88 | hi Special guifg=#7f9f44 guibg=NONE gui=NONE
89 | hi Ignore guifg=bg guibg=NONE gui=NONE
90 | hi Error guifg=#ff3030 guibg=NONE gui=underline
91 | hi Todo guifg=#ff88ee guibg=NONE gui=bold
92 | " 2}}}
93 |
94 | " Vim {{{2
95 | " -----------------------------------------------------------------------------
96 | hi VimError guifg=#ff0000 guibg=#000000 gui=bold
97 | hi VimCommentTitle guifg=#528b8b guibg=bg gui=bold,italic
98 | " 2}}}
99 |
100 | " QuickFix {{{2
101 | " -----------------------------------------------------------------------------
102 | hi qfFileName guifg=#607b8b guibg=NONE gui=italic
103 | hi qfLineNr guifg=#0088aa guibg=NONE gui=bold
104 | hi qfError guifg=#ff0000 guibg=NONE gui=bold
105 | " 2}}}
106 |
107 | " Python {{{2
108 | " -----------------------------------------------------------------------------
109 | hi pythonDecorator guifg=#cd8500 guibg=NONE gui=NONE
110 | hi link pythonDecoratorFunction pythonDecorator
111 | " 2}}}
112 |
113 | " Diff {{{2
114 | " -----------------------------------------------------------------------------
115 | hi diffOldFile guifg=#da70d6 guibg=NONE gui=italic
116 | hi diffNewFile guifg=#ffff00 guibg=NONE gui=italic
117 | hi diffFile guifg=#ffa500 guibg=NONE gui=italic
118 | hi diffLine guifg=#ff00ff guibg=NONE gui=italic
119 | hi link diffOnly Constant
120 | hi link diffIdentical Constant
121 | hi link diffDiffer Constant
122 | hi link diffBDiffer Constant
123 | hi link diffIsA Constant
124 | hi link diffNoEOL Constant
125 | hi link diffCommon Constant
126 | hi diffRemoved guifg=#cd5555 guibg=NONE gui=NONE
127 | hi diffChanged guifg=#4f94cd guibg=NONE gui=NONE
128 | hi diffAdded guifg=#00cd00 guibg=NONE gui=NONE
129 | hi link diffSubname diffLine
130 | hi link diffComment Comment
131 | " 2}}}
132 |
133 | " 1}}}
134 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/src/pbranch/export.rextile:
--------------------------------------------------------------------------------
1 |
2 | h1. Exporting Patches to Patch Queues (mq)
3 |
4 | <%= toc %>
5 |
6 | $ cd patches
7 |
8 |
9 | h2. Export to StdOut
10 |
11 | h3. Full Graph
12 |
13 | By default, @pexport@ lists all the diffs to stdout, base patches first:
14 |
15 | h5. hg pexport
16 |
17 | $ hg pexport
18 | # HG changeset patch
19 | # User john
20 | # Date 0 0
21 | a nifty patch
22 | _
23 | diff --git a/file-from-A b/file-from-A
24 | new file mode 100644
25 | --- /dev/null
26 | +++ b/file-from-A
27 | @@ -0,0 +1,2 @@
28 | +One
29 | +Later
30 | diff --git a/main-file-1 b/main-file-1
31 | --- a/main-file-1
32 | +++ b/main-file-1
33 | @@ -1,1 +1,1 @@
34 | -One
35 | +Eins
36 | _
37 | # HG changeset patch
38 | # User john
39 | # Date 0 0
40 | another patch
41 | _
42 | diff --git a/file-from-B b/file-from-B
43 | new file mode 100644
44 | --- /dev/null
45 | +++ b/file-from-B
46 | @@ -0,0 +1,1 @@
47 | +Two
48 | diff --git a/main-file-1 b/main-file-1
49 | --- a/main-file-1
50 | +++ b/main-file-1
51 | @@ -3,1 +3,1 @@
52 | -Two
53 | +Zwei
54 | _
55 | # HG changeset patch
56 | # User john
57 | # Date 0 0
58 | yet another patch
59 | _
60 | diff --git a/file-from-A b/file-from-A
61 | --- a/file-from-A
62 | +++ b/file-from-A
63 | @@ -2,1 +2,1 @@
64 | -Later
65 | +EvenLater
66 | diff --git a/file-from-C b/file-from-C
67 | new file mode 100644
68 | --- /dev/null
69 | +++ b/file-from-C
70 | @@ -0,0 +1,1 @@
71 | +Three
72 | diff --git a/main-file-1 b/main-file-1
73 | --- a/main-file-1
74 | +++ b/main-file-1
75 | @@ -5,1 +5,1 @@
76 | -Three
77 | +Drei
78 |
79 | h3. Partial Graph
80 |
81 | We can also export just patches plus their base patches:
82 |
83 | $ hg pexport --with-deps patchB
84 | # HG changeset patch
85 | # User john
86 | # Date 0 0
87 | a nifty patch
88 | _
89 | diff --git a/file-from-A b/file-from-A
90 | new file mode 100644
91 | --- /dev/null
92 | +++ b/file-from-A
93 | @@ -0,0 +1,2 @@
94 | +One
95 | +Later
96 | diff --git a/main-file-1 b/main-file-1
97 | --- a/main-file-1
98 | +++ b/main-file-1
99 | @@ -1,1 +1,1 @@
100 | -One
101 | +Eins
102 | _
103 | # HG changeset patch
104 | # User john
105 | # Date 0 0
106 | another patch
107 | _
108 | diff --git a/file-from-B b/file-from-B
109 | new file mode 100644
110 | --- /dev/null
111 | +++ b/file-from-B
112 | @@ -0,0 +1,1 @@
113 | +Two
114 | diff --git a/main-file-1 b/main-file-1
115 | --- a/main-file-1
116 | +++ b/main-file-1
117 | @@ -3,1 +3,1 @@
118 | -Two
119 | +Zwei
120 |
121 | h3. Individual Patches
122 |
123 | Finally, we can export individial patches in the order given:
124 |
125 | $ hg pexport patchC patchA
126 | # HG changeset patch
127 | # User john
128 | # Date 0 0
129 | yet another patch
130 | _
131 | diff --git a/file-from-A b/file-from-A
132 | --- a/file-from-A
133 | +++ b/file-from-A
134 | @@ -2,1 +2,1 @@
135 | -Later
136 | +EvenLater
137 | diff --git a/file-from-C b/file-from-C
138 | new file mode 100644
139 | --- /dev/null
140 | +++ b/file-from-C
141 | @@ -0,0 +1,1 @@
142 | +Three
143 | diff --git a/main-file-1 b/main-file-1
144 | --- a/main-file-1
145 | +++ b/main-file-1
146 | @@ -5,1 +5,1 @@
147 | -Three
148 | +Drei
149 | _
150 | # HG changeset patch
151 | # User john
152 | # Date 0 0
153 | a nifty patch
154 | _
155 | diff --git a/file-from-A b/file-from-A
156 | new file mode 100644
157 | --- /dev/null
158 | +++ b/file-from-A
159 | @@ -0,0 +1,2 @@
160 | +One
161 | +Later
162 | diff --git a/main-file-1 b/main-file-1
163 | --- a/main-file-1
164 | +++ b/main-file-1
165 | @@ -1,1 +1,1 @@
166 | -One
167 | +Eins
168 |
169 | h3. Specifying the Patch Graph
170 |
171 | By default, @pdiff@, @pexport@, and @pemail@ use the tip graph (@--tips@) to construct patch diffs. This means that for each patch branch _foo_, its patch diff is defined as the diff between the tip of branch _foo_ and the revision identified by the node id recorded in @.hgpatchinfo/foo.dep@ in _foo_'s tip (the last @pmerge@ in _foo_ put it there).
172 |
173 | $ hg pexport patchC
174 | # HG changeset patch
175 | # User john
176 | # Date 0 0
177 | yet another patch
178 | _
179 | diff --git a/file-from-A b/file-from-A
180 | --- a/file-from-A
181 | +++ b/file-from-A
182 | @@ -2,1 +2,1 @@
183 | -Later
184 | +EvenLater
185 | diff --git a/file-from-C b/file-from-C
186 | new file mode 100644
187 | --- /dev/null
188 | +++ b/file-from-C
189 | @@ -0,0 +1,1 @@
190 | +Three
191 | diff --git a/main-file-1 b/main-file-1
192 | --- a/main-file-1
193 | +++ b/main-file-1
194 | @@ -5,1 +5,1 @@
195 | -Three
196 | +Drei
197 |
198 | To see a patch or series precisely as it was at the time of a specific revision, use the @--rev@ option. However, this may mean that a patch is not defined, because the given revision might not have any @.dep@ files at all:
199 |
200 | $ hg pexport --rev default patchC
201 | abort: branch patchC is not in the patch graph (wrong --rev?)
202 |
203 |
204 | h2. Export to Patch Queues (mq)
205 |
206 | A more useful way to export patches is to write patch queues. Each patch gets its own file, and there's a series file listing the patches in the correct order (base patches first):
207 |
208 | h5. hg pexport --queue
209 |
210 | $ hg pexport --queue --ext .diff
211 |
212 | $ ls .hg/patches/
213 | patchA.diff
214 | patchB.diff
215 | patchC.diff
216 | series
217 |
218 | $ cat .hg/patches/series
219 | patchA.diff
220 | patchB.diff
221 | patchC.diff
222 |
223 | We can use this to reimport them using mq:
224 |
225 | $ cd ..
226 | $ hg clone main import
227 | updating to branch default
228 | 2 files updated, 0 files merged, 0 files removed, 0 files unresolved
229 | $ cd import
230 | $ cp -r ../patches/.hg/patches .hg/
231 |
232 | $ hg qseries
233 | patchA.diff
234 | patchB.diff
235 | patchC.diff
236 |
237 | $ hg qpush -a
238 | applying patchA.diff
239 | applying patchB.diff
240 | applying patchC.diff
241 | now at: patchC.diff
242 |
243 | $ hg log
244 | 3 : yet another patch - john
245 | 2 : another patch - john
246 | 1 : a nifty patch - john
247 | 0 : base - john
248 |
249 |
250 | h2. Export From Outside Of Repo
251 |
252 | Sometimes we wish to transfer patches from one repo to another, something like:
253 |
254 | hg -R pexport the-patch | hg import -
255 |
256 | So let's quickly test out-of-repo exports:
257 |
258 | $ cd ..
259 | $ hg -R patches pexport patchC
260 | # HG changeset patch
261 | # User john
262 | # Date 0 0
263 | yet another patch
264 | _
265 | diff --git a/file-from-A b/file-from-A
266 | --- a/file-from-A
267 | +++ b/file-from-A
268 | @@ -2,1 +2,1 @@
269 | -Later
270 | +EvenLater
271 | diff --git a/file-from-C b/file-from-C
272 | new file mode 100644
273 | --- /dev/null
274 | +++ b/file-from-C
275 | @@ -0,0 +1,1 @@
276 | +Three
277 | diff --git a/main-file-1 b/main-file-1
278 | --- a/main-file-1
279 | +++ b/main-file-1
280 | @@ -5,1 +5,1 @@
281 | -Three
282 | +Drei
283 | $ cd patches
284 |
285 |
--------------------------------------------------------------------------------
/vim/vim.symlink/doc/tags:
--------------------------------------------------------------------------------
1 | config/rails.vim rails.txt /*config\/rails.vim*
2 | g:loaded_rails rails.txt /*g:loaded_rails*
3 | g:rails_abbreviations rails.txt /*g:rails_abbreviations*
4 | g:rails_ctags_arguments rails.txt /*g:rails_ctags_arguments*
5 | g:rails_default_file rails.txt /*g:rails_default_file*
6 | g:rails_gnu_screen rails.txt /*g:rails_gnu_screen*
7 | g:rails_history_size rails.txt /*g:rails_history_size*
8 | g:rails_mappings rails.txt /*g:rails_mappings*
9 | g:rails_menu rails.txt /*g:rails_menu*
10 | g:rails_modelines rails.txt /*g:rails_modelines*
11 | g:rails_statusline rails.txt /*g:rails_statusline*
12 | g:rails_syntax rails.txt /*g:rails_syntax*
13 | g:rails_tabstop rails.txt /*g:rails_tabstop*
14 | g:rails_url rails.txt /*g:rails_url*
15 | macros/rails.vim rails.txt /*macros\/rails.vim*
16 | rails rails.txt /*rails*
17 | rails-'cfu' rails.txt /*rails-'cfu'*
18 | rails-'completefunc' rails.txt /*rails-'completefunc'*
19 | rails-'et' rails.txt /*rails-'et'*
20 | rails-'expandtab' rails.txt /*rails-'expandtab'*
21 | rails-'filetype' rails.txt /*rails-'filetype'*
22 | rails-'ft' rails.txt /*rails-'ft'*
23 | rails-'includeexpr' rails.txt /*rails-'includeexpr'*
24 | rails-'inex' rails.txt /*rails-'inex'*
25 | rails-'pa' rails.txt /*rails-'pa'*
26 | rails-'path' rails.txt /*rails-'path'*
27 | rails-'shiftwidth' rails.txt /*rails-'shiftwidth'*
28 | rails-'softtabstop' rails.txt /*rails-'softtabstop'*
29 | rails-'statusline' rails.txt /*rails-'statusline'*
30 | rails-'stl' rails.txt /*rails-'stl'*
31 | rails-'sts' rails.txt /*rails-'sts'*
32 | rails-'sua' rails.txt /*rails-'sua'*
33 | rails-'suffixesadd' rails.txt /*rails-'suffixesadd'*
34 | rails-'sw' rails.txt /*rails-'sw'*
35 | rails-:A rails.txt /*rails-:A*
36 | rails-:AD rails.txt /*rails-:AD*
37 | rails-:AE rails.txt /*rails-:AE*
38 | rails-:AS rails.txt /*rails-:AS*
39 | rails-:AT rails.txt /*rails-:AT*
40 | rails-:AV rails.txt /*rails-:AV*
41 | rails-:OpenURL rails.txt /*rails-:OpenURL*
42 | rails-:R rails.txt /*rails-:R*
43 | rails-:RD rails.txt /*rails-:RD*
44 | rails-:RE rails.txt /*rails-:RE*
45 | rails-:RS rails.txt /*rails-:RS*
46 | rails-:RT rails.txt /*rails-:RT*
47 | rails-:RV rails.txt /*rails-:RV*
48 | rails-:Rabbrev rails.txt /*rails-:Rabbrev*
49 | rails-:Rabbrev! rails.txt /*rails-:Rabbrev!*
50 | rails-:Rails rails.txt /*rails-:Rails*
51 | rails-:Rake rails.txt /*rails-:Rake*
52 | rails-:Rake! rails.txt /*rails-:Rake!*
53 | rails-:Rcd rails.txt /*rails-:Rcd*
54 | rails-:Rcommand rails.txt /*rails-:Rcommand*
55 | rails-:Rconsole rails.txt /*rails-:Rconsole*
56 | rails-:Rcontroller rails.txt /*rails-:Rcontroller*
57 | rails-:Rdbext rails.txt /*rails-:Rdbext*
58 | rails-:Rdestroy rails.txt /*rails-:Rdestroy*
59 | rails-:Rdoc rails.txt /*rails-:Rdoc*
60 | rails-:Rdoc! rails.txt /*rails-:Rdoc!*
61 | rails-:Redit rails.txt /*rails-:Redit*
62 | rails-:Renvironment rails.txt /*rails-:Renvironment*
63 | rails-:Rextract rails.txt /*rails-:Rextract*
64 | rails-:Rfind rails.txt /*rails-:Rfind*
65 | rails-:Rfixtures rails.txt /*rails-:Rfixtures*
66 | rails-:Rfunctionaltest rails.txt /*rails-:Rfunctionaltest*
67 | rails-:Rgenerate rails.txt /*rails-:Rgenerate*
68 | rails-:Rhelper rails.txt /*rails-:Rhelper*
69 | rails-:Rinitializer rails.txt /*rails-:Rinitializer*
70 | rails-:Rintegrationtest rails.txt /*rails-:Rintegrationtest*
71 | rails-:Rinvert rails.txt /*rails-:Rinvert*
72 | rails-:Rjavascript rails.txt /*rails-:Rjavascript*
73 | rails-:Rlayout rails.txt /*rails-:Rlayout*
74 | rails-:Rlcd rails.txt /*rails-:Rlcd*
75 | rails-:Rlib rails.txt /*rails-:Rlib*
76 | rails-:Rlocale rails.txt /*rails-:Rlocale*
77 | rails-:Rlog rails.txt /*rails-:Rlog*
78 | rails-:Rmailer rails.txt /*rails-:Rmailer*
79 | rails-:Rmetal rails.txt /*rails-:Rmetal*
80 | rails-:Rmigration rails.txt /*rails-:Rmigration*
81 | rails-:Rmodel rails.txt /*rails-:Rmodel*
82 | rails-:Rnavcommand rails.txt /*rails-:Rnavcommand*
83 | rails-:Robserver rails.txt /*rails-:Robserver*
84 | rails-:Rp rails.txt /*rails-:Rp*
85 | rails-:Rpartial rails.txt /*rails-:Rpartial*
86 | rails-:Rplugin rails.txt /*rails-:Rplugin*
87 | rails-:Rpp rails.txt /*rails-:Rpp*
88 | rails-:Rpreview rails.txt /*rails-:Rpreview*
89 | rails-:Rpreview! rails.txt /*rails-:Rpreview!*
90 | rails-:Rproject rails.txt /*rails-:Rproject*
91 | rails-:Rrefresh rails.txt /*rails-:Rrefresh*
92 | rails-:Rrefresh! rails.txt /*rails-:Rrefresh!*
93 | rails-:Rrunner rails.txt /*rails-:Rrunner*
94 | rails-:Rscript rails.txt /*rails-:Rscript*
95 | rails-:Rserver rails.txt /*rails-:Rserver*
96 | rails-:Rserver! rails.txt /*rails-:Rserver!*
97 | rails-:Rset rails.txt /*rails-:Rset*
98 | rails-:Rspec rails.txt /*rails-:Rspec*
99 | rails-:Rstylesheet rails.txt /*rails-:Rstylesheet*
100 | rails-:Rtags rails.txt /*rails-:Rtags*
101 | rails-:Rtask rails.txt /*rails-:Rtask*
102 | rails-:Rtree rails.txt /*rails-:Rtree*
103 | rails-:Runittest rails.txt /*rails-:Runittest*
104 | rails-:Rview rails.txt /*rails-:Rview*
105 | rails-:Ry rails.txt /*rails-:Ry*
106 | rails-:autocmd rails.txt /*rails-:autocmd*
107 | rails-abbreviations rails.txt /*rails-abbreviations*
108 | rails-abolish rails.txt /*rails-abolish*
109 | rails-about rails.txt /*rails-about*
110 | rails-alternate rails.txt /*rails-alternate*
111 | rails-alternate-related rails.txt /*rails-alternate-related*
112 | rails-autocommands rails.txt /*rails-autocommands*
113 | rails-commands rails.txt /*rails-commands*
114 | rails-configuration rails.txt /*rails-configuration*
115 | rails-configure-vim rails.txt /*rails-configure-vim*
116 | rails-cream rails.txt /*rails-cream*
117 | rails-custom-navigation rails.txt /*rails-custom-navigation*
118 | rails-dbext rails.txt /*rails-dbext*
119 | rails-gf rails.txt /*rails-gf*
120 | rails-global-settings rails.txt /*rails-global-settings*
121 | rails-install-plugin rails.txt /*rails-install-plugin*
122 | rails-installation rails.txt /*rails-installation*
123 | rails-integration rails.txt /*rails-integration*
124 | rails-introduction rails.txt /*rails-introduction*
125 | rails-license rails.txt /*rails-license*
126 | rails-menu rails.txt /*rails-menu*
127 | rails-migrations rails.txt /*rails-migrations*
128 | rails-modelines rails.txt /*rails-modelines*
129 | rails-navigation rails.txt /*rails-navigation*
130 | rails-options rails.txt /*rails-options*
131 | rails-partials rails.txt /*rails-partials*
132 | rails-plugin-author rails.txt /*rails-plugin-author*
133 | rails-rails-integration rails.txt /*rails-rails-integration*
134 | rails-rake rails.txt /*rails-rake*
135 | rails-rake-defaults rails.txt /*rails-rake-defaults*
136 | rails-refactoring rails.txt /*rails-refactoring*
137 | rails-related rails.txt /*rails-related*
138 | rails-rspec rails.txt /*rails-rspec*
139 | rails-screen rails.txt /*rails-screen*
140 | rails-scripts rails.txt /*rails-scripts*
141 | rails-snippets rails.txt /*rails-snippets*
142 | rails-surround rails.txt /*rails-surround*
143 | rails-syntax rails.txt /*rails-syntax*
144 | rails-syntax-assertions rails.txt /*rails-syntax-assertions*
145 | rails-syntax-classes rails.txt /*rails-syntax-classes*
146 | rails-syntax-keywords rails.txt /*rails-syntax-keywords*
147 | rails-syntax-strings rails.txt /*rails-syntax-strings*
148 | rails-syntax-yaml rails.txt /*rails-syntax-yaml*
149 | rails-tabs rails.txt /*rails-tabs*
150 | rails-template-types rails.txt /*rails-template-types*
151 | rails-type-navigation rails.txt /*rails-type-navigation*
152 | rails-vim-integration rails.txt /*rails-vim-integration*
153 | rails.txt rails.txt /*rails.txt*
154 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/crecord/crecord/crecord_core.py:
--------------------------------------------------------------------------------
1 | # crecord.py
2 | #
3 | # Copyright 2008 Mark Edgington
4 | #
5 | # This software may be used and distributed according to the terms of
6 | # the GNU General Public License, incorporated herein by reference.
7 | #
8 | # Much of this extension is based on Bryan O'Sullivan's record extension.
9 |
10 | '''text-gui based change selection during commit or qrefresh'''
11 | from mercurial.i18n import _
12 | from mercurial import cmdutil, hg, mdiff, patch
13 | from mercurial import util
14 | import cStringIO
15 | import errno
16 | import os
17 | import tempfile
18 |
19 | import crpatch
20 | import chunk_selector
21 |
22 | def dorecord(ui, repo, commitfunc, *pats, **opts):
23 | try:
24 | if not ui.interactive():
25 | raise util.Abort(_('running non-interactively, use commit instead'))
26 | except TypeError: # backwards compatibility with hg 1.1
27 | if not ui.interactive:
28 | raise util.Abort(_('running non-interactively, use commit instead'))
29 |
30 | def recordfunc(ui, repo, message, match, opts):
31 | """This is generic record driver.
32 |
33 | Its job is to interactively filter local changes, and accordingly
34 | prepare working dir into a state, where the job can be delegated to
35 | non-interactive commit command such as 'commit' or 'qrefresh'.
36 |
37 | After the actual job is done by non-interactive command, working dir
38 | state is restored to original.
39 |
40 | In the end we'll record interesting changes, and everything else will be
41 | left in place, so the user can continue his work.
42 | """
43 |
44 | merge = len(repo[None].parents()) > 1
45 | if merge:
46 | raise util.Abort(_('cannot partially commit a merge '
47 | '(use hg commit instead)'))
48 |
49 | changes = repo.status(match=match)[:3]
50 | diffopts = mdiff.diffopts(git=True, nodates=True)
51 | chunks = patch.diff(repo, changes=changes, opts=diffopts)
52 | fp = cStringIO.StringIO()
53 | fp.write(''.join(chunks))
54 | fp.seek(0)
55 |
56 | # 1. filter patch, so we have intending-to apply subset of it
57 | chunks = crpatch.filterpatch(opts,
58 | crpatch.parsepatch(changes, fp),
59 | chunk_selector.chunkselector, ui)
60 | del fp
61 |
62 | contenders = set()
63 | for h in chunks:
64 | try:
65 | contenders.update(set(h.files()))
66 | except AttributeError:
67 | pass
68 |
69 | changed = changes[0] + changes[1] + changes[2]
70 | newfiles = [f for f in changed if f in contenders]
71 |
72 | if not newfiles:
73 | ui.status(_('no changes to record\n'))
74 | return 0
75 |
76 | modified = set(changes[0])
77 |
78 | # 2. backup changed files, so we can restore them in the end
79 | backups = {}
80 | backupdir = repo.join('record-backups')
81 | try:
82 | os.mkdir(backupdir)
83 | except OSError, err:
84 | if err.errno != errno.EEXIST:
85 | raise
86 | try:
87 | # backup continues
88 | for f in newfiles:
89 | if f not in modified:
90 | continue
91 | fd, tmpname = tempfile.mkstemp(prefix=f.replace('/', '_')+'.',
92 | dir=backupdir)
93 | os.close(fd)
94 | ui.debug('backup %r as %r\n' % (f, tmpname))
95 | util.copyfile(repo.wjoin(f), tmpname)
96 | backups[f] = tmpname
97 |
98 | fp = cStringIO.StringIO()
99 | for c in chunks:
100 | if c.filename() in backups:
101 | c.write(fp)
102 | dopatch = fp.tell()
103 | fp.seek(0)
104 |
105 | # 2.5 optionally review / modify patch in text editor
106 | if opts['crecord_reviewpatch']:
107 | patchtext = fp.read()
108 | reviewedpatch = ui.edit(patchtext, "")
109 | fp.truncate(0)
110 | fp.write(reviewedpatch)
111 | fp.seek(0)
112 |
113 | # 3a. apply filtered patch to clean repo (clean)
114 | if backups:
115 | hg.revert(repo, repo.dirstate.parents()[0],
116 | lambda key: key in backups)
117 |
118 | # 3b. (apply)
119 | if dopatch:
120 | try:
121 | ui.debug('applying patch\n')
122 | ui.debug(fp.getvalue())
123 | if hasattr(patch, 'workingbackend'): # detect 1.9
124 | patch.internalpatch(ui, repo, fp, strip=1, eolmode=None)
125 | else:
126 | pfiles = {}
127 | try:
128 | patch.internalpatch(ui, repo, fp, 1, eolmode=None)
129 | except (TypeError, AttributeError): # pre 17cea10c343e
130 | try:
131 | patch.internalpatch(ui, repo, fp, 1, repo.root,
132 | eolmode=None)
133 | except (TypeError, AttributeError): # pre 00a881581400
134 | try:
135 | patch.internalpatch(fp, ui, 1, repo.root,
136 | files=pfiles, eolmode=None)
137 | except TypeError: # backwards compatible with hg 1.1
138 | patch.internalpatch(fp, ui, 1,
139 | repo.root, files=pfiles)
140 | try:
141 | cmdutil.updatedir(ui, repo, pfiles)
142 | except AttributeError:
143 | try:
144 | patch.updatedir(ui, repo, pfiles)
145 | except AttributeError:
146 | # from 00a881581400 onwards
147 | pass
148 | except patch.PatchError, err:
149 | s = str(err)
150 | if s:
151 | raise util.Abort(s)
152 | else:
153 | raise util.Abort(_('patch failed to apply'))
154 | del fp
155 |
156 | # 4. We prepared working directory according to filtered patch.
157 | # Now is the time to delegate the job to commit/qrefresh or the like!
158 |
159 | # it is important to first chdir to repo root -- we'll call a
160 | # highlevel command with list of pathnames relative to repo root
161 | cwd = os.getcwd()
162 | os.chdir(repo.root)
163 | try:
164 | commitfunc(ui, repo, *newfiles, **opts)
165 | finally:
166 | os.chdir(cwd)
167 |
168 | return 0
169 | finally:
170 | # 5. finally restore backed-up files
171 | try:
172 | for realname, tmpname in backups.iteritems():
173 | ui.debug('restoring %r to %r\n' % (tmpname, realname))
174 | util.copyfile(tmpname, repo.wjoin(realname))
175 | os.unlink(tmpname)
176 | os.rmdir(backupdir)
177 | except OSError:
178 | pass
179 | return cmdutil.commit(ui, repo, recordfunc, pats, opts)
180 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/src/style.css:
--------------------------------------------------------------------------------
1 | /* Colors used:
2 | (see http://www.somacon.com/p142.php)
3 | #8B0000 - darkred; for title-ish text and links
4 | #8B7765 - peachpuff4; for dimmed things like block quotes and navigation
5 | #EEE6D4 - ??; for 1px lines
6 | #FEF6E4 - warm shadow; for news background
7 | */
8 |
9 |
10 | /* Main stuff */
11 |
12 | h1, h2, h3, h4, h5 {
13 | color: #8B0000;
14 | font-family: Sans-Serif;
15 | }
16 |
17 | ul {
18 | list-style-type: square;
19 | padding-left: 1.5em;
20 | margin-left: 0;
21 | }
22 |
23 | ul.spaced > li {
24 | margin-bottom: 1ex;
25 | }
26 |
27 | pre
28 | {
29 | margin-left: 1.5em;
30 | padding: .5em;
31 | border: none;
32 | background: #EEE6D4;
33 | clear: right;
34 | }
35 |
36 | pre span.input {
37 | }
38 |
39 | pre span.output {
40 | color: #7B6755;
41 | }
42 |
43 | tt {
44 | font-style: italic;
45 | }
46 |
47 | a {
48 | color: #8B0000;
49 | font-style: normal;
50 | }
51 |
52 | a:visited {
53 | text-decoration: none;
54 | }
55 |
56 | a:hover {
57 | text-decoration: underline;
58 | }
59 |
60 | h2 > a:hover, h3 > a:hover, h4 > a:hover, h5 > a:hover {
61 | text-decoration: none;
62 | }
63 |
64 | td {
65 | vertical-align: top;
66 | }
67 |
68 | dt {
69 | margin-top: 1ex;
70 | font-style: italic;
71 | color: #8B0000;
72 | }
73 |
74 | blockquote {
75 | border-left: solid 1px #CDB7B5;
76 | color: #8B7765;
77 | font-style: italic;
78 | padding-left: 1em;
79 | margin-left: 0;
80 | margin-right: 0;
81 | }
82 |
83 |
84 | /* Main flow */
85 |
86 | div.all {
87 | margin-top: 1ex;
88 | margin-left: 20%;
89 | margin-right: 10%;
90 | max-width: 40em;
91 | }
92 |
93 |
94 | /* Photo */
95 |
96 | div.photo {
97 | float: right;
98 | }
99 |
100 |
101 | /* Breadcrumbs */
102 |
103 | div.nav {
104 | height: 4ex;
105 | font-size: x-small;
106 | text-transform: lowercase;
107 | color: #8B7765;
108 | font-family: Sans-Serif;
109 | }
110 |
111 | div.nav a {
112 | color: #8B7765;
113 | text-decoration: none;
114 | }
115 |
116 |
117 | div.nav a:hover, div.nav a:active {
118 | text-decoration: underline;
119 | }
120 |
121 |
122 | /* TOC */
123 |
124 | div.toc {
125 | border-left: solid 1px #EEE6D4;
126 | font-size: smaller;
127 | font-family: Sans-Serif;
128 | color: #8B7765;
129 | }
130 |
131 | div.toc > ul {
132 | list-style-type: none;
133 | padding-left: 1em;
134 | margin-left: 0;
135 | }
136 |
137 | div.toc > ul > li {
138 | margin-bottom: 0.3ex;
139 | }
140 |
141 | div.toc li.withitems {
142 | margin-bottom: 0.5ex;
143 | }
144 |
145 | ul.toc ul {
146 | font-size: x-small;
147 | margin-left: 0;
148 | }
149 |
150 | ul.toc a {
151 | color: #8B7765;
152 | text-decoration: none;
153 | }
154 |
155 | ul.toc a:hover, ul.toc a:active {
156 | text-decoration: underline;
157 | }
158 |
159 |
160 | /* Document title */
161 |
162 | h1 {
163 | font-size: x-large;
164 | font-weight: normal;
165 | margin-bottom: 1.5ex;
166 | padding-top: 0;
167 | padding-bottom: 0;
168 | border-bottom: solid 1px #EEE6D4
169 | }
170 |
171 | .nofirefox {
172 | font-size: x-small;
173 | color: red;
174 | float: right;
175 | width: 10em;
176 | }
177 |
178 | div > p.nofirefox {
179 | display: none;
180 | }
181 |
182 |
183 | /* Strong headings */
184 |
185 | div.content h2, div.content h3 {
186 | font-weight: normal;
187 | }
188 |
189 | div.content h2 {
190 | margin-top: .3em;
191 | margin-left: -10em;
192 | width: 10em;
193 | /*white-space: nowrap;
194 | overflow: visible;*/
195 | border-bottom: solid 1px #EEE6D4;
196 | font-size: large;
197 | }
198 |
199 | div.content h3 {
200 | margin-top: 1.5em;
201 | font-style: italic;
202 | }
203 |
204 | p.startofcontent + h2, p.startofcontent + h3 {
205 | display: none;
206 | }
207 |
208 |
209 | /* Margin headings */
210 |
211 | div.content h4, div.content h5 {
212 | margin-left: -5em;
213 | float: left;
214 | width: 9em;
215 | overflow: hidden;
216 | margin-top: 0;
217 | font-size: small;
218 | font-weight: normal;
219 | font-style: italic;
220 | text-align: right;
221 | }
222 |
223 | div.content > h4, div.content > h5 {
224 | margin-left: -9em;
225 | width: 8em;
226 | }
227 |
228 | div.content h4 {
229 | font-weight: bold;
230 | }
231 |
232 |
233 | /* Footer */
234 |
235 | div.footer {
236 | margin-top: 3em;
237 | border-top: solid 1px #EEE6D4;
238 | color: #8B7765;
239 | font-size: x-small;
240 | font-family: Sans-Serif;
241 | }
242 |
243 | div.footer p {
244 | margin-top: .5em;
245 | }
246 |
247 |
248 | /* News */
249 |
250 | div.news {
251 | float: right;
252 | width: 12em;
253 | margin-left: 1em;
254 | margin-bottom: 1em;
255 | padding-left: 1em;
256 | padding-right: 1em;
257 | background: #FEF6E4;
258 | }
259 |
260 | div.news h2, div.news h3 {
261 | margin-left: auto;
262 | float: none;
263 | width: auto;
264 | margin-top: auto;
265 | font-size: medium;
266 | text-align: left;
267 | }
268 |
269 | div.news h2 {
270 | margin-top: 0;
271 | font-size: medium;
272 | font-weight: normal;
273 | display: none;
274 | }
275 |
276 | div.news h3 {
277 | }
278 |
279 |
280 | /* General */
281 |
282 | .when {
283 | font-size: x-small;
284 | font-style: italic;
285 | }
286 |
287 | .printonly {
288 | display: none;
289 | }
290 |
291 |
292 | /* Java */
293 |
294 | span.j-bkg /* background */ {
295 | }
296 |
297 | span.j-lin /* line numbers */ {
298 | }
299 |
300 | span.j-blk /* block comment */ {
301 | color: green;
302 | font-style: italic;
303 | }
304 |
305 | span.j-cmt /* line comment */ {
306 | color: green;
307 | font-style: italic;
308 | }
309 |
310 | span.j-key /* keyword */ {
311 | /* font-weight:bold; */
312 | color: maroon;
313 | }
314 |
315 | span.j-str /* string constants */ {
316 | color: blue;
317 | }
318 |
319 | span.j-chr /* char constants */ {
320 | color: blue;
321 | }
322 |
323 | span.j-num /* number constants */ {
324 | }
325 |
326 | span.j-sym /* symbols, punctuation */ {
327 | }
328 |
329 | span.j-typ /* primitive types */ {
330 | color: maroon;
331 | }
332 |
333 | span.j-def /* default; all the rest */ {
334 | }
335 |
336 | span.j-jdoc /* javadoc */ {
337 | color: steelblue;
338 | }
339 |
340 | span.j-jdoc-key /* javadoc keyword */ {
341 | color: steelblue;
342 | font-weight: bold;
343 | }
344 |
345 | span.j-jdoc-html /* javadoc html tag */ {
346 | color: steelblue;
347 | font-style: italic;
348 | }
349 |
350 | span.j-jdoc-link /* javadoc link */ {
351 | color: steelblue;
352 | font-style: italic;
353 | }
354 |
355 | span.j-undef /* undefined */ {
356 | }
357 |
358 | span.j-hl /* highlight */ {
359 | text-decoration: none;
360 | background-color: #FFFFB0;
361 | }
362 |
363 | /******************** Excel */
364 |
365 | table.xl {
366 | border-collapse:collapse;
367 | }
368 |
369 | table.xl td {
370 | border: solid 1px lightgray;
371 | text-align: left;
372 | vertical-align: top;
373 | }
374 |
375 | table.xl td.xl-row, table.xl thead td {
376 | background-color: #ECECEC;
377 | border-color: gray;
378 | text-align: center;
379 | padding-left: 2px;
380 | padding-right: 2px;
381 | }
382 |
383 | table.xl td.xl-num, table.xl td.xl-date {
384 | text-align: right;
385 | }
386 |
387 | span.xl-exp {
388 | font-size: x-small;
389 | font-family: monospace;
390 | color: maroon;
391 | }
392 |
393 | span.xl-name {
394 | font-size: x-small;
395 | font-style: italic;
396 | color: #6495ED;
397 | }
398 |
399 | td.xl-r1, span.xl-r1 {
400 | background-color: #E0FFFF;
401 | }
402 |
403 | td.xl-r2, span.xl-r2 {
404 | background-color: #FFE0FF;
405 | }
406 |
407 | td.xl-r3, span.xl-r3 {
408 | background-color: #FFFFE0;
409 | }
410 |
411 | td.xl-r4, span.xl-r4 {
412 | background-color: #E0FFE0;
413 | }
414 |
415 | td.xl-r5, span.xl-r5 {
416 | background-color: #E0E0FF;
417 | }
418 |
--------------------------------------------------------------------------------
/hg/hgext.symlink/hg-pbranch/tut/src/pbranch/email.rextile:
--------------------------------------------------------------------------------
1 |
2 | h1. Submitting Patches by Email
3 |
4 | <%= toc %>
5 |
6 |
7 | h2. Email a Single Patch
8 |
9 | When a patch is ready for submission, we can send it on by email with ease. This is basically the same as the patchbomb extension (@hg email@), but for patch branches. In this script I don't actually send the email, so I specify the @--test@ option:
10 |
11 | $ cd patches
12 |
13 | h5. hg pemail
14 |
15 | $ hg pemail --test --from john@example.com --to jane@example.com patchA
16 | This patch series consists of 1 patches.
17 | _
18 | Cc:
19 | _
20 | Displaying [PATCH] a nifty patch ...
21 | Content-Type: text/plain; charset="us-ascii"
22 | MIME-Version: 1.0
23 | Content-Transfer-Encoding: 7bit
24 | Subject: [PATCH] a nifty patch
25 | X-Mercurial-Node:
26 | Message-Id:
27 | User-Agent: Mercurial-patchbomb/6ba851a24b10+20090703
28 | Date: Fri, 03 Jul 2009 10:27:23 -0000
29 | From: john@example.com
30 | To: jane@example.com
31 | _
32 | # HG changeset patch
33 | # User john
34 | # Date 0 0
35 | a nifty patch
36 | _
37 | diff --git a/file-from-A b/file-from-A
38 | new file mode 100644
39 | --- /dev/null
40 | +++ b/file-from-A
41 | @@ -0,0 +1,2 @@
42 | +One
43 | +Later
44 | diff --git a/main-file-1 b/main-file-1
45 | --- a/main-file-1
46 | +++ b/main-file-1
47 | @@ -1,1 +1,1 @@
48 | -One
49 | +Eins
50 |
51 |
52 | h2. Email Multiple Patches
53 |
54 | When sending multiple patches, we need a subject and body for the introductory message for the series. This adds more clutter to the @pemail@ command. To highlight the relevant parts of the command in the following samples, I have factored out the mail formatting and addressing options:
55 |
56 | $ cat >maildesc <<-eof
57 | This is the patch series description.
58 | eof
59 | $ cat >mailopts <<-eof
60 | --test --from john@example.com --to jane@example.com --subject "Intro" --desc maildesc
61 | eof
62 |
63 | h3. Patch Series
64 |
65 | To send a patch series, we can specify just the head patches in the patch graph. Then pbranch will email them and all their dependencies in topological order, meaning base patches are sent before dependent patches:
66 |
67 | h5. hg pemail --with-deps
68 |
69 | $ hg pemail $(cat mailopts) --with-deps patchB
70 | This patch series consists of 2 patches.
71 | _
72 | Cc:
73 | _
74 | Displaying [PATCH 0 of 2] "Intro" ...
75 | Content-Type: text/plain; charset="us-ascii"
76 | MIME-Version: 1.0
77 | Content-Transfer-Encoding: 7bit
78 | Subject: [PATCH 0 of 2] "Intro"
79 | Message-Id:
80 | User-Agent: Mercurial-patchbomb/6ba851a24b10+20090703
81 | Date: Fri, 03 Jul 2009 10:27:23 -0000
82 | From: john@example.com
83 | To: jane@example.com
84 | _
85 | This is the patch series description.
86 | _
87 | Displaying [PATCH 1 of 2] a nifty patch ...
88 | Content-Type: text/plain; charset="us-ascii"
89 | MIME-Version: 1.0
90 | Content-Transfer-Encoding: 7bit
91 | Subject: [PATCH 1 of 2] a nifty patch
92 | X-Mercurial-Node:
93 | Message-Id:
94 | In-Reply-To:
95 | References:
96 | User-Agent: Mercurial-patchbomb/6ba851a24b10+20090703
97 | Date: Fri, 03 Jul 2009 10:27:24 -0000
98 | From: john@example.com
99 | To: jane@example.com
100 | _
101 | # HG changeset patch
102 | # User john
103 | # Date 0 0
104 | a nifty patch
105 | _
106 | diff --git a/file-from-A b/file-from-A
107 | new file mode 100644
108 | --- /dev/null
109 | +++ b/file-from-A
110 | @@ -0,0 +1,2 @@
111 | +One
112 | +Later
113 | diff --git a/main-file-1 b/main-file-1
114 | --- a/main-file-1
115 | +++ b/main-file-1
116 | @@ -1,1 +1,1 @@
117 | -One
118 | +Eins
119 | Displaying [PATCH 2 of 2] another patch ...
120 | Content-Type: text/plain; charset="us-ascii"
121 | MIME-Version: 1.0
122 | Content-Transfer-Encoding: 7bit
123 | Subject: [PATCH 2 of 2] another patch
124 | X-Mercurial-Node:
125 | Message-Id:
126 | In-Reply-To:
127 | References:
128 | User-Agent: Mercurial-patchbomb/6ba851a24b10+20090703
129 | Date: Fri, 03 Jul 2009 10:27:25 -0000
130 | From: john@example.com
131 | To: jane@example.com
132 | _
133 | # HG changeset patch
134 | # User john
135 | # Date 0 0
136 | another patch
137 | _
138 | diff --git a/file-from-B b/file-from-B
139 | new file mode 100644
140 | --- /dev/null
141 | +++ b/file-from-B
142 | @@ -0,0 +1,1 @@
143 | +Two
144 | diff --git a/main-file-1 b/main-file-1
145 | --- a/main-file-1
146 | +++ b/main-file-1
147 | @@ -3,1 +3,1 @@
148 | -Two
149 | +Zwei
150 |
151 | h3. Specified Patches In Specified Order
152 |
153 | Finally, we can send multiple patches in arbitrary order by naming them all explicitly:
154 |
155 | $ hg pemail $(cat mailopts) patchA patchB patchC
156 | This patch series consists of 3 patches.
157 | _
158 | Cc:
159 | _
160 | Displaying [PATCH 0 of 3] "Intro" ...
161 | Content-Type: text/plain; charset="us-ascii"
162 | MIME-Version: 1.0
163 | Content-Transfer-Encoding: 7bit
164 | Subject: [PATCH 0 of 3] "Intro"
165 | Message-Id:
166 | User-Agent: Mercurial-patchbomb/6ba851a24b10+20090703
167 | Date: Fri, 03 Jul 2009 10:27:23 -0000
168 | From: john@example.com
169 | To: jane@example.com
170 | _
171 | This is the patch series description.
172 | _
173 | Displaying [PATCH 1 of 3] a nifty patch ...
174 | Content-Type: text/plain; charset="us-ascii"
175 | MIME-Version: 1.0
176 | Content-Transfer-Encoding: 7bit
177 | Subject: [PATCH 1 of 3] a nifty patch
178 | X-Mercurial-Node:
179 | Message-Id:
180 | In-Reply-To:
181 | References:
182 | User-Agent: Mercurial-patchbomb/6ba851a24b10+20090703
183 | Date: Fri, 03 Jul 2009 10:27:24 -0000
184 | From: john@example.com
185 | To: jane@example.com
186 | _
187 | # HG changeset patch
188 | # User john
189 | # Date 0 0
190 | a nifty patch
191 | _
192 | diff --git a/file-from-A b/file-from-A
193 | new file mode 100644
194 | --- /dev/null
195 | +++ b/file-from-A
196 | @@ -0,0 +1,2 @@
197 | +One
198 | +Later
199 | diff --git a/main-file-1 b/main-file-1
200 | --- a/main-file-1
201 | +++ b/main-file-1
202 | @@ -1,1 +1,1 @@
203 | -One
204 | +Eins
205 | Displaying [PATCH 2 of 3] another patch ...
206 | Content-Type: text/plain; charset="us-ascii"
207 | MIME-Version: 1.0
208 | Content-Transfer-Encoding: 7bit
209 | Subject: [PATCH 2 of 3] another patch
210 | X-Mercurial-Node:
211 | Message-Id:
212 | In-Reply-To:
213 | References:
214 | User-Agent: Mercurial-patchbomb/6ba851a24b10+20090703
215 | Date: Fri, 03 Jul 2009 10:27:25 -0000
216 | From: john@example.com
217 | To: jane@example.com
218 | _
219 | # HG changeset patch
220 | # User john
221 | # Date 0 0
222 | another patch
223 | _
224 | diff --git a/file-from-B b/file-from-B
225 | new file mode 100644
226 | --- /dev/null
227 | +++ b/file-from-B
228 | @@ -0,0 +1,1 @@
229 | +Two
230 | diff --git a/main-file-1 b/main-file-1
231 | --- a/main-file-1
232 | +++ b/main-file-1
233 | @@ -3,1 +3,1 @@
234 | -Two
235 | +Zwei
236 | Displaying [PATCH 3 of 3] yet another patch ...
237 | Content-Type: text/plain; charset="us-ascii"
238 | MIME-Version: 1.0
239 | Content-Transfer-Encoding: 7bit
240 | Subject: [PATCH 3 of 3] yet another patch
241 | X-Mercurial-Node:
242 | Message-Id:
243 | In-Reply-To:
244 | References:
245 | User-Agent: Mercurial-patchbomb/6ba851a24b10+20090703
246 | Date: Fri, 03 Jul 2009 10:27:26 -0000
247 | From: john@example.com
248 | To: jane@example.com
249 | _
250 | # HG changeset patch
251 | # User john
252 | # Date 0 0
253 | yet another patch
254 | _
255 | diff --git a/file-from-A b/file-from-A
256 | --- a/file-from-A
257 | +++ b/file-from-A
258 | @@ -2,1 +2,1 @@
259 | -Later
260 | +EvenLater
261 | diff --git a/file-from-C b/file-from-C
262 | new file mode 100644
263 | --- /dev/null
264 | +++ b/file-from-C
265 | @@ -0,0 +1,1 @@
266 | +Three
267 | diff --git a/main-file-1 b/main-file-1
268 | --- a/main-file-1
269 | +++ b/main-file-1
270 | @@ -5,1 +5,1 @@
271 | -Three
272 | +Drei
273 |
274 |
275 |
--------------------------------------------------------------------------------