diff --git a/README.md b/README.md index 7a37733..f150182 100644 --- a/README.md +++ b/README.md @@ -25,16 +25,28 @@ If you want to submit tips, [please do so here](http://gitready.com/submit.html) If you are interested in translating posts into another language, great! Here's what to do: * Fork the project. -* Create a branch with the ISO code for your language +* Create a branch with the ISO code for your language, so for english: + +
+git checkout -b en
+
+ +* Unpublish all the posts (and commit your changes): + +
+rake unpublish
+git commit -am "Unpublishing all the posts"
+
+ * Translate the front page headers, footers. Check out the other translated sites for an example, such as the [german one](http://de.gitready.com). * Translate as little or as many posts as you so desire. -* The posts that aren't translated, add this to the YAML front matter (this way, untranslated posts don't show up): +* Push your work back up (remember to the right branch name!):
-published: false
+git push origin en
 
-* Submit a pull request to the main repository. +* Submit a pull request to qrush's repository. Once that's done, I'll add your language's subdomain and get it published. diff --git a/Rakefile b/Rakefile index 63a7154..e30b077 100644 --- a/Rakefile +++ b/Rakefile @@ -28,3 +28,13 @@ EOF ssh.exec commands end end + +desc "Unpublish all posts" +task :unpublish do + Dir["_posts/*.textile"].each do |post| + puts "Unpublishing #{post}" + lines = File.readlines(post) + lines.insert(1, "published: false\n") + File.open(post, "w") { |f| f.write lines.join } + end +end