Permalink
Browse files

Keeping the Changelog up to date and improved the Readme

  • Loading branch information...
1 parent 42e4413 commit 11c3e0b782da383a73c0b3e827851a0d02c75ecd Rémy Coutable committed with Rémy Coutable May 28, 2011
Showing with 51 additions and 13 deletions.
  1. +23 −7 CHANGELOG.markdown → CHANGELOG.md
  2. +28 −3 README.markdown → README.md
  3. +0 −3 lib/guard/dsl.rb
View
30 CHANGELOG.markdown → CHANGELOG.md
@@ -1,6 +1,23 @@
+## 0.4.0.rc - May 28, 2011
+
+### Bugs fixes:
+
+- Pull request [#69](https://github.com/guard/guard/pull/69): Fixed typo in README: Ctr-/ => Ctr-\\. ([@tinogomes](https://github.com/tinogomes))
+- Pull request [#66](https://github.com/guard/guard/pull/66): Support for dashes in guard names. ([@johnbintz](https://github.com/johnbintz))
+- Require `guard/ui` because Guard::Notifier can be required without full Guard. ([@yannlugrin](https://github.com/yannlugrin))
+- Handled quick file (<1s) modification. Avoid to catch modified files without content modification (sha1 checksum). ([@thibaudgg](https://github.com/thibaudgg) and [@netzpirat](https://github.com/netzpirat))
+- Fixed Guard::Notifier (when growl/libnotify not present). ([@thibaudgg](https://github.com/thibaudgg))
+- Fixed Rubygems deprecation messages. ([@thibaudgg](https://github.com/thibaudgg))
+
### New features:
-- Pull request [#55](https://github.com/guard/guard/issues/55): It is now possible to pass `:guardfile` (a Guardfile path) or `:guardfile_contents` (the content of a Guardfile). Hence this allows to use Guard::Dsl.evaluate_guardfile in a programmatic manner. ([@anithri](https://github.com/anithri), improved by ([@rymai](https://github.com/rymai))
+- Pull request [#67](https://github.com/guard/guard/pull/67): Allow Guardfile in $HOME folder. ([@hashrocketeer](https://github.com/hashrocketeer))
+- Pull request [#64](https://github.com/guard/guard/pull/64): Windows notifications support. ([@stereobooster](https://github.com/stereobooster))
+- Use ENV['GUARD_NOTIFY"] to disable notifications. ([@thibaudgg](https://github.com/thibaudgg))
+- Cleaning up all specs. ([@netzpirat](https://github.com/netzpirat))
+- Pull request [#60](https://github.com/guard/guard/pull/60): Added Windows support. ([@stereobooster](https://github.com/stereobooster))
+- Pull request [#58](https://github.com/guard/guard/pull/58): Extract code from signal handlers into methods. ([@nicksieger](https://github.com/nicksieger))
+- Pull request [#55](https://github.com/guard/guard/pull/55): It is now possible to pass `:guardfile` (a Guardfile path) or `:guardfile_contents` (the content of a Guardfile) to `Guard::Dsl.evaluate_guardfile`. Hence this allows the use of `Guard::Dsl.evaluate_guardfile` in a programmatic manner. ([@anithri](https://github.com/anithri), improved by ([@rymai](https://github.com/rymai))
## 0.3.4 - April 24, 2011
@@ -27,7 +44,7 @@
### Bugs fixes:
-- Pull request [#43](https://github.com/guard/guard/issues/43): Fixed `guard init` command. ([@brainopia](https://github.com/brainopia))
+- Pull request [#43](https://github.com/guard/guard/pull/43): Fixed `guard init` command. ([@brainopia](https://github.com/brainopia))
## 0.3.1 - April 14, 2011
@@ -53,16 +70,15 @@
### New features:
- The whole directory is now watched during `run_on_change` to detect new files modifications. ([@thibaudgg](https://github.com/thibaudgg))
-- Pull request [#26](https://github.com/guard/guard/issues/26): New DSL method: `group` allows you to group several guards. ([@netzpirat](https://github.com/netzpirat))
-- Pull request [#26](https://github.com/guard/guard/issues/26): New CLI option: `--group group_name` to specify certain groups of guards to start. ([@netzpirat](https://github.com/netzpirat))
+- Pull request [#26](https://github.com/guard/guard/pull/26): New DSL method: `group` allows you to group several guards. New CLI option: `--group group_name` to specify certain groups of guards to start. ([@netzpirat](https://github.com/netzpirat))
- `watch` patterns are now more strict: strings are matched with `String#==`, `Regexp` are matched with `Regexp#match`. ([@rymai](https://github.com/rymai))
- A deprecation warning is displayed if your `Guardfile` contains `String` that look like `Regexp` (bad!). ([@rymai](https://github.com/rymai))
- It's now possible to return an `Enumerable` in the `watch` optional blocks in the `Guardfile`. ([@rymai](https://github.com/rymai))
### New specs:
- Guard::Watcher. ([@rymai](https://github.com/rymai))
-- Pull request [#13](https://github.com/guard/guard/issues/13): Guard::Dsl. ([@oliamb](https://github.com/oliamb))
+- Pull request [#13](https://github.com/guard/guard/pull/13): Guard::Dsl. ([@oliamb](https://github.com/oliamb))
## 0.2.2 - October 25, 2010
@@ -76,8 +92,8 @@
### Bugs fixes:
-- Pull request [#7](https://github.com/guard/guard/issues/7): Fixes for Linux support. ([@yannlugrin](https://github.com/yannlugrin)))
-- Pull request [#6](https://github.com/guard/guard/issues/6): Locate guard now chomp newline in result path. ([@yannlugrin](https://github.com/yannlugrin)))
+- Pull request [#7](https://github.com/guard/guard/pull/7): Fixes for Linux support. ([@yannlugrin](https://github.com/yannlugrin)))
+- Pull request [#6](https://github.com/guard/guard/pull/6): Locate guard now chomp newline in result path. ([@yannlugrin](https://github.com/yannlugrin)))
## 0.2.0 - October 21, 2010
View
31 README.markdown → README.md
@@ -103,7 +103,7 @@ or if you use Bundler, to run the Guard executable specific to your bundle:
$ bundle exec guard
```
-Guard will look for a Guardfile in your current directory. If it does not find one, it will look in your home directory for one.
+Guard will look for a Guardfile in your current directory. If it does not find one, it will look in your `$HOME` directory for one.
Command line options
--------------------
@@ -122,7 +122,7 @@ $ guard --notify false
$ guard -n f # shortcut
```
-Notifications can also be disabled by setting a `GUARD_NOTIFY` environment variable to `false`
+Notifications can also be disabled globally by setting a `GUARD_NOTIFY` environment variable to `false`
The guards to start can be specified by group (see the Guardfile DSL below) specifying the `--group` (or `-g`) option:
@@ -212,6 +212,31 @@ group 'frontend' do
end
```
+The Guardfile DSL can also be used in a programmatic fashion by calling directly `Guard::Dsl.evaluate_guardfile`.
+Available options are as follow:
+
+* `:guardfile` - The path to a valid Guardfile.
+* `:guardfile_contents` - A string representing the content of a valid Guardfile
+
+Without any options given, Guard will look for a Guardfile in your current directory and if it does not find one, it will look in your `$HOME` directory for one.
+
+For instance, you could use it as follow:
+
+``` ruby
+gem 'guard'
+require 'guard'
+
+Guard.setup
+
+Guard::Dsl.evaluate_guardfile(:guardfile => '/Your/Custom/Path/To/A/Valid/Guardfile')
+# or
+Guard::Dsl.evaluate_guardfile(:guardfile_contents => "
+ guard 'rspec' do
+ watch(%r{^spec/.+_spec\.rb})
+ end
+")
+```
+
Create a new guard
------------------
@@ -304,7 +329,7 @@ Development
* Report Issues/Questions/Feature requests on [GitHub Issues](https://github.com/guard/guard/issues).
Pull requests are very welcome! Make sure your patches are well tested. Please create a topic branch for every separate change
-you make.
+you make. Please do not change the version in your pull-request.
Author
------
View
3 lib/guard/dsl.rb
@@ -3,9 +3,6 @@ class Dsl
class << self
@@options = nil
- # TODO: Add documentation to explain that it is possible to pass `:guardfile` (a Guardfile path)
- # or `:guardfile_contents` (the content of a Guardfile). Hence this allows to use Guard::Dsl.evaluate_guardfile
- # in a programmatic manner
def evaluate_guardfile(options = {})
options.is_a?(Hash) or raise ArgumentError.new("evaluate_guardfile not passed a Hash!")

0 comments on commit 11c3e0b

Please sign in to comment.