Skip to content
Browse files

Updated license date

  • Loading branch information...
1 parent d37502d commit c2fdcd76a685ef8361c8e6b85ad1b30c3d84d149 Thibaud Guillaume-Gentil committed Jan 19, 2011
Showing with 13 additions and 17 deletions.
  1. +1 −1 LICENSE
  2. +12 −16 README.rdoc
View
2 LICENSE
@@ -1,4 +1,4 @@
-Copyright (c) 2010 Thibaud Guillaume-Gentil
+Copyright (c) 2011 Thibaud Guillaume-Gentil
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
View
28 README.rdoc
@@ -141,7 +141,7 @@ Example:
guard 'bundler' do
watch('Gemfile')
end
-
+
guard 'rspec' do
# Regexp watch patterns are matched with Regexp#match
watch(%r{^spec/(.+)_spec\.rb})
@@ -158,7 +158,7 @@ Example:
guard 'coffeescript', :output => 'public/javascripts/compiled' do
watch(%r{app/coffeescripts/.+\.coffee})
end
-
+
guard 'livereload' do
watch(%r{app/.+\.(erb|haml)})
end
@@ -179,59 +179,55 @@ lib/guard/guard-name.rb inherit from guard/guard and should overwrite at least o
require 'guard'
require 'guard/guard'
-
+
module Guard
class GuardName < Guard
-
+
def initialize(watchers = [], options = {})
super
# init stuff here, thx!
end
-
+
# ================
# = Guard method =
# ================
-
+
# If one of those methods raise an exception, the Guard instance
# will be removed from the active guard.
-
+
# Call once when guard starts
# Please override initialize method to init stuff
def start
true
end
-
+
# Call with Ctrl-C signal (when Guard quit)
def stop
true
end
-
+
# Call with Ctrl-Z signal
# This method should be mainly used for "reload" (really!) actions like reloading passenger/spork/bundler/...
def reload
true
end
-
+
# Call with Ctrl-/ signal
# This method should be principally used for long action like running all specs/tests/...
def run_all
true
end
-
+
# Call on file(s) modifications
def run_on_change(paths)
true
end
-
+
end
end
Looks at available guards code for more concrete example.
-== TODO
-
-- Add more specs! Shame on me :)
-
== Development
- Source hosted at {GitHub}[https://github.com/guard/guard]

0 comments on commit c2fdcd7

Please sign in to comment.
Something went wrong with that request. Please try again.