Permalink
Browse files

Initial

  • Loading branch information...
ayanko committed Jun 3, 2012
0 parents commit d3eed718638e451b52ebb34b3c0f026d3bea777b
No changes.
@@ -0,0 +1,7 @@
+source :rubygems
+
+gem "sinatra", "1.3.2"
+
+gem "i18n_template",
+ :git => "git://github.com/railsware/i18n_template.git",
+ :branch => "development"
@@ -0,0 +1,56 @@
+GIT
+ remote: git://github.com/railsware/i18n_template.git
+ revision: d8ceba036e1beb81c7e597fda4c9cc24177c0e31
+ branch: development
+ specs:
+ i18n_template (0.1.0)
+ actionpack (>= 2.3.0)
+
+GEM
+ remote: http://rubygems.org/
+ specs:
+ actionpack (3.2.5)
+ activemodel (= 3.2.5)
+ activesupport (= 3.2.5)
+ builder (~> 3.0.0)
+ erubis (~> 2.7.0)
+ journey (~> 1.0.1)
+ rack (~> 1.4.0)
+ rack-cache (~> 1.2)
+ rack-test (~> 0.6.1)
+ sprockets (~> 2.1.3)
+ activemodel (3.2.5)
+ activesupport (= 3.2.5)
+ builder (~> 3.0.0)
+ activesupport (3.2.5)
+ i18n (~> 0.6)
+ multi_json (~> 1.0)
+ builder (3.0.0)
+ erubis (2.7.0)
+ hike (1.2.1)
+ i18n (0.6.0)
+ journey (1.0.3)
+ multi_json (1.3.6)
+ rack (1.4.1)
+ rack-cache (1.2)
+ rack (>= 0.4)
+ rack-protection (1.2.0)
+ rack
+ rack-test (0.6.1)
+ rack (>= 1.0)
+ sinatra (1.3.2)
+ rack (~> 1.3, >= 1.3.6)
+ rack-protection (~> 1.2)
+ tilt (~> 1.3, >= 1.3.3)
+ sprockets (2.1.3)
+ hike (~> 1.2)
+ rack (~> 1.0)
+ tilt (~> 1.1, != 1.3.0)
+ tilt (1.3.3)
+
+PLATFORMS
+ ruby
+
+DEPENDENCIES
+ i18n_template!
+ sinatra (= 1.3.2)
@@ -0,0 +1,35 @@
+require 'sinatra'
+require 'i18n_template'
+
+class Application < Sinatra::Base
+ get '/' do
+ internationalize
+ end
+
+ post '/' do
+ internationalize
+ end
+
+ include ERB::Util
+
+ def internationalize
+ @source = params[:source] || default_source
+
+ document = I18nTemplate::Document.new(@source)
+ document.process!
+
+ @template = document.source
+ @phrases = document.keys.uniq.join("\n")
+
+ erb :index
+ end
+
+ def default_source
+ <<-DATA
+<body>
+ <h2>Hello World</h2>
+ <%= link_to "Home", home_path %>
+</body>
+ DATA
+ end
+end
@@ -0,0 +1,3 @@
+require File.expand_path("../application", __FILE__)
+
+run Application

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.

Large diffs are not rendered by default.

Oops, something went wrong.
@@ -0,0 +1,152 @@
+/*
+Date: 17.V.2011
+Author: pumbur <pumbur@pumbur.net>
+*/
+
+pre code
+{
+ display: block; padding: 0.5em;
+ background: #222;
+}
+
+pre .header,
+pre .profile .header *,
+pre .ini .title
+{
+ color: #fff;
+}
+
+pre .comment,
+pre .javadoc,
+pre .preprocessor,
+pre .shebang,
+pre .profile .summary,
+pre .diff,
+pre .pi,
+pre .doctype,
+pre .xml .tag,
+pre .template_comment,
+pre .css .rules,
+pre .tex .special
+{
+ color: #444;
+}
+
+pre .string,
+pre .symbol,
+pre .diff .change,
+pre .regexp,
+pre .xml .attribute,
+pre .xml .value,
+pre .smalltalk .char,
+pre .ini .value
+{
+ color: #ffcc33;
+}
+
+pre .number,
+pre .addition
+{
+ color: #00cc66;
+}
+
+pre .built_in,
+pre .literal,
+pre .vhdl .type,
+pre .go .constant,
+pre .go .typename,
+pre .ini .keyword,
+pre .lua .title,
+pre .perl .variable,
+pre .php .variable,
+pre .mel .variable,
+pre .django .variable,
+pre .css .funtion,
+pre .smalltalk .method,
+pre .hexcolor,
+pre .important,
+pre .flow,
+pre .inheritance,
+pre .parser3 .variable
+{
+ color: #32AAEE;
+}
+
+pre .keyword,
+pre .xml .tag .title,
+pre .css .tag,
+pre .css .class,
+pre .css .id,
+pre .css .pseudo,
+pre .css .attr_selector,
+pre .lisp .title,
+pre .winutils,
+pre .tex .command
+{
+ color: #6644aa;
+}
+
+pre .class .title,
+pre .ruby .constant,
+pre .vala .constant,
+pre .parent,
+pre .deletion,
+pre .template_tag,
+pre .css .keyword,
+pre .javascript .title,
+pre .objectivec .class .id,
+pre .smalltalk .class,
+pre .lisp .keyword,
+pre .apache .tag,
+pre .nginx .variable,
+pre .envvar,
+pre .bash .variable,
+pre .go .built_in,
+pre .vbscript .built_in,
+pre .lua .built_in,
+pre .rsl .built_in,
+pre .tail,
+pre .avrasm .label,
+pre .parser3 .title,
+pre .tex .formula,
+pre .tex .formula *
+{
+ color: #bb1166;
+}
+
+pre .yardoctag,
+pre .phpdoc,
+pre .profile .header,
+pre .ini .title,
+pre .apache .tag,
+pre .parser3 .title
+{
+ font-weight: bold;
+}
+
+pre .coffeescript .javascript,
+pre .xml .javascript,
+pre .xml .css,
+pre .xml .cdata
+{
+ opacity: 0.6;
+}
+
+pre code,
+pre .javascript,
+pre .css,
+pre .xml,
+pre .subst,
+pre .diff .chunk,
+pre .css .value,
+pre .css .attribute,
+pre .lisp .string,
+pre .lisp .number,
+pre .tail .params,
+pre .container,
+pre .haskell *,
+pre .erlang *,
+pre .erlang_repl *
+{
+ color: #aaa;
+}
@@ -0,0 +1,129 @@
+/*
+
+github.com style (c) Vasily Polovnyov <vast@whiteants.net>
+
+*/
+
+pre code {
+ display: block; padding: 0.5em;
+ color: #000;
+ background: #f8f8ff
+}
+
+pre .comment,
+pre .template_comment,
+pre .diff .header,
+pre .javadoc {
+ color: #998;
+ font-style: italic
+}
+
+pre .keyword,
+pre .css .rule .keyword,
+pre .winutils,
+pre .javascript .title,
+pre .lisp .title,
+pre .subst {
+ color: #000;
+ font-weight: bold
+}
+
+pre .number,
+pre .hexcolor {
+ color: #40a070
+}
+
+pre .string,
+pre .tag .value,
+pre .phpdoc,
+pre .tex .formula {
+ color: #d14
+}
+
+pre .title,
+pre .id {
+ color: #900;
+ font-weight: bold
+}
+
+pre .javascript .title,
+pre .lisp .title,
+pre .subst {
+ font-weight: normal
+}
+
+pre .class .title,
+pre .haskell .label,
+pre .tex .command {
+ color: #458;
+ font-weight: bold
+}
+
+pre .tag,
+pre .tag .title,
+pre .rules .property,
+pre .django .tag .keyword {
+ color: #000080;
+ font-weight: normal
+}
+
+pre .attribute,
+pre .variable,
+pre .instancevar,
+pre .lisp .body {
+ color: #008080
+}
+
+pre .regexp {
+ color: #009926
+}
+
+pre .class {
+ color: #458;
+ font-weight: bold
+}
+
+pre .symbol,
+pre .ruby .symbol .string,
+pre .ruby .symbol .keyword,
+pre .ruby .symbol .keymethods,
+pre .lisp .keyword,
+pre .tex .special,
+pre .input_number {
+ color: #990073
+}
+
+pre .builtin,
+pre .built_in,
+pre .lisp .title {
+ color: #0086b3
+}
+
+pre .preprocessor,
+pre .pi,
+pre .doctype,
+pre .shebang,
+pre .cdata {
+ color: #999;
+ font-weight: bold
+}
+
+pre .deletion {
+ background: #fdd
+}
+
+pre .addition {
+ background: #dfd
+}
+
+pre .diff .change {
+ background: #0086b3
+}
+
+pre .chunk {
+ color: #aaa
+}
+
+pre .tex .formula {
+ opacity: 0.5;
+}
Oops, something went wrong.

0 comments on commit d3eed71

Please sign in to comment.