You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is the source for the [Kotlin Web Site](http://kotlinlang.org)
4
+
This is the source for the [http://kotlinlang.org](http://kotlinlang.org).
5
5
6
-
-[Filing bugs](#filing-bugs)
7
6
-[Installation](#installation)
8
-
-[Working with site](#working-with-site)
9
-
-[Run](#run-site)
10
-
-[Data](#data)
11
-
-[Templates](#templates)
12
-
-[Page metadata](#page-metadata)
13
-
-[Writing content](#writing-content)
14
-
15
-
16
-
Filing Bugs
17
-
===========
18
-
We use [YouTrack](http://youtrack.jetbrains.com/issues/KT#) for bug reports and suggestions. Click [here to report an issue](http://youtrack.jetbrains.com/newIssue?project=KT&clearDraft=true&c=Subsystems+Web+Site).
19
-
20
-
Installation
21
-
============
22
-
23
-
## Prerequisites
24
-
25
-
- Python 3. Kotlinlang is a [Flask](http://flask.pocoo.org/)-based site, so you'll need Python 3 to get it working.
26
-
- Ruby + [kramdown](http://kramdown.gettalong.org/installation.html). Python has very poor support for Markdown, so kramdown is used as the Markdown-to-HTML converter.
27
-
-[nodejs](https://nodejs.org/en/) + npm to build frontend assets
After installation of required tools run `npm i` to download all frontend dependencies and `pip install -r requirements.txt` to download backend dependencies.
13
+
1. You will need Docker to run site lifecycle tasks. Installation for [macOS](https://docs.docker.com/docker-for-mac/install/#download-docker-for-mac) and
2. If you want to develop frontend Yarn package manager is also needed ([installation instructions](https://yarnpkg.com/lang/en/docs/install/)).
16
+
Don't forget to install frontend dependencies - `yarn install`.
17
+
3. All specific app parameters stored in env-file. Copy sample file `.env.sample` and rename it to `.env`.
18
+
Change variables values if needed.
32
19
33
-
Working with this site
34
-
======================
20
+
## How to run
35
21
36
-
## Running this site
22
+
-**All in one option (suitable for content authors/writers)**: `docker-compose up`.
23
+
It will build all stuff and create site on [http://localhost:5000](http://localhost:5000).
24
+
-**Developer has 2-step option**:
25
+
-`docker-compose up website` will run only site at [http://localhost:5000](http://localhost:5000).
26
+
-`yarn start` will run webpack-dev-server on [http://localhost:9000](http://localhost:9000).
27
+
This address should be used to development. All pages from origin server will be proxied.
28
+
29
+
<aid="project-structure"></a>
30
+
## Project structure & overview
37
31
38
-
- Use `npm run build` command to build assets. If you are going to modify js/scss files use `npm start` instead.
39
-
- To run site use `python kotlin-website.py` command
40
-
41
-
## Data
32
+
### Data
42
33
43
34
All data is stored in the \*.yml files in folder `_data`:
44
35
@@ -48,19 +39,21 @@ All data is stored in the \*.yml files in folder `_data`:
48
39
It contains a list of videos or other categories. Maximum tree depth level is 3.
49
40
-[events.yml](_data/events.yml) event data.
50
41
51
-
## Templates
42
+
###Templates
52
43
53
44
Kotlinlang uses [Jinja2](http://jinja.pocoo.org/docs/dev/) templates that can be found in templates folder.
54
-
Note that all Markdown files are processed as Jinja templates before being converted to HTML. This allows you to use all Jinja power inside Markdown (for example, build urls with url_for function).
45
+
Note that all Markdown files are processed as Jinja templates before being converted to HTML.
46
+
This allows you to use all Jinja power inside Markdown (for example, build urls with url_for function).
55
47
56
-
## Page metadata
48
+
###Page metadata
57
49
58
50
Every page can have an unlimited number of metadata fields. More information [here](http://jekyllrb.com/docs/frontmatter/).
59
51
The most important of them are the page template (e.g. `layout: reference`) and its type (e.g. `type: tutorial`). `category` and `title` fields are added for future development.
60
52
61
-
## Kotlin grammar reference
53
+
###Kotlin grammar reference
62
54
63
-
The Kotlin grammar reference (grammar.xml) is generated by the [Kotlin grammar generator](https://github.com/JetBrains/kotlin-grammar-generator) from the [Kotlin grammar definition](https://github.com/JetBrains/kotlin/tree/master/grammar).
55
+
The Kotlin grammar reference (grammar.xml) is generated by the [Kotlin grammar generator](https://github.com/JetBrains/kotlin-grammar-generator) from the
0 commit comments