Using the `commit.template` setting, read in a commit message template
for each commit. This template is commented out so the commit message
author doesn't need to delete it.
The template serves as a reminder on how to write a better commit
message. The bullets are taken from Caleb's blog post[1]. There is no
_problem_ per se -- we are writing good messages these days -- but it's
handy to be reminded of things to think about. For example, people often
forget to note whether there are any side effects.
This message does not show on `git commit --amend`, only normal `git
commit`.
[1] http://bit.ly/13HWyiy
It is a common practice to store environment variables in a .env file in
development. This file is read by tools such as foreman and dotenv. This
file can contain sensitive information such as secret keys and should
always be excluded from version control
* Automatically :write before commands such as `:next` or `:!`
* Saves keystrokes by eliminating writes before running tests, etc
* See `:help 'autowrite'` for more information
It gets very annoying to manually force CtrlP to re-index every time I
add a new file. Since ag is so fast, we can turn off caching when it
powers CtrlP without any noticeable impact on search speed.
Newer versions of vim (such as 7.3.923) syntax highlight Rackup and JSON
files correctly. In the interest of keeping the dotfiles slim and our
machines up-to-date, I think the solution is to remove these from
dotfiles and install a newer version of vim in thoughtbot/laptop:
https://github.com/thoughtbot/laptop/pull/118
* Syntax highlight `Appraisals` as Ruby. Used especially for our open
source libraries.
* Syntax highlight rackup (`config.ru`) files as Ruby. Used in all our
Ruby web apps. Rails apps are rarely touched but some of the Sinatra
and Middleman apps are occasionally edited.
* Syntax highlight JSON files as JavaScript. Used in our Trail Map.
* sass gets compiled to `tmp/sass-cache` with Rails
* vendor/bundle_gems seems like an arbitrary vendor directory
* vim/.netrwhist is for a plugin we no longer use
* haml, html and markdown highlight still work without these plugins
* treetop and textile are likely very situational
* unsure if anyone is using greplace
Follows the pattern of:
* ~/.aliases.local in ce7ad49
* ~/.gitconfig.local in 8e141fe
* ~/.vimrc.local in a666267
Use consistent:
* `source`ing style.
* commenting style.
I am using ~/.zshrc.local as a home for `eval "$(rbenv init -)"`.
* Bash users experience errors when using the double-escaped spaces for the CtrlP-SilverSearcher integration.
Thanks to @adamyonk for raising this issue
When logging into a new shell, users see a banner such as:
Last login: Sun Jun 23 11:41:42 on ttys007
Adding an empty ~/.hushlogin file turns that banner off:
http://kb.iu.edu/data/acdd.html
* Use `ag` as the find method for listing files in CtrlP Vim plugin
* ag indexes and searches far faster than the native engine
* ag also respects .gitignore files on on a per-directory basis, avoiding duplication
This is Mac OS X-specific. Including this line in the dotfiles causes
`tmux` and `tmux new -s new-session` to break with `[exited]`.
I personally don't do copy-pasteable work inside tmux anymore.
I'm sure this is valuable to some of the thoughtbot vim users but I'm
thinking it better belongs above `DO NOT EDIT BELOW THIS LINE` as custom
configuration for those users.
It's not very useful to be dropped into the middle of your diff when
opening a new commit. This change prevents cursor position from being
restored for the `gitcommit` filetype.
I've had this in [my own dotfiles] for a while now, and really like
having the separation of what I consider to be code/configuration from
what to me feels more like a Gemfile, in that it lists out all of the
external dependencies in a single place.
[my own dotfiles](https://github.com/calebthompson/dotfiles/blob/master/vim/vimrc.bundles.symlink)
* Awesomer vundle integration:
* Refactor .vimrc and .vimrc.bundles to support standalone
BundleInstall.
* Install vim bundles as part of install.sh without sourcing the
normal vimrc, which prevents error messages from uninstalled
plugins referenced in the main vimrc.
dotfiles[master]/
↪ git submodule init
No submodule mapping found in .gitmodules for path 'vim/bundle/ctags.vim'
Git requires a `.gitmodules` file for submodules, but these aren’t
needed as `vundle` handles finding and cloning vim plugins.
There’s also not really any benefit to locking down a version as vim
plugins don’t have a standardized versioning system. Many don’t have
version numbers at all.
I've added a `.gitkeep` file, which is something I generally don’t like
having, but we need to have the directory around for vundle. I’d be up
for removing that and creating the directory in `install.sh`. Thoughts?
* Fixes an issue where tab completing specs that start with the same
words(s) makes tab completion freak out and stop working.
* The con is that we'll see "_spec.rb" in the output, like:
```zsh
$ rspec spec/models/
models/calendar_spec.rb
models/event_closer_spec.rb
...
```
vim-ruby is where Vim's support for Ruby comes from - file type
detection, syntax highlighting, etc. Vim bundles vim-ruby, but the
GitHub project is always ahead of what's released with Vim.
@jferris:
This has the effect that Git will never implicitly do a merge commit,
including while doing git pull. If I'm unexpectedly out of sync when I
git pull, I get this message:
> fatal: Not possible to fast-forward, aborting.
At that point, I know that I've forgotten to do something in my normal
workflow, and I retrace my steps.
@gylaz:
I like the value of seeing a failure message if a pull (or just merge)
fails due to not being able to get fast-forwarded. Then I can look to
see whose changes went out, that I may have not expected to be there.