Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GitBookの構造を変更 #76

Merged
merged 3 commits into from
Jul 4, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 14 additions & 5 deletions book.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,20 @@
"gitbook": ">=2.5.2",
"title": "JavaScriptの入門書",
"description": "この書籍はES2015以降をベースとしたJavaScript入門書となる予定",
"structure":{
"readme": "README.html.md"
"root": "./source/",
"structure": {
"readme": "index.html.md",
"summary": "README.md"
},
"plugins": [
"include-codeblock",
"japanese-support"
]
}
"japanese-support",
"edit-link"
],
"pluginsConfig": {
"edit-link": {
"base": "https://github.com/asciidwango/js-primer/edit/master/source/",
"label": "このページを編集"
}
}
}
2 changes: 1 addition & 1 deletion gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ gulp.task('test:example', function () {
/**
* *-invalid.js が実行 または パースエラーとなることをテストする
**/
gulp.task('test:example', function () {
gulp.task('test:invalid', function () {
return gulp.src(['./source/**/*-invalid.js', '!source/**/node_modules{,/**}'])
.on('error', function (error) {
console.error(error);
Expand Down
7 changes: 4 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@
"eslint:js": "eslint source/",
"eslint:fix": "eslint --fix source/",
"textlint": "gulp textlint",
"textlint:fix": "summary-to-path | xargs textlint --fix",
"test:example": "gulp test:example test:doc-code",
"test:ch1": "mocha './source/ch1/**/*-test.js'",
"textlint:fix": "summary-to-path ./source/README.md | xargs textlint --fix",
"test:example": "gulp test:example test:invalid test:doc-code",
"test:basic": "mocha './source/basic/**/*-test.js'",
"test": "npm-run-all -l --parallel test:* textlint eslint:* build"
},
"keywords": [
Expand All @@ -33,6 +33,7 @@
"eslint": "^3.0.0",
"eslint-plugin-markdown": "^1.0.0-beta.2",
"gitbook-cli": "^2.1.2",
"gitbook-plugin-edit-link": "^2.0.2",
"gitbook-plugin-include-codeblock": "^1.4.0",
"gitbook-plugin-japanese-support": "0.0.1",
"gitbook-summary-to-path": "^1.0.1",
Expand Down
18 changes: 10 additions & 8 deletions SUMMARY.md → source/README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
# 目次

- 書籍の読み方
- [基礎文法](source/ch1/README.md)
- [JavaScriptとは](source/ch1/basic/README.md)
- [コメント](source/ch1/comments/README.md)
- [基礎文法](basic/README.md)
- [JavaScriptとは](basic/introduction/README.md)
- [コメント](basic/comments/README.md)
- 字句構造
- Strict mode
- [変数と宣言](source/ch1/variables/README.md)
- [値の評価と表示](source/ch1/read-eval-print/README.md)
- [データ型とリテラル](source/ch1/data-type/README.md)
- [条件分岐](source/ch1/condition/README.md)
- [変数と宣言](basic/variables/README.md)
- [値の評価と表示](basic/read-eval-print/README.md)
- [データ型とリテラル](basic/data-type/README.md)
- [条件分岐](basic/condition/README.md)
- 式と演算子
- 文
- String
Expand All @@ -34,7 +36,7 @@
- Proxy
- Unicode
- Intl
- 応用編(ユースケース)
- 応用編ユースケース
- Ajaxで通信
- Node.jsでCLIアプリ
- TODOアプリ
File renamed without changes.
File renamed without changes.
3 changes: 3 additions & 0 deletions source/basic/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# 第1章 基本文法

JavaScriptの基本文法について解説します。
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 0 additions & 2 deletions source/ch1/README.md

This file was deleted.

3 changes: 3 additions & 0 deletions source/index.html.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{% include "./landing/index.html" %}

<!-- TOPページの実際の内容はlandingに書かれています -->
4 changes: 2 additions & 2 deletions README.html.md → source/landing/index.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<link rel="stylesheet" type="text/css" href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css"/>
<link rel="stylesheet" type="text/css" href="./source/landing/css/style.css"/>
<link rel="stylesheet" type="text/css" href="./landing/css/style.css"/>
<!-- Main container -->
<div class="page-container">
<div class="row main" id="js-main">
Expand Down Expand Up @@ -51,7 +51,7 @@ <h3 class="mg-sm">
</form>
</div>
<div class="col-sm-4">
<img src="./source/landing/img/cover.png" alt="Cover Image" class="img-responsive hidden-xs"/>
<img src="./landing/img/cover.png" alt="Cover Image" class="img-responsive hidden-xs"/>
</div>
</div>
</div>
Expand Down