<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -1 +1,2 @@
-/config.xml
\ No newline at end of file
+/config.xml
+endless_tweets/endless_tweets.user.js
\ No newline at end of file</diff>
      <filename>.gitignore</filename>
    </modified>
    <modified>
      <diff>@@ -4,10 +4,33 @@ require 'curl'
 require 'cgi'
 
 class Gm &lt; Thor
+  desc 'build', %(Builds the *.user.js files from *.js sources)
+  def build
+    for name in self.class.scripts.keys
+      source = File.open(&quot;#{name}/#{name}.js&quot;, 'r')
+      target = File.open(&quot;#{name}/#{name}.user.js&quot;, 'w')
+      
+      for line in source
+        case line
+        when %r{(\s*)//= (\w+)}
+          helper_name = $2
+          target.puts &quot;/*** #{helper_name} ***/&quot;
+          target.write File.read(&quot;toolkit/#{helper_name}.js&quot;)
+        else
+          target.write line
+        end
+      end
+      
+      source.close
+      target.close
+      puts target.path
+    end
+  end
+  
   desc 'check', %(Checks scriptLength property on both local and remote file)
   def check
     Net::HTTP.start('userscripts.org') do |http|
-      self.class.scripts.each do |name, id|
+      for name, id in self.class.scripts
         req = Net::HTTP::Head.new script_path(id)
         res = http.request(req)
         remote_size = res.content_length</diff>
      <filename>Thorfile</filename>
    </modified>
    <modified>
      <diff>@@ -605,8 +605,6 @@ if (address &amp;&amp; /[+-]?\d+\.\d+,[+-]?\d+\.\d+/.test(address.textContent)) {
   address.innerHTML = '&lt;a class=&quot;googlemap&quot; href=&quot;http://maps.google.com/maps?q=' + coordinates + '&quot;&gt;&lt;img src=&quot;http://maps.google.com/staticmap?center=' + coordinates + '&amp;markers=' + coordinates + ',red&amp;zoom=13&amp;size=165x165&amp;key=' + API_KEY + '&quot; alt=&quot;&quot;&gt;&lt;/a&gt;'
 }
 
-// *** update notification *** //
-
 //= update_notifier
 
 var scriptURL = 'http://userscripts.org/scripts/show/24398',
@@ -645,8 +643,6 @@ if (wrapper) checkUserscriptUpdate(scriptURL, scriptLength, function() {
     &quot;)
 })
 
-// ********* UTILITY FUNCTIONS ********* //
-  
 //= toolkit
 
 function twitterLinkify(text) {</diff>
      <filename>endless_tweets/endless_tweets.js</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>02bbae77f0fbb5b2ea6ed10d23070e490db4e103</id>
    </parent>
  </parents>
  <author>
    <name>Mislav Marohni&#263;</name>
    <email>mislav.marohnic@gmail.com</email>
  </author>
  <url>http://github.com/mislav/user-scripts/commit/908fe788e5eac9aedd73fcdc208c7aa58aa0b8e2</url>
  <id>908fe788e5eac9aedd73fcdc208c7aa58aa0b8e2</id>
  <committed-date>2009-06-03T11:03:06-07:00</committed-date>
  <authored-date>2009-05-08T12:33:19-07:00</authored-date>
  <message>thor gm:build task for building *.user.js files from source

remove now unnecessary delimiters in comments</message>
  <tree>8fb18d22b78afa0ce365b54434222a0866230054</tree>
  <committer>
    <name>Mislav Marohni&#263;</name>
    <email>mislav.marohnic@gmail.com</email>
  </committer>
</commit>
