Skip to content

Commit

Permalink
Add a script so don't need to rely on Sake anymore
Browse files Browse the repository at this point in the history
  • Loading branch information
Cuong Tran committed Feb 29, 2008
1 parent 4bf0348 commit 3502a73
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 14 deletions.
2 changes: 1 addition & 1 deletion Manifest.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ log/debug.log
script/destroy
script/generate
script/txt2html
bin/annotate
setup.rb
tasks/annotate.rake
tasks/deployment.rake
tasks/environment.rake
tasks/website.rake
Expand Down
5 changes: 2 additions & 3 deletions README.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,11 @@ Install
=======

sudo gem install sake annotate_models
sake -i http://github.com/ctran/annotate_models/tree/master/tasks/annotate.rake?raw=true

Usage
=====

sake annotate_models
cd [your project]
annotate

Source
======
Expand Down
5 changes: 5 additions & 0 deletions bin/annotate
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
load 'Rakefile'
require 'tasks/annotate'

Rake::Task['annotate_models'].invoke

4 changes: 2 additions & 2 deletions config/hoe.rb
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@ def extra_deps

# == Optional
p.changes = p.paragraphs_of("History.txt", 0..1).join("\n\n")
p.extra_deps = [['sake', '1.0.13']] # An array of rubygem dependencies [name, version], e.g. [ ['active_support', '>= 1.3.1'] ]
#p.spec_extras = {} # A hash of extra values to set in the gemspec.
p.extra_deps = [] # An array of rubygem dependencies [name, version], e.g. [ ['active_support', '>= 1.3.1'] ]
p.spec_extras = {} # A hash of extra values to set in the gemspec.

end

Expand Down
2 changes: 1 addition & 1 deletion tasks/annotate.rake → lib/tasks/annotate.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
task :annotate_models => :environment do
require 'annotate_models'
AnnotateModels.do_annotations
end
end
7 changes: 3 additions & 4 deletions website/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ <h2>Installing</h2>

<p><pre class='syntax'>
<span class="ident">sudo</span> <span class="ident">gem</span> <span class="ident">install</span> <span class="ident">annotate_models</span>
<span class="ident">sake</span> <span class="punct">-</span><span class="ident">i</span> <span class="ident">http</span><span class="punct">:/</span><span class="regex"></span><span class="punct">/</span><span class="ident">github</span><span class="punct">.</span><span class="ident">com</span><span class="punct">/</span><span class="ident">ctran</span><span class="punct">/</span><span class="ident">annotate_models</span><span class="punct">/</span><span class="ident">tree</span><span class="punct">/</span><span class="ident">master</span><span class="punct">/</span><span class="ident">tasks</span><span class="punct">/</span><span class="ident">deployment</span><span class="punct">.</span><span class="ident">rake?raw</span><span class="punct">=</span><span class="constant">true</span>
</pre></p>


Expand All @@ -55,13 +54,13 @@ <h2>The basics


<p>This was created by Dave Thomas as a Rails plugin.
This is now a gem that can be used together with <a href="http://errtheblog.com/posts/60-sake-bomb">Sake</a></p>
This is now a gem that can run from command line</p>


<h2>Demonstration of usage</h2>


<p>Go to your <span class="caps">RAILS</span>_ROOT dir, then run <code>sake annotate_models</code></p>
<p>Go to your <span class="caps">RAILS</span>_ROOT dir, then run <code>annotate</code></p>


<h2>How to submit patches</h2>
Expand All @@ -87,7 +86,7 @@ <h2>Contact</h2>

<p>Comments are welcome. Send an email to <a href="mailto:[email protected]">Cuong Tran</a></p>
<p class="coda">
<a href="[email protected]">Cuong Tran</a>, 28th February 2008<br>
<a href="[email protected]">Cuong Tran</a>, 29th February 2008<br>
Theme extended from <a href="http://rb2js.rubyforge.org/">Paul Battley</a>
</p>
</div>
Expand Down
5 changes: 2 additions & 3 deletions website/index.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,17 @@ h2. Installing

<pre syntax="ruby">
sudo gem install annotate_models
sake -i http://github.com/ctran/annotate_models/tree/master/tasks/annotate.rake?raw=true
</pre>

h2. The basics
Add a comment summarizing the current schema to the top of each ActiveRecord model source file.

This was created by Dave Thomas as a Rails plugin.
This is now a gem that can be used together with "Sake":http://errtheblog.com/posts/60-sake-bomb
This is now a gem that can run from command line

h2. Demonstration of usage

Go to your RAILS_ROOT dir, then run <code>sake annotate_models</code>
Go to your RAILS_ROOT dir, then run <code>annotate</code>

h2. How to submit patches

Expand Down

0 comments on commit 3502a73

Please sign in to comment.