Skip to content
This repository

Readme section for creating new Guard is unclear #261

Merged
merged 2 commits into from over 2 years ago

2 participants

Sandro Padin Rémy Coutable
Sandro Padin

I'm confused by the use of the term guard-name in the README section for creating a new guard. It's unclear whether you should be using the actual word "guard" or the name of your Guard.

spadin added some commits
Sandro Padin spadin Removes the usage of the term `guard-name`. `guard-name` was used wit…
…h different meanings in the same context making this section very difficult to understand.
54ae028
Sandro Padin spadin Didn't finish updating the section correctly. a49181b
Rémy Coutable
Owner
rymai commented

Very good catch!!

Thanks very much for clarifying all that! :)

Rémy Coutable rymai merged commit 9e36762 into from
Rémy Coutable rymai closed this
Rémy Coutable
Owner
rymai commented

And you're in the CHANGELOG now! :clap:

Sandro Padin

Nice. Thanks! :smile:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Showing 2 unique commits by 1 author.

Mar 13, 2012
Sandro Padin spadin Removes the usage of the term `guard-name`. `guard-name` was used wit…
…h different meanings in the same context making this section very difficult to understand.
54ae028
Sandro Padin spadin Didn't finish updating the section correctly. a49181b
This page is out of date. Refresh to see the latest.

Showing 1 changed file with 10 additions and 11 deletions. Show diff stats Hide diff stats

  1. +10 11 README.md
21 README.md
Source Rendered
@@ -760,13 +760,12 @@ You may also need to pay attention to the values of `max_queued_events` and `max
760 760 Create a Guard
761 761 --------------
762 762
763   -Creating a new Guard is very easy, just create a new gem by running `bundle gem guard-name`, where `name` is
764   -the name of your Guard. Please make your Guard start with `guard-`, so that it can easily be found on RubyGems.
  763 +Creating a new Guard is very easy. For example, to create a Guard named `yoyo` just create a new gem by running `bundle gem guard-yoyo`. Please make your Guard start with `guard-`, so that it can easily be found on RubyGems.
765 764
766 765 ```bash
767   -$ mkdir guard-name
768   -$ cd guard-name
769   -$ bundle gem guard-name
  766 +$ mkdir guard-yoyo
  767 +$ cd guard-yoyo
  768 +$ bundle gem guard-yoyo
770 769 ```
771 770
772 771 Now extend the project structure to have an initial Guard:
@@ -775,31 +774,31 @@ Now extend the project structure to have an initial Guard:
775 774 .travis.yml # bonus point!
776 775 CHANGELOG.md # bonus point!
777 776 Gemfile
778   -guard-name.gemspec
  777 +guard-yoyo.gemspec
779 778 Guardfile
780 779 lib/
781 780 guard/
782   - guard-name/
  781 + yoyo/
783 782 templates/
784 783 Guardfile # needed for `guard init <guard-name>`
785 784 version.rb
786   - guard-name.rb
  785 + yoyo.rb
787 786 test/ # or spec/
788 787 README.md
789 788 ```
790 789
791   -Your Guard main class `Guard::GuardName` in `lib/guard/guard-name.rb` must inherit from
  790 +Your Guard main class `Guard::Yoyo` in `lib/guard/guard-yoyo.rb` must inherit from
792 791 [Guard::Guard](http://rubydoc.info/github/guard/guard/master/Guard/Guard) and should overwrite at least the
793 792 `#run_on_change` task methods.
794 793
795   -Here is an example scaffold for `lib/guard/guard-name.rb`:
  794 +Here is an example scaffold for `lib/guard/yoyo.rb`:
796 795
797 796 ```ruby
798 797 require 'guard'
799 798 require 'guard/guard'
800 799
801 800 module Guard
802   - class GuardName < Guard
  801 + class Yoyo < Guard
803 802
804 803 # Initialize a Guard.
805 804 # @param [Array<Guard::Watcher>] watchers the Guard file watchers

Tip: You can add notes to lines in a file. Hover to the left of a line to make a note

Something went wrong with that request. Please try again.