Skip to content

Commit

Permalink
Translation: Simple Chinese
Browse files Browse the repository at this point in the history
  • Loading branch information
hongjiang authored and mariusae committed Sep 18, 2012
1 parent 13038cc commit 9a185ae
Show file tree
Hide file tree
Showing 7 changed files with 1,373 additions and 2 deletions.
7 changes: 5 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#MARKDOWN = $(HOME)/Library/Haskell/bin/pandoc -f markdown -t html
MARKDOWN = peg-markdown --smart --notes

all: index.html index-ja.html index-ru.html
all: index.html index-ja.html index-ru.html index-cn.html

index.html: header.html.inc effectivescala.html footer.html.inc
cat $^ > $@
Expand All @@ -12,8 +12,11 @@ index-ja.html: header-jp.html.inc effectivescala-ja.html footer-jp.html.inc
index-ru.html: header-ru.html.inc effectivescala-ru.html footer-ru.html.inc
cat $^ > $@

index-cn.html: header-cn.html.inc effectivescala-cn.html footer-cn.html.inc
cat $^ > $@

pub: all
./publish.sh index.html index-ja.html index-ru.html coll.png
./publish.sh index.html index-ja.html index-ru.html index-cn.html coll.png

%.html: %.mo
cat $< | bash proc.sh | bash toc.sh | bash fmt.sh | $(MARKDOWN) > $@
Expand Down
1,239 changes: 1,239 additions & 0 deletions effectivescala-cn.mo

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions effectivescala-ja.mo
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
<h2>他の言語</h2>
<a href="index.html">English</a>
<a href="index-ru.html">Русский</a>
<a href="index-cn.html">简体中文</a>

## 序章

Expand Down
1 change: 1 addition & 0 deletions effectivescala-ru.mo
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
<h2>Перевод на другие языки</h2>
<a href="index.html">English</a>
<a href="index-ja.html">日本語</a>
<a href="index-cn.html">简体中文</a>

## Введение

Expand Down
1 change: 1 addition & 0 deletions effectivescala.mo
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
<h2>Other languages</h2>
<a href="index-ja.html">日本語</a>
<a href="index-ru.html">Русский</a>
<a href="index-cn.html">简体中文</a>


## Introduction
Expand Down
11 changes: 11 additions & 0 deletions footer-cn.html.inc
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@

<center class="footer">
Copyright &copy; 2012 Twitter Inc.<br>
Licensed under <a href="http://creativecommons.org/licenses/by/3.0/">CC BY 3.0</a>
<!--
<a href="http://creativecommons.org/licenses/by/3.0/"><img style="bottom: 0; right: 0; border: 0;" src="http://i.creativecommons.org/l/by/3.0/80x15.png" /></a>
-->
</center>

</body>
</html>
115 changes: 115 additions & 0 deletions header-cn.html.inc
Original file line number Diff line number Diff line change
@@ -0,0 +1,115 @@
<html>
<head>
<title>Effective Scala</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<script type="text/javascript" src="http://use.typekit.com/bub8efs.js"></script>
<script type="text/javascript">try{Typekit.load();}catch(e){}</script>

<!--
<link href='http://fonts.googleapis.com/css?family=Droid+Sans+Mono' rel='stylesheet' type='text/css'>
<link href='http://fonts.googleapis.com/css?family=Droid+Serif' rel='stylesheet' type='text/css'>
<link href='http://fonts.googleapis.com/css?family=Droid+Sans' rel='stylesheet' type='text/css'>
<link href='http://fonts.googleapis.com/css?family=Inconsolata' rel='stylesheet' type='text/css'>
-->

<!--
<link href='http://fonts.googleapis.com/css?family=Droid+Sans+Mono' rel='stylesheet' type='text/css'>
-->

<style>
body {
font-family: "ff-meta-serif-web-pro", times, serif;
margin: 0 1.0in 0 1.0in;
/* line-height: 1.3em;*/
}

address {
text-align: center;
}

.header {
text-align: center;
margin-top: 1em;
}

.rhs {
text-align: left;
}

p {
text-indent: 1em;
text-align: justify;
}

.LP {
text-indent: 0em;
}

code {
font-family: "Droid Sans Mono'", monospace;
/* font-size: 0.75em;*/
font-size: 0.80em;
}

address {
font-family: sans-serif;
}

h1 {
font-family: "prenton-condensed";
}

h2 {
font-weight: bold;
font-size: 110%;
margin-top: 1.5em;
margin-bottom: 0.05in;
}

h3 {
font-size: 100%;
font-style: oblique;
margin-top: 1.5em;
margin-bottom: 0.05in;
}

pre {
margin: 0 0.5in 0 0.5in;
}

dl.rules dt {
font-style: oblique;
}

table#toc {
margin: 0 auto;
}

/* XXX: apply only to TOC. todo: reapply -- html whatever? */
ul {
/* list-style-type: none;*/
}

.algo {
font-variant: small-caps;
}

div.explainer {
margin-left: 3em;
border-left: 2px solid;
padding-left: 1em;
}

.explainer > h3 {
margin-top: 0px;
font-style: normal;
}

.footer {
font-style: oblique;
font-size: small;
}
</style>
</head>

<body>

0 comments on commit 9a185ae

Please sign in to comment.