Skip to content

iwataka/gitignore.vim

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gitignore.vim

Git is now must-have version control system and you write .gitignore files when using it. Sometimes they become large and complicated, but GitHub provides the official collection of .gitignore templates in https://github.com/github/gitignore, so why don't you use them?

You can use them in Vim with great ease.

Usage

  • :Gitignore [Foo...]

    This adds the patterns for Foo filetype to .gitignore in the project root.

  • :Gitignore! [Foo...]

    This is almost the same as the above, but discard the existing .gitignore content before.

  • :GitignoreUpdate

    This updates the .gitignore template collection in g:gitignore_dir.

Installation

This can be installed by using any plugin-managers like Vundle.vim, but if you don't have your favorite one, I recommend vim-plug.

Install it and write the below line in your .vimrc:

Plug 'iwataka/gitignore.vim'

For other plugin-managers, please see their own documents.

Configuration

  • g:gitignore_dir (default value: ~/.gitignore-boilerplates)

    This specify the directory which contains the .gitignore template collection. By default, this uses the same directory as gibo, which means no additional downloading even if using gibo.

  • g:gitignore_enable_shallow_clone (default value: 1)

    If this value is non-zero, this plug-in uses shallow-clone.

Additional features

  • You'll see no duplicated patterns even if running Gitignore Foo twice!

Related projects

About

Gitignore utility for Vim

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published