Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ar1hur/gitkeep
A gem which creates .gitkeep files in all empty directories in your project automatically
https://github.com/ar1hur/gitkeep
Last synced: about 2 months ago
JSON representation
A gem which creates .gitkeep files in all empty directories in your project automatically
- Host: GitHub
- URL: https://github.com/ar1hur/gitkeep
- Owner: ar1hur
- Created: 2012-08-17T09:14:08.000Z (about 12 years ago)
- Default Branch: master
- Last Pushed: 2013-05-21T19:33:21.000Z (over 11 years ago)
- Last Synced: 2024-07-18T07:10:35.230Z (2 months ago)
- Language: Ruby
- Homepage:
- Size: 180 KB
- Stars: 23
- Watchers: 4
- Forks: 3
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
[![Build Status](https://travis-ci.org/ar1hur/gitkeep.png?branch=master)](https://travis-ci.org/ar1hur/gitkeep)
#gitkeep (ruby >= 1.9.3 required)
=======People who want to track empty directories in git, have created the convention of putting files called “.gitkeep” in these directories.
Because git is not able to track empty directories.
For lazy people (like myself) i have developed this tiny gem which creates .gitkeep files automatically!##changelog
0.3.2
- added autoclean method to remove not needed .gitkeep files - THX to Scott(!)
- refactored rspec test0.2.4
- added -h option to show possible options0.2.3
- added -a option to execute git add for adding directories which have a .gitkeep file in there0.2.2
- added rspec test
- added interactive mode
- counting errors
- refactored code0.2.1
- added checks for read/write permissions
- added a counter to show how many files were created
0.2.0
- first release##usage
``` shell
# current path
$ gitkeep# with specified path
$ gitkeep /var/www/myproject# dryrun -> doesn't create any files, but you will see in which places gitkeep would create files
$ gitkeep -d
# or
$ gitkeep -d some/path# interactive mode - ask you everytime when gitkeep wants to create a file
$ gitkeep -i# after creating .gitkeep files you can add these automatically with -a option to your git index
$ gitkeep -a# removes unneeded .gitkeep files
$ gitkeep -ac# removes unneeded .gitkeep files, also from your git index
$ gitkeep -acr
```##installation
see [https://rubygems.org/gems/gitkeep](https://rubygems.org/gems/gitkeep "Title")