Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

add details on how to use specific annotations in rake:notes

  • Loading branch information...
commit 406d61ee8c0311f742ac74b9a15845cc3cd214d3 1 parent 3e44159
@vijaydev vijaydev authored
Showing with 16 additions and 2 deletions.
  1. +16 −2 railties/guides/source/command_line.textile
View
18 railties/guides/source/command_line.textile
@@ -402,7 +402,7 @@ If you want to strip out or rebuild any of the Rails documentation (including th
h4. +notes+
-+rake notes+ will search through your code for comments beginning with FIXME, OPTIMIZE or TODO. This checks only for files with extension +.builder+, +.rb+, +.rxml+, +.rhtml+ and +.erb+.
++rake notes+ will search through your code for comments beginning with FIXME, OPTIMIZE or TODO. The search is only done in files with extension +.builder+, +.rb+, +.rxml+, +.rhtml+ and +.erb+ for both default and custom annotations.
<shell>
$ rake notes
@@ -416,7 +416,19 @@ app/model/school.rb:
* [ 17] [FIXME]
</shell>
-You can also use custom annotations in your code and list them using +rake notes:custom+ and specify the annotation using an environment variable +ANNOTATION+.
+If you are looking for a specific annotation, say FIXME, you can use +rake notes:fixme+. Note that you have to lower case the annotation's name.
+
+<shell>
+$ rake notes:fixme
+(in /home/foobar/commandsapp)
+app/controllers/admin/users_controller.rb:
+ * [132] high priority for next deploy
+
+app/model/school.rb:
+ * [ 17]
+</shell>
+
+You can also use custom annotations in your code and list them using +rake notes:custom+ by specifying the annotation using an environment variable +ANNOTATION+.
<shell>
$ rake notes:custom ANNOTATION=BUG
@@ -425,6 +437,8 @@ app/model/post.rb:
* [ 23] Have to fix this one before pushing!
</shell>
+NOTE. When using specific annotations and custom annotations, the annotation name (FIXME, BUG etc) is not displayed in the output lines.
+
h4. +routes+
+rake routes+ will list all of your defined routes, which is useful for tracking down routing problems in your app, or giving you a good overview of the URLs in an app you're trying to get familiar with.
Please sign in to comment.
Something went wrong with that request. Please try again.