diff --git a/lfsa/en/index.html b/lfsa/en/index.html new file mode 100644 index 0000000..d10c83e --- /dev/null +++ b/lfsa/en/index.html @@ -0,0 +1,134 @@ + + + +
+ +Local File System Access (LFSA) is:
+Client Side Web Apps run solely on your device, they are not related to cloud solutions in any way: nobody can pull the plug on you. +CSWAs use LFSA to keep data at your hard drive, so you have complete control of your data.
+PSKOV static site generator is the first CSWA to use LFSA.
+If you use Linux or macOS released after 2005 (yes, 2005), you only need to download lfsa-201905.py.
+If you use Windows 2000 or newer (excluding Windows ME), you need to:
+If you use Linux or macOS, run LFSA in Terminal this way:
+/path/to/lfsa-201905.py /path/to/dir
+
+Here's how it looks like on macOS Mojave:
+ +If you use Windows, run LFSA in CMD this way:
+C:/path/to/Python/installation/python.exe C:/path/to/lfsa-201905.py C:/path/to/dir
+
+Here's how it looks like on Windows 2000:
+ +As you noticed, LFSA can run on really old operating systems dating back to 2000. That's intentional: we care about users, so we want to cover as many users as possible.
+PSKOV is a static site generator that runs in your web browser. What you see now has also been generated with PSKOV. If you're new to PSKOV, visit education page.
- +PSKOV_ITEM_CONTENTSК Локальной Файловой Системе Доступ (ЛФСД, LFSA) является:
+Сетевые Приложения на Стороне Клиента выполняются исключительно на вашем устройстве, они никак не связаны с облачными решениями: никто не сможет их отключить. +СПСК используют ЛФСД для хранения данных на вашем жёстком диске, поэтому вы полностью владеете своими данными.
+ПСКОВ (генератор статических сайтов) является первым СПСК, использующим ЛФСД.
+Если вы используете Linux или macOS, выпущенные после 2005-го (да, 2005-го), вам необходимо просто загрузить lfsa-201905.py.
+Если вы используете Windows 2000 или новее (за исключением Windows ME), вам необходимо:
+Если вы используете Linux или macOS, запускайте ЛФСД в Терминале следующим образом:
+/путь/до/lfsa-201905.py /путь/до/директории
+
+Вот как это выглядит на macOS Mojave:
+ +Если вы используете Windows, запускайте ЛФСД в CMD следующим образом:
+C:/путь/до/установки/Python/python.exe C:/путь/до/lfsa-201905.py C:/путь/до/директории
+
+Вот как это выглядит на Windows 2000:
+ +Как вы заметили, ЛФСД может работать на действительно старых операционных системах, родом из 2000-х. Это осознанный выбор: мы заботимся о пользователях, поэтому хотим предоставить наш инструмент как можно большему числу пользователей.
+In this document we teach how to install PSKOV dependencies.
-Estimated completion time: ?? minutes.
+In this document we describe PSKOV dependencies and how to get them.
+Estimated completion time: 5 minutes.
Table of contents
We designed PSKOV to run inside web browsers. Hence, here is a list of PSKOV dependencies:
+We designed PSKOV to run inside web browsers. Here is what you need to run PSKOV:
№ | -Dependency | -Note | +PSKOV dependency | +Notes |
---|---|---|---|---|
2 | -Local file system access (LFSA) | -LFSA gives PSKOV access to your local file system | +Local file system access | +LFSA gives PSKOV access to your local file system. Install LFSA to be able to use PSKOV. |
Since PSKOV is a client side JavaScript application, it has no direct access to your local file system to generate files. That's why we have also created LFSA, a tiny Python server to provide read/write access to your local file system at 8000 port. LFSA is under 200 lines of code, feel free to inspect it to make sure we don't steal your data.
- -TODO
- -Tell Showdown.JS is used to convert Markdown to HTML, so users should refer to Showdown.JS for rules.
+Note: install LFSA to be able to use PSKOV.
+ +PSKOV:
+LFSA:
+In this document we create a simple static web site with two pages.
-Estimated completion time: ? minutes.
+Estimated completion time: 10 minutes.
Table of contents
cfg
fileitem.template
fileindex.md
and cv.md
filesabout.md
and cv.md
filesLet's look at their contents closer.
@@ -149,7 +145,7 @@ item = item.templateitem
Note: style was collapsed for brevity.
-As you can see, item.template
is an average HTML file with two constants specified:
As you can see, item.template
is an average HTML file with two PSKOV constants specified:
Slug: |
-Tells PSKOV that this particular Markdown file should be saved under <slug>.html filename |
+Tells PSKOV that particular Markdown file should be saved under <slug>.html filename |
The rest of index.md
contents is what any Markdown file looks like.
The rest of about.md
contents is what any Markdown file looks like.
Note: cv
page is referenced as cv.html
, not cv.md
cv.md
file has the following contents:
Title: Curriculum vitae
@@ -267,8 +266,8 @@ PSKOV_ITEM_CONTENTS
As you can see, there's nothing new in cv.md
except for a Markdown table.
05. Launch LFSA
-Launch LFSA so that it points to directory with the files we just observed:
-$ /path/to/local-file-system-access.py /path/to/dir/01.TwoPages
+Launch LFSA so that it points to directory with the files we just observed:
+$ /path/to/lfsa-201905.py /path/to/dir/01.TwoPages
You should see output similar to this:
DIR: '/Users/kornerr/p/site-pskov-sample/01.TwoPages'
@@ -283,10 +282,69 @@ PORT: '8000'
Path:
points to the same directory you specified before
Input directory:
and Item template:
have values from cfg
Press Generate
button to generate HTML files right where Markdown ones reside
-Open generated index.html
from the site's directory
+Open generated about.html
from the site's directory
You should see your web site running locally
-Take time to observe your new shiny personal web site consisting of two pages.
+
+07. Summary
+You have successfully generated a web site with two pages. Check out the result.
+Introduced PSKOV constants include:
+
+
+
+PSKOV constant
+Description
+
+
+
+
+PSKOV_ITEM_TITLE
+Provides title from Title:
part of page's header section
+
+
+PSKOV_ITEM_CONTENTS
+Provides HTML contents generated out of Markdown contents
+
+
+
+Introduced configuration keys include:
+
+
+
+Key
+Description
+
+
+
+
+input
+Points to a directory where item
's file is located
+
+
+item
+Points to an HTML template file that is used to generate HTML files out of Markdown ones
+
+
+
+Introduced header constants include:
+
+
+
+Header constant
+Description
+
+
+
+
+Title:
+Provides value for PSKOV_ITEM_TITLE
constant when generating HTML out of Markdown
+
+
+Slug:
+Tells PSKOV that particular Markdown file should be saved under <slug>.html
filename
+
+
+
In this document we add language selection.
-Estimated completion time: ? minutes.
+Estimated completion time: 10 minutes.
Table of contents
- 01. Localization
@@ -110,6 +105,7 @@ Education: 04. Language
- 03. Investigate template files
- 04. Investigate Markdown files
- 05. Launch LFSA and generate the site
+- 06. Summary
01. Localization
@@ -118,10 +114,10 @@ Education: 04. Language
cfg
en/item.template
-en/index.md
+en/about.md
en/cv.md
ru/item.template
-ru/index.md
+ru/about.md
ru/cv.md
Let's look at the contents of these files closer.
@@ -143,7 +139,7 @@ item = item.template
<body>
<div id="header">
<strong>Serov</strong>
- <a href="index.html">About me</a>
+ <a href="about.html">About me</a>
<a href="cv.html">CV</a>
<div id="lang">
<a href="../en/PSKOV_ITEM_URL">EN</a>
@@ -160,7 +156,7 @@ item = item.template
<body>
<div id="header">
<strong>Серов</strong>
- <a href="index.html">Обо мне</a>
+ <a href="about.html">Обо мне</a>
<a href="cv.html">Резюме</a>
<div id="lang">
<a href="../en/PSKOV_ITEM_URL">EN</a>
@@ -189,14 +185,14 @@ item = item.template
PSKOV_ITEM_URL
-Provides <slug>.html
value for the page
+Provides generated page's file name: <slug>.html
As you see, PSKOV_ITEM_URL
is all you need to have your page in as many languages as you please.
en/index.md
and en/cv.md
files look exactly as before. ru/index.md
and ru/cv.md
are simply Russian variants of the same pages.
en/about.md
and en/cv.md
files look almost exactly as before. ru/about.md
and ru/cv.md
are simply Russian variants of the same pages.
For example, ru/cv.md
has the following contents:
Title: Резюме
Slug: cv
@@ -215,17 +211,34 @@ item = item.template
Note: Russian page has exactly the same Slug:
value as English one.
05. Launch LFSA and generate the site
-Launch LFSA so that it points to directory with the files we just observed:
-$ /path/to/local-file-system-access.py /path/to/dir/02.Language
+Launch LFSA so that it points to directory with the files we just observed:
+$ /path/to/lfsa-201905.py /path/to/dir/02.Language
Generate the site:
- Go to Tool page
- Press
Generate
button
-- Open generated
en/index.html
or ru/index.html
from the site's directory locally
+- Open generated
en/about.html
or ru/about.html
from the site's directory locally
- Switch language to verify language selection works fine
-Take time to observe just how little effort you spent to have your web site localized.
+
+06. Summary
+You have successfully added language selection. Check out the result.
+Introduced PSKOV constants include:
+
+
+
+PSKOV constant
+Description
+
+
+
+
+PSKOV_ITEM_URL
+Provides generated page's file name: <slug>.html
+
+
+
< Back | +Index | +Next > | +
---|---|---|
04. Language | +Education | +Not available | +
In this document we create "dynamic" pages like blog posts.
+Estimated completion time: 20 minutes.
+Table of contents
+cfg
fileSo, you have your web site in both English and Russian. You start to feel the need to constantly share your thoughts with the world as blog posts.
+You set on to create the following directory structure:
+cfg
en/blog/
item.template
index.template
preview.template
pagination.template
pagination.prev.template
pagination.next.template
1885.md
1886.01.md
1886.02.md
1887.01.md
1887.02.md
1888.md
1896.md
1899.md
en/page/
item.template
about.md
cv.md
ru/blog/
item.template
index.template
preview.template
pagination.template
pagination.prev.template
pagination.next.template
1885.md
1886.01.md
1886.02.md
1887.01.md
1887.02.md
1888.md
1896.md
1899.md
ru/page/
item.template
about.md
cv.md
Let's look at the contents of these files closer.
+ +cfg
filecfg
file has the following contents:
input = en/page;ru/page;en/blog;ru/blog
+item = item.template
+preview = preview.template
+index = index.template
+paginationPrev = pagination.prev.template
+paginationNext = pagination.next.template
+paginationPrevNext = pagination.template
+previewSize = 200
+previewEnding = . . .
+previewsPerPage = 3
+previewPageBaseName = index
+
+Apart from already used input
and item
keys, we have quite a lot of new ones. Let's break them down:
Key | +Description | +
---|---|
preview |
+Points to an HTML template file that is used to generate HTML previews out of the first previewSize (approximately) characters of Markdown files |
+
index |
+Points to an HTML template file that is used to generate HTML index (summary) files to host previews | +
paginationPrev |
+Points to an HTML template file that is used to generate pagination section used by the last index (summary) file | +
paginationNext |
+Points to an HTML template file that is used to generate pagination section used by the first index (summary) file | +
paginationPrevNext |
+Points to an HTML template file that is used to generate pagination section used by index (summary) files except the ones at the beginning and at the end | +
previewSize |
+How many characters (approximately) to take out of a Markdown file to generate an HTML preview | +
previewEnding |
+String to use at the end of HTML previews | +
previewsPerPage |
+Number of HTML previews hosted by single index (summary) file | +
previewsPageBaseName |
+Index (summary) file base name | +
In our case:
+200
characters in size (approximately). . .
string at the end of each preview3
previews maximumindex.html
, index2.html
, index3.html
, etc.en/blog/item.template
contents:
- - - - Collapsed for brevity - - - -
+<body>
+ <div id="header">
+ <strong>Serov</strong>
+ <a href="../../en/blog/index.html">Blog</a>
+ <a href="../../en/page/about.html">About me</a>
+ <a href="../../en/page/cv.html">CV</a>
+ <div id="lang">
+ <a href="../../en/blog/PSKOV_ITEM_URL">EN</a>
+ <a href="../../ru/blog/PSKOV_ITEM_URL">RU</a>
+ </div>
+ </div>
+ <center>
+ <h1>In the blog...</h1>
+ <div class="contents">
+ <h2 class="itemTitle">
+ <a href="PSKOV_ITEM_URL">PSKOV_ITEM_TITLE</a>
+ </h2>
+ <p class="itemDate">PSKOV_ITEM_DATE</p>
+PSKOV_ITEM_CONTENTS
+ </div>
+ <div id="footer">
+ This sample web site has been generated by <a href="http://opengamestudio.org/pskov">PSKOV</a>.
+ </div>
+ </center>
+</body>
+- - - - Collapsed for brevity - - - -
+
ru/blog/item.template
contents:
- - - - Collapsed for brevity - - - -
+<body>
+ <div id="header">
+ <strong>Серов</strong>
+ <a href="../../ru/blog/index.html">Блог</a>
+ <a href="../../ru/page/about.html">Обо мне</a>
+ <a href="../../ru/page/cv.html">Резюме</a>
+ <div id="lang">
+ <a href="../../en/blog/PSKOV_ITEM_URL">EN</a>
+ <a href="../../ru/blog/PSKOV_ITEM_URL">RU</a>
+ </div>
+ </div>
+ <center>
+ <h1>В блоге...</h1>
+ <div class="contents">
+ <h2 class="itemTitle">
+ <a href="PSKOV_ITEM_URL">PSKOV_ITEM_TITLE</a>
+ </h2>
+ <p class="itemDate">PSKOV_ITEM_DATE</p>
+PSKOV_ITEM_CONTENTS
+ </div>
+ <div id="footer">
+ Этот пример сайта сгенерирован <a href="http://opengamestudio.org/pskov">ПСКОВОМ</a>.
+ </div>
+ </center>
+</body>
+- - - - Collapsed for brevity - - - -
+
Note: beginning and ending were collapsed for brevity.
+As you can see, both files look similar to item.template
files we saw before.
The changes include:
+page
directory and first index (summary) file in blog
directorycontents
section as a link to complete pageDate reference uses new PSKOV_ITEM_DATE
constant:
PSKOV constant | +Description | +
---|---|
PSKOV_ITEM_DATE |
+Provides date from Date: part of page's header section |
+
en/blog/preview.template
contents:
<div class="contents">
+ <h2 class="itemTitle">
+ <a href="PSKOV_ITEM_URL">PSKOV_ITEM_TITLE</a>
+ </h2>
+ <p class="itemDate">PSKOV_ITEM_DATE</p>
+PSKOV_PREVIEW
+ <div class="itemMore">
+ <a href="PSKOV_ITEM_URL">Continue reading</a>
+ </div>
+</div>
+
ru/blog/preview.template
contents:
<div class="contents">
+ <h2 class="itemTitle">
+ <a href="PSKOV_ITEM_URL">PSKOV_ITEM_TITLE</a>
+ </h2>
+ <p class="itemDate">PSKOV_ITEM_DATE</p>
+PSKOV_PREVIEW
+ <div class="itemMore">
+ <a href="PSKOV_ITEM_URL">Читать дальше</a>
+ </div>
+</div>
+
Previews have no <head>
, <body>
, and similar full page HTML tags. Previews represent sections inserted into index (summary) files.
Preview itself is referenced by PSKOV_PREVIEW
constant:
PSKOV constant | +Description | +
---|---|
PSKOV_PREVIEW |
+Provides contents from a Markdown file limited by previewSize characters (approximately) |
+
en/blog/index.template
contents:
- - - - Collapsed for brevity - - - -
+<body>
+ <div id="header">
+ <strong>Serov</strong>
+ <a href="../../en/blog/index.html">Blog</a>
+ <a href="../../en/page/about.html">About me</a>
+ <a href="../../en/page/cv.html">CV</a>
+ <div id="lang">
+ <a href="../../en/blog/PSKOV_INDEX_URL">EN</a>
+ <a href="../../ru/blog/PSKOV_INDEX_URL">RU</a>
+ </div>
+ </div>
+ <center>
+ <h1>Blog</h1>
+PSKOV_PREVIEWS
+PSKOV_PAGINATION
+ <div id="footer">
+ This sample web site has been generated by <a href="http://opengamestudio.org/pskov">PSKOV</a>.
+ </div>
+ </center>
+</body>
+- - - - Collapsed for brevity - - - -
+
ru/blog/index.template
contents:
- - - - Collapsed for brevity - - - -
+<body>
+ <div id="header">
+ <strong>Серов</strong>
+ <a href="../../ru/blog/index.html">Блог</a>
+ <a href="../../ru/page/about.html">Обо мне</a>
+ <a href="../../ru/page/cv.html">Резюме</a>
+ <div id="lang">
+ <a href="../../en/blog/PSKOV_INDEX_URL">EN</a>
+ <a href="../../ru/blog/PSKOV_INDEX_URL">RU</a>
+ </div>
+ </div>
+ <center>
+ <h1>Блог</h1>
+PSKOV_PREVIEWS
+PSKOV_PAGINATION
+ <div id="footer">
+ Этот пример сайта сгенерирован <a href="http://opengamestudio.org/pskov">ПСКОВОМ</a>.
+ </div>
+ </center>
+</body>
+- - - - Collapsed for brevity - - - -
+
Notes:
+PSKOV_INDEX_URL
constant is used to provide language selectionIndex (summary) files are used to host previews.
+Here are new PSKOV constants explained:
+PSKOV constant | +Description | +
---|---|
PSKOV_INDEX_URL |
+Provides generated page's file name: <previewsPageBaseName><id>.html |
+
PSKOV_PREVIEWS |
+Provides a combination of PSKOV_PREVIEW sections |
+
PSKOV_PAGINATION |
+Provides pagination section to navigate index (summary) pages | +
Pagination templates represent sections used to navigate index (summary) pages.
+There are free pagination templates:
+Pagination template | +Description | +
---|---|
prev | +Is used for the last index (summary) page because we can only go backwards | +
next | +Is used for the first index (summary) page because we can only go forward | +
both | +Is used for intermediate index (summary) pages because we can either go backwards, or forward | +
Let's look at English pagination templates:
+en/blog/pagination.prev.template
contents:
<p>Page PSKOV_PAGE_ID of PSKOV_PAGES_COUNT</p>
+<p>
+ <a href="PSKOV_PREV_PAGE_URL">« Newer</a>
+</p>
+
en/blog/pagination.next.template
contents:
<p>Page PSKOV_PAGE_ID of PSKOV_PAGES_COUNT</p>
+<p>
+ <a href="PSKOV_NEXT_PAGE_URL">Older »</a>
+</p>
+
en/blog/pagination.template
contents:
<p>Page PSKOV_PAGE_ID of PSKOV_PAGES_COUNT</p>
+<p>
+ <a href="PSKOV_PREV_PAGE_URL">« Newer</a>
+ <a href="PSKOV_NEXT_PAGE_URL">Older »</a>
+</p>
+
Russian counterparts look similar. Here's ru/blog/pagination.template
contents:
<p>Страница PSKOV_PAGE_ID из PSKOV_PAGES_COUNT</p>
+<p>
+ <a href="PSKOV_PREV_PAGE_URL">« Новее</a>
+ <a href="PSKOV_NEXT_PAGE_URL">Старее »</a>
+</p>
+
+Here are new PSKOV constants we used:
+PSKOV constant | +Description | +
---|---|
PSKOV_PAGE_ID |
+Provides index (summary) page id starting from 1 |
+
PSKOV_PAGES_COUNT |
+Provides total number of index (summary) pages generated | +
PSKOV_PREV_PAGE_URL |
+Provides previous index (summary) page file name | +
PSKOV_NEXT_PAGE_URL |
+Provides next index (summary) page file name | +
Markdown files represent blog posts and they look almost like Markdown files for pages. Here's en/blog/1885.md
contents:
Title: Bullocks
+ Date: 1885
+ Slug: 1885.01.bullocks
+
+ ![Bullocks][bullocks]
+
+ I've been painting "Bullocks" sketch while I was staying in Odessa at Kuznetsov's in 1885.
+
+ [bullocks]: https://upload.wikimedia.org/wikipedia/commons/c/cb/Walentin_Aleksandrovich_Serov_Bullocks.jpg
+
+Date is used to sort blog posts by date in ascending order:
+Header constant | +Description | +
---|---|
Date: |
+Provides value for PSKOV_ITEM_DATE constant when generating HTML out of Markdown |
+
Launch LFSA so that it points to directory with the files we just observed:
+$ /path/to/lfsa-201905.py /path/to/dir/03.Blog
+
+Generate the site:
+Generate
buttonen/blog/index.html
or ru/blog/index.html
from the site's directory locallyYou have successfully generated a web site with "constant" and "dynamic" pages. Check out the result.
+Introduced PSKOV constants include:
+PSKOV constant | +Description | +
---|---|
PSKOV_ITEM_DATE |
+Provides date from Date: part of page's header section |
+
PSKOV_PREVIEW |
+Provides contents from a Markdown file limited by previewSize characters (approximately) |
+
PSKOV_INDEX_URL |
+Provides generated page's file name: <previewsPageBaseName><id>.html |
+
PSKOV_PREVIEWS |
+Provides a combination of PSKOV_PREVIEW sections |
+
PSKOV_PAGINATION |
+Provides pagination section to navigate index (summary) pages | +
PSKOV_PAGE_ID |
+Provides index (summary) page id starting from 1 |
+
PSKOV_PAGES_COUNT |
+Provides total number of index (summary) pages generated | +
PSKOV_PREV_PAGE_URL |
+Provides previous index (summary) page file name | +
PSKOV_NEXT_PAGE_URL |
+Provides next index (summary) page file name | +
Introduced configuration keys include:
+Key | +Description | +
---|---|
preview |
+Points to an HTML template file that is used to generate HTML previews out of the first previewSize (approximately) characters of Markdown files |
+
index |
+Points to an HTML template file that is used to generate HTML index (summary) files to host previews | +
paginationPrev |
+Points to an HTML template file that is used to generate pagination section used by the last index (summary) file | +
paginationNext |
+Points to an HTML template file that is used to generate pagination section used by the first index (summary) file | +
paginationPrevNext |
+Points to an HTML template file that is used to generate pagination section used by index (summary) files except the ones at the beginning and at the end | +
previewSize |
+How many characters (approximately) to take out of a Markdown file to generate an HTML preview | +
previewEnding |
+String to use at the end of HTML previews | +
previewsPerPage |
+Number of HTML previews hosted by single index (summary) file | +
previewsPageBaseName |
+Index (summary) file base name | +
Introduced header constants include:
+Header constant | +Description | +
---|---|
Date: |
+Provides value for PSKOV_ITEM_DATE constant when generating HTML out of Markdown |
+
This was the final document to make you proficient in generating static sites with PSKOV. If you like what we do, support us by joining our group at Twitter, Facebook, or VK.
+Now use PSKOV to generate your very own web site!
+< Back | +Index | +Next > | +
---|---|---|
04. Language | +Education | +Not available | +
PSKOV_ITEM_DATE
+PSKOV_ITEM_CONTENTS +PSKOV_ITEM_DATE
+PSKOV_ITEM_CONTENTS +Page PSKOV_PAGE_ID of PSKOV_PAGES_COUNT
++ « Newer +
+ ``` + +* `en/blog/pagination.next.template` contents: + + ``` +Page PSKOV_PAGE_ID of PSKOV_PAGES_COUNT
++ Older » +
+ ``` + +* `en/blog/pagination.template` contents: + + ``` +Page PSKOV_PAGE_ID of PSKOV_PAGES_COUNT
+ + ``` + +Russian counterparts look similar. Here's `ru/blog/pagination.template` contents: + +``` +Страница PSKOV_PAGE_ID из PSKOV_PAGES_COUNT
+ +``` + +Here are new **PSKOV** constants we used: + +| PSKOV constant | Description | +|---|---| +| `PSKOV_PAGE_ID` | Provides index (summary) page id starting from `1` | +| `PSKOV_PAGES_COUNT` | Provides total number of index (summary) pages generated | +| `PSKOV_PREV_PAGE_URL` | Provides previous index (summary) page file name | +| `PSKOV_NEXT_PAGE_URL` | Provides next index (summary) page file name | + + + +## 07. Investigate Markdown files + +Markdown files represent blog posts and they look almost like Markdown files for pages. Here's `en/blog/1885.md` contents: + +``` + Title: Bullocks + Date: 1885 + Slug: 1885.01.bullocks + + ![Bullocks][bullocks] + + I've been painting "Bullocks" sketch while I was staying in Odessa at Kuznetsov's in 1885. + + [bullocks]: https://upload.wikimedia.org/wikipedia/commons/c/cb/Walentin_Aleksandrovich_Serov_Bullocks.jpg +``` + +Date is used to sort blog posts by date in ascending order: + +| Header constant | Description | +|---|---| +| `Date:` | Provides value for `PSKOV_ITEM_DATE` constant when generating HTML out of Markdown | + + + +## 08. Launch LFSA and generate the site + +Launch [LFSA][lfsa] so that it points to directory with the files we just observed: + +``` +$ /path/to/lfsa-201905.py /path/to/dir/03.Blog +``` + +Generate the site: + +* Go to [Tool][tool] page +* Press `Generate` button +* Open generated `en/blog/index.html` or `ru/blog/index.html` from the site's directory locally +* Navigate index (summary) pages to make sure everything works fine + + + +## 09. Summary + +You have successfully generated a web site with "constant" and "dynamic" pages. [Check out the result][03-sample]. + +Introduced PSKOV constants include: + +| PSKOV constant | Description | +|---|---| +| `PSKOV_ITEM_DATE` | Provides date from `Date:` part of page's header section | +| `PSKOV_PREVIEW` | Provides contents from a Markdown file limited by `previewSize` characters (approximately) | +| `PSKOV_INDEX_URL` | Provides generated page's file name: `Here you can find a set of documents to make you proficient in generating static sites with PSKOV. You are encouraged to read the documents in order.
+Here is a set of documents to make you proficient in generating static sites with PSKOV. We encourage you to read the documents in order.
+№ | -Document | +Item | Details | -Demonstration | -Estimated completion time |
---|---|---|---|---|---|
1 | -Why | +Description | Find out why PSKOV was created | -- | +|
Estimated completion time | 5 minutes |
Item | +Details | +||||
---|---|---|---|---|---|
2 | -Dependencies | +Description | Install dependencies to start using PSKOV | -- | -?? minutes |
3 | -Site | +Estimated completion time | +5 minutes | +
Item | +Details | +|||||
---|---|---|---|---|---|---|
Description | Learn how to create a simple static web site with two pages | -TODO Link | -?? minutes | |||
4 | -Language | -? | -TODO Link | -? | +Estimated completion time | +10 minutes | +
Demonstration | +TwoPages | +|||||
Introduced PSKOV constants | +
|
+|||||
Introduced configuration keys | +
|
+|||||
Introduced header constants | +
|
+
Item | +Details | +
---|---|
Description | +Learn how to add language selection | +
Estimated completion time | +10 minutes | +
Demonstration | +Language | +
Introduced PSKOV constants | +
|
+
Item | +Details | +|||||
---|---|---|---|---|---|---|
Description | +Learn how to create "dynamic" pages like blog posts | +|||||
Estimated completion time | +20 minutes | +|||||
Demonstration | +Blog | +|||||
Introduced PSKOV constants | +
|
+|||||
Introduced configuration keys | +
|
|||||
5 | -Blog | -? | -TODO Link | -? | +Introduced header constants | +
|
If you like what we do, support us by joining our group at Twitter, Facebook, or VK.
- Local file system access - | -|
Path: | -Updating... | -
- Configuration - - | -|
Input directory: | -- |
Item template: | -- |
Preview template: | -- |
Index template: | -- |
Pagination 'Previous' template: | -- |
Pagination 'Next' template: | -- |
Pagination 'Previous/Next' template: | -- |
Preview characters limit: | -- |
Preview ending string: | -- |
Previews per page: | -- |
Preview page base name: | -- |
- News - - | -|
Log | -|
- |
+ PSKOV is a static site generator that runs in your web browser. + What you see now has also been generated with PSKOV. + If you're new to PSKOV, visit education page. +
++ Local file system access + | +|
Path: | +Updating... | +
+ Configuration + + | +|
Input directory: | ++ |
Item template: | ++ |
Preview template: | ++ |
Index template: | ++ |
Pagination 'Previous' template: | ++ |
Pagination 'Next' template: | ++ |
Pagination 'Previous/Next' template: | ++ |
Preview characters limit: | ++ |
Preview ending string: | ++ |
Previews per page: | ++ |
Preview page base name: | ++ |
+ News + + | +|
Log | +|
+ |