shinmun 0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (74) hide show
  1. data/.gitignore +1 -0
  2. data/LICENSE +18 -0
  3. data/README.md +249 -0
  4. data/Rakefile +60 -0
  5. data/bin/shinmun +12 -0
  6. data/example/posts/2008/9/example.md +19 -0
  7. data/example/posts/blog.yml +10 -0
  8. data/example/posts/uuid.state +3 -0
  9. data/example/public/controllers/comments.php +56 -0
  10. data/example/public/images/loading.gif +0 -0
  11. data/example/public/javascripts/comments.js +60 -0
  12. data/example/public/javascripts/highlight.js +505 -0
  13. data/example/public/javascripts/images/bg-fill.png +0 -0
  14. data/example/public/javascripts/images/bg.png +0 -0
  15. data/example/public/javascripts/images/blockquote.png +0 -0
  16. data/example/public/javascripts/images/bold.png +0 -0
  17. data/example/public/javascripts/images/code.png +0 -0
  18. data/example/public/javascripts/images/h1.png +0 -0
  19. data/example/public/javascripts/images/hr.png +0 -0
  20. data/example/public/javascripts/images/img.png +0 -0
  21. data/example/public/javascripts/images/italic.png +0 -0
  22. data/example/public/javascripts/images/link.png +0 -0
  23. data/example/public/javascripts/images/ol.png +0 -0
  24. data/example/public/javascripts/images/redo.png +0 -0
  25. data/example/public/javascripts/images/separator.png +0 -0
  26. data/example/public/javascripts/images/ul.png +0 -0
  27. data/example/public/javascripts/images/undo.png +0 -0
  28. data/example/public/javascripts/images/wmd-on.png +0 -0
  29. data/example/public/javascripts/images/wmd.png +0 -0
  30. data/example/public/javascripts/jquery-form.js +869 -0
  31. data/example/public/javascripts/jquery.js +3383 -0
  32. data/example/public/javascripts/languages/1c.js +82 -0
  33. data/example/public/javascripts/languages/axapta.js +52 -0
  34. data/example/public/javascripts/languages/bash.js +80 -0
  35. data/example/public/javascripts/languages/diff.js +64 -0
  36. data/example/public/javascripts/languages/dos.js +33 -0
  37. data/example/public/javascripts/languages/dynamic.js +460 -0
  38. data/example/public/javascripts/languages/ini.js +36 -0
  39. data/example/public/javascripts/languages/javascript.js +38 -0
  40. data/example/public/javascripts/languages/lisp.js +86 -0
  41. data/example/public/javascripts/languages/mel.js +50 -0
  42. data/example/public/javascripts/languages/profile.js +50 -0
  43. data/example/public/javascripts/languages/renderman.js +71 -0
  44. data/example/public/javascripts/languages/smalltalk.js +53 -0
  45. data/example/public/javascripts/languages/sql.js +50 -0
  46. data/example/public/javascripts/languages/static.js +175 -0
  47. data/example/public/javascripts/languages/vbscript.js +25 -0
  48. data/example/public/javascripts/languages/www.js +245 -0
  49. data/example/public/javascripts/prettyDate.js +36 -0
  50. data/example/public/javascripts/showdown.js +421 -0
  51. data/example/public/javascripts/template.js +165 -0
  52. data/example/public/javascripts/wmd-base.js +1799 -0
  53. data/example/public/javascripts/wmd-plus.js +311 -0
  54. data/example/public/javascripts/wmd.js +73 -0
  55. data/example/public/stylesheets/grid.css +243 -0
  56. data/example/public/stylesheets/grid.png +0 -0
  57. data/example/public/stylesheets/highlight/ascetic.css +38 -0
  58. data/example/public/stylesheets/highlight/dark.css +96 -0
  59. data/example/public/stylesheets/highlight/default.css +91 -0
  60. data/example/public/stylesheets/highlight/far.css +95 -0
  61. data/example/public/stylesheets/highlight/idea.css +75 -0
  62. data/example/public/stylesheets/highlight/sunburst.css +112 -0
  63. data/example/public/stylesheets/highlight/zenburn.css +108 -0
  64. data/example/public/stylesheets/print.css +76 -0
  65. data/example/public/stylesheets/reset.css +45 -0
  66. data/example/public/stylesheets/style.css +141 -0
  67. data/example/public/stylesheets/typography.css +59 -0
  68. data/example/templates/feed.rxml +21 -0
  69. data/example/templates/layout.rhtml +54 -0
  70. data/example/templates/page.rhtml +4 -0
  71. data/example/templates/post.rhtml +57 -0
  72. data/example/templates/posts.rhtml +10 -0
  73. data/lib/shinmun.rb +420 -0
  74. metadata +151 -0
@@ -0,0 +1,96 @@
1
+ /*
2
+
3
+ Dark style from softwaremaniacs.org (c) Ivan Sagalaev <Maniac@SoftwareManiacs.Org>
4
+
5
+ */
6
+
7
+ pre code[class]:after {
8
+ content: 'highlight: ' attr(class);
9
+ display: block; text-align: right;
10
+ font-size: smaller;
11
+ color: #CCC; background: white;
12
+ border-top: solid 1px black;
13
+ padding-top: 0.5em;
14
+ }
15
+
16
+ pre code {
17
+ display: block;
18
+ background: #444;
19
+ }
20
+
21
+ .keyword,
22
+ .literal,
23
+ .change,
24
+ .winutils,
25
+ .flow,
26
+ .lisp .title {
27
+ color: white;
28
+ }
29
+
30
+ pre code,
31
+ .ruby .subst {
32
+ color: #DDD;
33
+ }
34
+
35
+ .string,
36
+ .function .title,
37
+ .class .title,
38
+ .ini .title,
39
+ .tag .attribute .value,
40
+ .css .rules .value,
41
+ .preprocessor,
42
+ .ruby .symbol,
43
+ .ruby .instancevar,
44
+ .ruby .class .parent,
45
+ .built_in,
46
+ .sql .aggregate,
47
+ .django .template_tag,
48
+ .django .variable,
49
+ .smalltalk .class,
50
+ .javadoc,
51
+ .ruby .string,
52
+ .django .filter .argument,
53
+ .smalltalk .localvars,
54
+ .smalltalk .array,
55
+ .css .attr_selector,
56
+ .addition,
57
+ .stream,
58
+ .envvar {
59
+ color: #D88;
60
+ }
61
+
62
+ .comment,
63
+ .java .annotation,
64
+ .python .decorator,
65
+ .template_comment,
66
+ .pi,
67
+ .doctype,
68
+ .deletion,
69
+ .shebang {
70
+ color: #777;
71
+ }
72
+
73
+ .keyword,
74
+ .literal,
75
+ .css .id,
76
+ .phpdoc,
77
+ .function .title,
78
+ .class .title,
79
+ .vbscript .built_in,
80
+ .sql .aggregate,
81
+ .rsl .built_in,
82
+ .smalltalk .class,
83
+ .xml .tag .title,
84
+ .diff .header,
85
+ .chunk,
86
+ .winutils,
87
+ .bash .variable,
88
+ .lisp .title {
89
+ font-weight: bold;
90
+ }
91
+
92
+ .html .css,
93
+ .html .javascript,
94
+ .html .vbscript {
95
+ opacity: 0.5;
96
+ }
@@ -0,0 +1,91 @@
1
+ /*
2
+
3
+ Original style from softwaremaniacs.org (c) Ivan Sagalaev <Maniac@SoftwareManiacs.Org>
4
+
5
+ */
6
+
7
+ pre code {
8
+ display: block;
9
+ background: #F0F0F0;
10
+ padding: 1em;
11
+ border: 1px solid #ccc;
12
+ }
13
+
14
+ pre code,
15
+ .ruby .subst,
16
+ .xml .title,
17
+ .lisp .title {
18
+ color: black;
19
+ }
20
+
21
+ .string,
22
+ .title,
23
+ .parent,
24
+ .tag .attribute .value,
25
+ .rules .value,
26
+ .rules .value .number,
27
+ .preprocessor,
28
+ .ruby .symbol,
29
+ .instancevar,
30
+ .aggregate,
31
+ .template_tag,
32
+ .django .variable,
33
+ .smalltalk .class,
34
+ .addition,
35
+ .flow,
36
+ .stream,
37
+ .bash .variable {
38
+ color: #800;
39
+ }
40
+
41
+ .comment,
42
+ .annotation,
43
+ .template_comment,
44
+ .diff .header,
45
+ .chunk {
46
+ color: #888;
47
+ }
48
+
49
+ .number,
50
+ .regexp,
51
+ .literal,
52
+ .smalltalk .symbol,
53
+ .smalltalk .char,
54
+ .change {
55
+ color: #080;
56
+ }
57
+
58
+ .javadoc,
59
+ .ruby .string,
60
+ .decorator,
61
+ .filter .argument,
62
+ .localvars,
63
+ .array,
64
+ .attr_selector,
65
+ .pi,
66
+ .doctype,
67
+ .deletion,
68
+ .envvar,
69
+ .shebang {
70
+ color: #88F;
71
+ }
72
+
73
+ .keyword,
74
+ .id,
75
+ .phpdoc,
76
+ .title,
77
+ .vbscript .built_in,
78
+ .rsl .built_in,
79
+ .cpp .built_in,
80
+ .aggregate,
81
+ .smalltalk .class,
82
+ .winutils,
83
+ .bash .variable {
84
+ font-weight: bold;
85
+ }
86
+
87
+ .html .css,
88
+ .html .javascript,
89
+ .html .vbscript {
90
+ opacity: 0.5;
91
+ }
@@ -0,0 +1,95 @@
1
+ /*
2
+
3
+ FAR Style (c) MajestiC <majestic2k@gmail.com>
4
+
5
+ */
6
+
7
+ pre code[class]:after {
8
+ content: 'highlight: ' attr(class);
9
+ display: block; text-align: right;
10
+ font-size: smaller;
11
+ color: #CCC; background: white;
12
+ border-top: solid 1px;
13
+ padding-top: 0.5em;
14
+ }
15
+
16
+ pre code {
17
+ display: block;
18
+ background: #000080;
19
+ }
20
+
21
+ pre code,
22
+ .ruby .subst {
23
+ color: #0FF;
24
+ }
25
+
26
+ .string,
27
+ .ruby .string,
28
+ .function .title,
29
+ .class .title,
30
+ .ini .title,
31
+ .tag .attribute .value,
32
+ .css .rules .value,
33
+ .css .rules .value .number,
34
+ .preprocessor,
35
+ .ruby .symbol,
36
+ .built_in,
37
+ .sql .aggregate,
38
+ .django .template_tag,
39
+ .django .variable,
40
+ .smalltalk .class,
41
+ .addition {
42
+ color: #FF0;
43
+ }
44
+
45
+ .change,
46
+ .envvar,
47
+ .bash .variable {
48
+ color: #FFF;
49
+ }
50
+
51
+ .comment,
52
+ .phpdoc,
53
+ .javadoc,
54
+ .java .annotation,
55
+ .template_comment,
56
+ .deletion {
57
+ color: #888;
58
+ }
59
+
60
+ .number,
61
+ .regexp,
62
+ .literal,
63
+ .smalltalk .symbol,
64
+ .smalltalk .char {
65
+ color: #0F0;
66
+ }
67
+
68
+ .python .decorator,
69
+ .django .filter .argument,
70
+ .smalltalk .localvars,
71
+ .smalltalk .array,
72
+ .css .attr_selector,
73
+ .xml .pi,
74
+ .diff .header,
75
+ .chunk,
76
+ .shebang {
77
+ color: #008080;
78
+ }
79
+
80
+ .keyword,
81
+ .css .id,
82
+ .function .title,
83
+ .class .title,
84
+ .ini .title,
85
+ .vbscript .built_in,
86
+ .sql .aggregate,
87
+ .rsl .built_in,
88
+ .smalltalk .class,
89
+ .xml .tag .title,
90
+ .winutils,
91
+ .flow,
92
+ .lisp .title {
93
+ color: #FFF;
94
+ font-weight: bold;
95
+ }
@@ -0,0 +1,75 @@
1
+ /*
2
+
3
+ Intellij Idea-like styling (c) Vasily Polovnyov <vast@whiteants.net>
4
+
5
+ */
6
+
7
+ pre code {
8
+ font: 12px "Monospaced", monospace;
9
+ display: block;
10
+ color: #000;
11
+ background: #fff;
12
+ }
13
+
14
+ .subst, .title {
15
+ font-weight: normal;
16
+ color: #000;
17
+ }
18
+
19
+ .comment, .template_comment, .javadoc, .diff .header {
20
+ color: #808080;
21
+ font-style: italic;
22
+ }
23
+
24
+ .annotation, .decorator, .preprocessor, .doctype, .pi, .chunk, .shebang {
25
+ color: #808000;
26
+ }
27
+
28
+ .tag, .pi {
29
+ background: #efefef;
30
+ }
31
+
32
+ .tag .title, .id, .attr_selector, .literal, .keyword, .hexcolor, .css .function, .ini .title, .css .class, .list .title {
33
+ font-weight: bold;
34
+ color: #000080;
35
+ }
36
+
37
+ .attribute, .rules .keyword, .number, .regexp {
38
+ font-weight: bold;
39
+ color: #0000ff;
40
+ }
41
+
42
+ .number, .regexp {
43
+ font-weight: normal;
44
+ }
45
+
46
+ .string, .value, .filter .argument, .css .function .params {
47
+ color: #008000;
48
+ font-weight: bold;
49
+ }
50
+
51
+ .symbol, .char {
52
+ color: #000;
53
+ background: #d0eded;
54
+ font-style: italic;
55
+ }
56
+
57
+ .phpdoc, .javadoctag {
58
+ text-decoration: underline;
59
+ }
60
+
61
+ .variable, .envvar {
62
+ color: #660e7a;
63
+ }
64
+
65
+ .addition {
66
+ background: #baeeba;
67
+ }
68
+
69
+ .deletion {
70
+ background: #ffc8bd;
71
+ }
72
+
73
+ .diff .change {
74
+ background: #bccff9;
75
+ }
@@ -0,0 +1,112 @@
1
+ /*
2
+
3
+ Sunburst-like style (c) Vasily Polovnyov <vast@whiteants.net>
4
+
5
+ */
6
+
7
+ pre code {
8
+ font: 12px / 1.3em 'Lucida Console', 'courier new', monospace;
9
+ color: #f8f8f8;
10
+ }
11
+
12
+ pre {
13
+ background: #000;
14
+ }
15
+
16
+ .comment, .template_comment, .javadoc {
17
+ color: #aeaeae;
18
+ font-style: italic;
19
+ }
20
+
21
+ .keyword, .ruby .function .keyword {
22
+ color: #E28964;
23
+ }
24
+
25
+ .function .keyword, .sub .keyword, .method, .list .title {
26
+ color: #99CF50;
27
+ }
28
+
29
+ .string, .attribute .value, .cdata, .filter .argument, .attr_selector {
30
+ color: #65B042;
31
+ }
32
+
33
+ .subst {
34
+ color: #DAEFA3;
35
+ }
36
+
37
+ .regexp {
38
+ color: #E9C062;
39
+ }
40
+
41
+ .function .title, .sub .identifier, .pi, .tag, .tag .keyword, .decorator, .ini .title, .shebang {
42
+ color: #89BDFF;
43
+ }
44
+
45
+ .class .title, .smalltalk .class, .javadoctag, .phpdoc {
46
+ text-decoration: underline;
47
+ }
48
+
49
+ .symbol, .number {
50
+ color: #3387CC;
51
+ }
52
+
53
+ .params, .variable {
54
+ color: #3E87E3;
55
+ }
56
+
57
+ .css .keyword {
58
+ color: #CDA869;
59
+ }
60
+
61
+ .css .class {
62
+ color: #9B703F;
63
+ }
64
+
65
+ .rules .keyword {
66
+ color: #C5AF75;
67
+ }
68
+
69
+ .rules .value {
70
+ color: #CF6A4C;
71
+ }
72
+
73
+ .css .id {
74
+ color: #8B98AB;
75
+ }
76
+
77
+ .annotation {
78
+ color: #9B859D;
79
+ }
80
+
81
+ .preprocessor {
82
+ color: #8996A8;
83
+ }
84
+
85
+ .hexcolor, .css .value .number {
86
+ color: #DD7B3B;
87
+ }
88
+
89
+ .css .function {
90
+ color: #DAD085;
91
+ }
92
+
93
+ .diff .header, .chunk {
94
+ background-color: #0E2231;
95
+ color: #F8F8F8;
96
+ font-style: italic;
97
+ }
98
+
99
+ .diff .change {
100
+ background-color: #4A410D;
101
+ color: #F8F8F8;
102
+ }
103
+
104
+ .addition {
105
+ background-color: #253B22;
106
+ color: #F8F8F8;
107
+ }
108
+
109
+ .deletion {
110
+ background-color: #420E09;
111
+ color: #F8F8F8;
112
+ }
@@ -0,0 +1,108 @@
1
+ /*
2
+
3
+ Zenburn style from voldmar.ru (c) Vladimir Epifanov <voldmar@voldmar.ru>
4
+ based on dark.css by Ivan Sagalaev
5
+
6
+ */
7
+
8
+ pre code[class]:after {
9
+ content: 'highlight: ' attr(class);
10
+ display: block; text-align: right;
11
+ font-size: smaller;
12
+ color: #CCC; background: white;
13
+ border-top: solid 1px black;
14
+ padding-top: 0.5em;
15
+ }
16
+
17
+ pre code {
18
+ display: block;
19
+ background: #3F3F3F;
20
+ color: #DCDCDC;
21
+ }
22
+
23
+ .keyword,
24
+ .tag,
25
+ .django .tag,
26
+ .django .keyword,
27
+ .css .class,
28
+ .css .id,
29
+ .lisp .title {
30
+ color: #E3CEAB;
31
+ }
32
+
33
+ .django .template_tag,
34
+ .django .variable,
35
+ .django .filter .argument {
36
+ color: #DCDCDC;
37
+ }
38
+
39
+ .number {
40
+ color: #8CD0D3;
41
+ }
42
+
43
+ .dos .envvar,
44
+ .dos .stream,
45
+ .variable {
46
+ color: #EFDCBC;
47
+ }
48
+
49
+ .dos .flow,
50
+ .diff .change,
51
+ .python .exception,
52
+ .python .built_in,
53
+ .literal {
54
+ color: #EFEFAF;
55
+ }
56
+
57
+ .diff .chunk,
58
+ .ruby .subst {
59
+ color: #8F8F8F;
60
+ }
61
+
62
+ .dos .keyword,
63
+ .python .decorator,
64
+ .class .title,
65
+ .function .title,
66
+ .ini .title,
67
+ .diff .header,
68
+ .ruby .class .parent {
69
+ color: #efef8f;
70
+ }
71
+
72
+ .dos .winutils,
73
+ .ruby .symbol,
74
+ .ruby .string,
75
+ .ruby .instancevar {
76
+ color: #DCA3A3;
77
+ }
78
+
79
+ .diff .deletion,
80
+ .string,
81
+ .tag .attribute .value,
82
+ .preprocessor,
83
+ .built_in,
84
+ .sql .aggregate,
85
+ .javadoc,
86
+ .smalltalk .class,
87
+ .smalltalk .localvars,
88
+ .smalltalk .array,
89
+ .css .rules .value,
90
+ .css .attr_selector {
91
+ color: #CC9393;
92
+ }
93
+
94
+ .shebang,
95
+ .diff .addition,
96
+ .comment,
97
+ .java .annotation,
98
+ .template_comment,
99
+ .pi,
100
+ .doctype {
101
+ color: #7F9F7F;
102
+ }
103
+
104
+ .html .css,
105
+ .html .javascript {
106
+ opacity: 0.5;
107
+ }
108
+
@@ -0,0 +1,76 @@
1
+ body {
2
+ line-height:1.5;
3
+ font-family:"Helvetica Neue", "Lucida Grande", Arial, Verdana, sans-serif;
4
+ color:#000;
5
+ background:none;
6
+ font-size:10pt;
7
+ }
8
+
9
+ .container {
10
+ background:none;
11
+ }
12
+
13
+ h1,h2,h3,h4,h5,h6 {
14
+ font-family:"Helvetica Neue", Arial, "Lucida Grande", sans-serif;
15
+ }
16
+
17
+ code {
18
+ font:.9em "Courier New", Monaco, Courier, monospace;
19
+ }
20
+
21
+ img {
22
+ float:left;
23
+ margin:1.5em 1.5em 1.5em 0;
24
+ }
25
+
26
+ a img {
27
+ border:none;
28
+ }
29
+
30
+ p img.top {
31
+ margin-top:0;
32
+ }
33
+
34
+ hr {
35
+ background:#ccc;
36
+ color:#ccc;
37
+ width:100%;
38
+ height:2px;
39
+ border:none;
40
+ margin:2em 0;
41
+ padding:0;
42
+ }
43
+
44
+ blockquote {
45
+ font-style:italic;
46
+ font-size:.9em;
47
+ margin:1.5em;
48
+ padding:1em;
49
+ }
50
+
51
+ .small {
52
+ font-size:.9em;
53
+ }
54
+
55
+ .large {
56
+ font-size:1.1em;
57
+ }
58
+
59
+ .quiet {
60
+ color:#999;
61
+ }
62
+
63
+ .hide {
64
+ display:none;
65
+ }
66
+
67
+ a:link,a:visited {
68
+ background:transparent;
69
+ font-weight:700;
70
+ text-decoration:underline;
71
+ }
72
+
73
+ a:link:after,a:visited:after {
74
+ content:" (" attr(href) ") ";
75
+ font-size:90%;
76
+ }
@@ -0,0 +1,45 @@
1
+ /* --------------------------------------------------------------
2
+
3
+ reset.css
4
+ * Resets default browser CSS.
5
+
6
+ Based on work by Eric Meyer:
7
+ * meyerweb.com/eric/thoughts/2007/05/01/reset-reloaded/
8
+
9
+ -------------------------------------------------------------- */
10
+
11
+ html, body, div, span, object, iframe,
12
+ h1, h2, h3, h4, h5, h6,
13
+ a, img, form, label, legend,
14
+ table, caption, tbody, tfoot, thead, tr, th, td {
15
+ margin: 0;
16
+ padding: 0;
17
+ border: 0;
18
+ font-weight: inherit;
19
+ font-style: inherit;
20
+ font-size: 100%;
21
+ font-family: inherit;
22
+ /* vertical-align: baseline; */
23
+ }
24
+
25
+ body {
26
+ line-height: 1.5;
27
+ background: #fff;
28
+ margin:0.5em 0;
29
+ }
30
+
31
+ table {
32
+ border-collapse: separate;
33
+ border-spacing: 0;
34
+ }
35
+
36
+ caption, th, td {
37
+ text-align: left;
38
+ }
39
+
40
+ q:before, q:after {
41
+ content:'';
42
+ }
43
+
44
+
45
+