ivalkeen / guard-ctags-bundler

Guard gem for generating ctags for project files and gems from project's bundle.
https://github.com/ivalkeen/guard-ctags-bundler
MIT License
108 stars 24 forks source link

Facilitate easier configuration for emacs and vim users in one team #26

Open keithpitty opened 9 years ago

keithpitty commented 9 years ago

We have both emacs and vim users in our team. It would be nice to enable us to have guard-ctags-bundler set up in the Guardfile in such a way that we can derive whether or not :emacs is true based on a a dot file (e.g. .guard-ctags-bundler) that specifies the value of :emacs.

ivalkeen commented 9 years ago

Thanks for the suggestion, I think it's a good idea, I will think about it.

For now you can use environment variables. Something like this should work:

guard 'ctags-bundler', :emacs => ENV['EDITOR'] == 'emacs', :src_path => ["app", "lib", "spec/support"] do
  watch(/^(app|lib|spec\/support)\/.*\.rb$/)
  watch('Gemfile.lock')
end
keithpitty commented 9 years ago

Ah, thanks. That's a good idea. We'll give it a shot.