Closed MafcoCinco closed 11 years ago
I took a look at gitignore and it seems better suited for generating your global ~/.gitignore
file. Ore already defines ignore patterns in each of it's templates.
These patterns are then added to the resulting .gitignore or .hgignore files.
I'm afraid I'll have to pass on this feature. :/
No worries. That makes sense. Thanks for checking it out.
On Monday, October 8, 2012, Postmodern wrote:
I took a look at gitignore https://github.com/github/gitignore and it seems better suited for generating your global ~/.gitignore file. Ore already defines ignore patterns in each of it's templates.
- bundlerhttps://github.com/ruby-ore/ore/blob/master/data/ore/templates/bundler/template.yml#L1-3
- rdochttps://github.com/ruby-ore/ore/blob/master/data/ore/templates/rdoc/template.yml#L4-5
- yardhttps://github.com/ruby-ore/ore/blob/master/data/ore/templates/yard/template.yml#L4-5
These patterns are then added to the resulting .gitignorehttps://github.com/ruby-ore/ore/blob/master/data/ore/templates/git/.gitignore.erbor .hgignorehttps://github.com/ruby-ore/ore/blob/master/data/ore/templates/hg/.hgignore.erbfiles.
I'm afraid I'll have to pass on this feature. :/
— Reply to this email directly or view it on GitHubhttps://github.com/ruby-ore/ore/pull/28#issuecomment-9244485.
Description
Added CLI option to specify parameters to the gitignore gem. If this option is specified and the gitignore gem is installed,
ore
will invokegitignore
with specified options to update the.gitignore
file. The update happens as an append so previously ignored files and directories will not be overwritten.If the option is specified and the gitignore gem is not installed,
ore
will display a red message informing the user and indicating how to get the gitignore gem.Usage Examples
If you are developing a Ruby app/gem on OS X using Emacs, you might specify something like this:
The
.gitignore
file will contain the results fromgitignore
's templates for Ruby, OS X and Emacs.If
gitignore
is not installed, the user will see the following outputQuestions
Provided this is something that you would be interested in adding to
ore
, there is one open question I had. Given that Ruby will always be the language if the user is usingore
, shouldgitignore
automatically be invoked with the Ruby option, even when--gitignore
is not specified? This seems to make sense in a narrow context but at the same time, I was worried it would be a much bigger change overall and perhaps a bit over reaching or confusing. For example, what happens ifgitignore
is not installed? Should there be a message indicating how to install even though the user did not specify any option related togitignore
? Could cause some confusion.Also, I'm not sure if this requires a bump of the version number and, if so, if it should be the build or the minor version number that is bumped.