mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-12 08:37:25 +02:00
parent
8db87ffa39
commit
09d11ceb49
742 changed files with 8947 additions and 8877 deletions
File diff suppressed because one or more lines are too long
|
@ -94,7 +94,7 @@
|
||||||
<p>For example, at <code>website/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
<p>For example, at <code>website/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">https://twitter.com/foobarbaz</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">https://twitter.com/foobarbaz</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -94,7 +94,7 @@
|
||||||
<p>For example, at <code>website/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
<p>For example, at <code>website/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">https://twitter.com/foobarbaz</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">https://twitter.com/foobarbaz</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -109,7 +109,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
||||||
|
@ -122,7 +122,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -109,7 +109,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
||||||
|
@ -122,7 +122,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -141,7 +141,7 @@
|
||||||
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
||||||
...
|
...
|
||||||
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
||||||
<span class="hljs-attr">baseUrl</span>: <span class="hljs-string">'/testProject/'</span>,
|
baseUrl: <span class="hljs-string">'/testProject/'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
||||||
...
|
...
|
||||||
|
@ -211,23 +211,23 @@
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
git config --global user.name "<YOUR_NAME>"
|
git config --global user.name "<YOUR_NAME>"
|
||||||
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
||||||
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
||||||
|
@ -264,7 +264,7 @@ e.g.</li>
|
||||||
<span class="hljs-attr"> branches:</span>
|
<span class="hljs-attr"> branches:</span>
|
||||||
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
<span class="hljs-attr"> - run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
||||||
|
@ -285,11 +285,11 @@ e.g.</li>
|
||||||
<span class="hljs-attr">cache:</span>
|
<span class="hljs-attr">cache:</span>
|
||||||
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
||||||
<span class="hljs-attr">script:</span>
|
<span class="hljs-attr">script:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">></span> <span class="hljs-string">~/.netrc</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">> ~/.netrc
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">cd</span> <span class="hljs-string">website</span> <span class="hljs-string">&&</span> <span class="hljs-string">yarn</span> <span class="hljs-string">install</span> <span class="hljs-string">&&</span> <span class="hljs-string">GIT_USER="${GH_NAME}"</span> <span class="hljs-string">yarn</span> <span class="hljs-string">run</span> <span class="hljs-string">publish-gh-pages</span>
|
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
|
||||||
</code></pre>
|
</span></code></pre>
|
||||||
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
||||||
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
||||||
|
|
|
@ -141,7 +141,7 @@
|
||||||
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
||||||
...
|
...
|
||||||
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
||||||
<span class="hljs-attr">baseUrl</span>: <span class="hljs-string">'/testProject/'</span>,
|
baseUrl: <span class="hljs-string">'/testProject/'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
||||||
...
|
...
|
||||||
|
@ -211,23 +211,23 @@
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
git config --global user.name "<YOUR_NAME>"
|
git config --global user.name "<YOUR_NAME>"
|
||||||
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
||||||
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
||||||
|
@ -264,7 +264,7 @@ e.g.</li>
|
||||||
<span class="hljs-attr"> branches:</span>
|
<span class="hljs-attr"> branches:</span>
|
||||||
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
<span class="hljs-attr"> - run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
||||||
|
@ -285,11 +285,11 @@ e.g.</li>
|
||||||
<span class="hljs-attr">cache:</span>
|
<span class="hljs-attr">cache:</span>
|
||||||
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
||||||
<span class="hljs-attr">script:</span>
|
<span class="hljs-attr">script:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">></span> <span class="hljs-string">~/.netrc</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">> ~/.netrc
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">cd</span> <span class="hljs-string">website</span> <span class="hljs-string">&&</span> <span class="hljs-string">yarn</span> <span class="hljs-string">install</span> <span class="hljs-string">&&</span> <span class="hljs-string">GIT_USER="${GH_NAME}"</span> <span class="hljs-string">yarn</span> <span class="hljs-string">run</span> <span class="hljs-string">publish-gh-pages</span>
|
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
|
||||||
</code></pre>
|
</span></code></pre>
|
||||||
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
||||||
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
||||||
|
|
|
@ -206,17 +206,17 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<p><a href="/docs/en/1.10.x/doc-markdown">Syntax highlighting</a> options:</p>
|
<p><a href="/docs/en/1.10.x/doc-markdown">Syntax highlighting</a> options:</p>
|
||||||
<pre><code class="hljs css language-js">{
|
<pre><code class="hljs css language-js">{
|
||||||
<span class="hljs-comment">// ...</span>
|
<span class="hljs-comment">// ...</span>
|
||||||
<span class="hljs-attr">highlight</span>: {
|
highlight: {
|
||||||
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
||||||
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
||||||
<span class="hljs-attr">theme</span>: <span class="hljs-string">'default'</span>,
|
theme: <span class="hljs-string">'default'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
||||||
<span class="hljs-attr">version</span>: <span class="hljs-string">'9.12.0'</span>,
|
version: <span class="hljs-string">'9.12.0'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
||||||
<span class="hljs-attr">hljs</span>: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
hljs: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
||||||
<span class="hljs-comment">// do something here</span>
|
<span class="hljs-comment">// do something here</span>
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -224,10 +224,10 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
||||||
|
|
||||||
<span class="hljs-attr">defaultLang</span>: <span class="hljs-string">'javascript'</span>,
|
defaultLang: <span class="hljs-string">'javascript'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
||||||
<span class="hljs-attr">themeUrl</span>: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
themeUrl: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
@ -291,12 +291,12 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
||||||
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
||||||
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
||||||
<span class="hljs-attr">defaultVersionShown</span>: <span class="hljs-string">'1.0.0'</span>,
|
defaultVersionShown: <span class="hljs-string">'1.0.0'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
||||||
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
||||||
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
||||||
<span class="hljs-attr">headerLinks</span>: [
|
headerLinks: [
|
||||||
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
||||||
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
||||||
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
||||||
|
|
|
@ -206,17 +206,17 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<p><a href="/docs/en/1.10.x/doc-markdown">Syntax highlighting</a> options:</p>
|
<p><a href="/docs/en/1.10.x/doc-markdown">Syntax highlighting</a> options:</p>
|
||||||
<pre><code class="hljs css language-js">{
|
<pre><code class="hljs css language-js">{
|
||||||
<span class="hljs-comment">// ...</span>
|
<span class="hljs-comment">// ...</span>
|
||||||
<span class="hljs-attr">highlight</span>: {
|
highlight: {
|
||||||
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
||||||
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
||||||
<span class="hljs-attr">theme</span>: <span class="hljs-string">'default'</span>,
|
theme: <span class="hljs-string">'default'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
||||||
<span class="hljs-attr">version</span>: <span class="hljs-string">'9.12.0'</span>,
|
version: <span class="hljs-string">'9.12.0'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
||||||
<span class="hljs-attr">hljs</span>: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
hljs: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
||||||
<span class="hljs-comment">// do something here</span>
|
<span class="hljs-comment">// do something here</span>
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -224,10 +224,10 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
||||||
|
|
||||||
<span class="hljs-attr">defaultLang</span>: <span class="hljs-string">'javascript'</span>,
|
defaultLang: <span class="hljs-string">'javascript'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
||||||
<span class="hljs-attr">themeUrl</span>: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
themeUrl: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
@ -291,12 +291,12 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
||||||
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
||||||
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
||||||
<span class="hljs-attr">defaultVersionShown</span>: <span class="hljs-string">'1.0.0'</span>,
|
defaultVersionShown: <span class="hljs-string">'1.0.0'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
||||||
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
||||||
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
||||||
<span class="hljs-attr">headerLinks</span>: [
|
headerLinks: [
|
||||||
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
||||||
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
||||||
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
||||||
|
|
|
@ -266,11 +266,11 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
|
@ -287,12 +287,12 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
- crowdin --config crowdin.yaml download -b master
|
- crowdin --config crowdin.yaml download -b master
|
||||||
# build and publish website
|
# build and publish website
|
||||||
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
||||||
|
|
|
@ -266,11 +266,11 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
|
@ -287,12 +287,12 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
- crowdin --config crowdin.yaml download -b master
|
- crowdin --config crowdin.yaml download -b master
|
||||||
# build and publish website
|
# build and publish website
|
||||||
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
||||||
|
|
|
@ -85,13 +85,13 @@
|
||||||
<h2><a class="anchor" aria-hidden="true" id="put-the-site-online"></a><a href="#put-the-site-online" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Put the Site Online</h2>
|
<h2><a class="anchor" aria-hidden="true" id="put-the-site-online"></a><a href="#put-the-site-online" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Put the Site Online</h2>
|
||||||
<p>Kill the web server first by pressing Cmd + C or Ctrl + C depending on your operating system.</p>
|
<p>Kill the web server first by pressing Cmd + C or Ctrl + C depending on your operating system.</p>
|
||||||
<p>In <code>website/siteConfig.js</code>, fill in the following fields:</p>
|
<p>In <code>website/siteConfig.js</code>, fill in the following fields:</p>
|
||||||
<pre><code class="hljs"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs">const siteConfig = {
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
||||||
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
||||||
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
||||||
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<ol start="2">
|
<ol start="2">
|
||||||
|
|
|
@ -85,13 +85,13 @@
|
||||||
<h2><a class="anchor" aria-hidden="true" id="put-the-site-online"></a><a href="#put-the-site-online" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Put the Site Online</h2>
|
<h2><a class="anchor" aria-hidden="true" id="put-the-site-online"></a><a href="#put-the-site-online" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Put the Site Online</h2>
|
||||||
<p>Kill the web server first by pressing Cmd + C or Ctrl + C depending on your operating system.</p>
|
<p>Kill the web server first by pressing Cmd + C or Ctrl + C depending on your operating system.</p>
|
||||||
<p>In <code>website/siteConfig.js</code>, fill in the following fields:</p>
|
<p>In <code>website/siteConfig.js</code>, fill in the following fields:</p>
|
||||||
<pre><code class="hljs"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs">const siteConfig = {
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
||||||
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
||||||
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
||||||
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<ol start="2">
|
<ol start="2">
|
||||||
|
|
|
@ -94,7 +94,7 @@
|
||||||
<p>For example, at <code>website/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
<p>For example, at <code>website/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">https://twitter.com/foobarbaz</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">https://twitter.com/foobarbaz</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -94,7 +94,7 @@
|
||||||
<p>For example, at <code>website/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
<p>For example, at <code>website/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">https://twitter.com/foobarbaz</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">https://twitter.com/foobarbaz</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -109,7 +109,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
||||||
|
@ -122,7 +122,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -109,7 +109,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
||||||
|
@ -122,7 +122,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -141,7 +141,7 @@
|
||||||
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
||||||
...
|
...
|
||||||
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
||||||
<span class="hljs-attr">baseUrl</span>: <span class="hljs-string">'/testProject/'</span>,
|
baseUrl: <span class="hljs-string">'/testProject/'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
||||||
...
|
...
|
||||||
|
@ -211,23 +211,23 @@
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
git config --global user.name "<YOUR_NAME>"
|
git config --global user.name "<YOUR_NAME>"
|
||||||
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
||||||
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
||||||
|
@ -264,7 +264,7 @@ e.g.</li>
|
||||||
<span class="hljs-attr"> branches:</span>
|
<span class="hljs-attr"> branches:</span>
|
||||||
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
<span class="hljs-attr"> - run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
||||||
|
@ -285,11 +285,11 @@ e.g.</li>
|
||||||
<span class="hljs-attr">cache:</span>
|
<span class="hljs-attr">cache:</span>
|
||||||
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
||||||
<span class="hljs-attr">script:</span>
|
<span class="hljs-attr">script:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">></span> <span class="hljs-string">~/.netrc</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">> ~/.netrc
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">cd</span> <span class="hljs-string">website</span> <span class="hljs-string">&&</span> <span class="hljs-string">yarn</span> <span class="hljs-string">install</span> <span class="hljs-string">&&</span> <span class="hljs-string">GIT_USER="${GH_NAME}"</span> <span class="hljs-string">yarn</span> <span class="hljs-string">run</span> <span class="hljs-string">publish-gh-pages</span>
|
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
|
||||||
</code></pre>
|
</span></code></pre>
|
||||||
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
||||||
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
||||||
|
|
|
@ -141,7 +141,7 @@
|
||||||
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
||||||
...
|
...
|
||||||
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
||||||
<span class="hljs-attr">baseUrl</span>: <span class="hljs-string">'/testProject/'</span>,
|
baseUrl: <span class="hljs-string">'/testProject/'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
||||||
...
|
...
|
||||||
|
@ -211,23 +211,23 @@
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
git config --global user.name "<YOUR_NAME>"
|
git config --global user.name "<YOUR_NAME>"
|
||||||
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
||||||
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
||||||
|
@ -264,7 +264,7 @@ e.g.</li>
|
||||||
<span class="hljs-attr"> branches:</span>
|
<span class="hljs-attr"> branches:</span>
|
||||||
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
<span class="hljs-attr"> - run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
||||||
|
@ -285,11 +285,11 @@ e.g.</li>
|
||||||
<span class="hljs-attr">cache:</span>
|
<span class="hljs-attr">cache:</span>
|
||||||
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
||||||
<span class="hljs-attr">script:</span>
|
<span class="hljs-attr">script:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">></span> <span class="hljs-string">~/.netrc</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">> ~/.netrc
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">cd</span> <span class="hljs-string">website</span> <span class="hljs-string">&&</span> <span class="hljs-string">yarn</span> <span class="hljs-string">install</span> <span class="hljs-string">&&</span> <span class="hljs-string">GIT_USER="${GH_NAME}"</span> <span class="hljs-string">yarn</span> <span class="hljs-string">run</span> <span class="hljs-string">publish-gh-pages</span>
|
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
|
||||||
</code></pre>
|
</span></code></pre>
|
||||||
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
||||||
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
||||||
|
|
|
@ -206,17 +206,17 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<p><a href="/docs/en/1.11.x/doc-markdown">Syntax highlighting</a> options:</p>
|
<p><a href="/docs/en/1.11.x/doc-markdown">Syntax highlighting</a> options:</p>
|
||||||
<pre><code class="hljs css language-js">{
|
<pre><code class="hljs css language-js">{
|
||||||
<span class="hljs-comment">// ...</span>
|
<span class="hljs-comment">// ...</span>
|
||||||
<span class="hljs-attr">highlight</span>: {
|
highlight: {
|
||||||
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
||||||
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
||||||
<span class="hljs-attr">theme</span>: <span class="hljs-string">'default'</span>,
|
theme: <span class="hljs-string">'default'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
||||||
<span class="hljs-attr">version</span>: <span class="hljs-string">'9.12.0'</span>,
|
version: <span class="hljs-string">'9.12.0'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
||||||
<span class="hljs-attr">hljs</span>: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
hljs: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
||||||
<span class="hljs-comment">// do something here</span>
|
<span class="hljs-comment">// do something here</span>
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -224,10 +224,10 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
||||||
|
|
||||||
<span class="hljs-attr">defaultLang</span>: <span class="hljs-string">'javascript'</span>,
|
defaultLang: <span class="hljs-string">'javascript'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
||||||
<span class="hljs-attr">themeUrl</span>: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
themeUrl: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
@ -301,12 +301,12 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
||||||
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
||||||
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
||||||
<span class="hljs-attr">defaultVersionShown</span>: <span class="hljs-string">'1.0.0'</span>,
|
defaultVersionShown: <span class="hljs-string">'1.0.0'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
||||||
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
||||||
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
||||||
<span class="hljs-attr">headerLinks</span>: [
|
headerLinks: [
|
||||||
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
||||||
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
||||||
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
||||||
|
|
|
@ -206,17 +206,17 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<p><a href="/docs/en/1.11.x/doc-markdown">Syntax highlighting</a> options:</p>
|
<p><a href="/docs/en/1.11.x/doc-markdown">Syntax highlighting</a> options:</p>
|
||||||
<pre><code class="hljs css language-js">{
|
<pre><code class="hljs css language-js">{
|
||||||
<span class="hljs-comment">// ...</span>
|
<span class="hljs-comment">// ...</span>
|
||||||
<span class="hljs-attr">highlight</span>: {
|
highlight: {
|
||||||
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
||||||
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
||||||
<span class="hljs-attr">theme</span>: <span class="hljs-string">'default'</span>,
|
theme: <span class="hljs-string">'default'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
||||||
<span class="hljs-attr">version</span>: <span class="hljs-string">'9.12.0'</span>,
|
version: <span class="hljs-string">'9.12.0'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
||||||
<span class="hljs-attr">hljs</span>: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
hljs: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
||||||
<span class="hljs-comment">// do something here</span>
|
<span class="hljs-comment">// do something here</span>
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -224,10 +224,10 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
||||||
|
|
||||||
<span class="hljs-attr">defaultLang</span>: <span class="hljs-string">'javascript'</span>,
|
defaultLang: <span class="hljs-string">'javascript'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
||||||
<span class="hljs-attr">themeUrl</span>: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
themeUrl: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
@ -301,12 +301,12 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
||||||
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
||||||
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
||||||
<span class="hljs-attr">defaultVersionShown</span>: <span class="hljs-string">'1.0.0'</span>,
|
defaultVersionShown: <span class="hljs-string">'1.0.0'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
||||||
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
||||||
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
||||||
<span class="hljs-attr">headerLinks</span>: [
|
headerLinks: [
|
||||||
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
||||||
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
||||||
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
||||||
|
|
|
@ -266,11 +266,11 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
|
@ -287,12 +287,12 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
- crowdin --config crowdin.yaml download -b master
|
- crowdin --config crowdin.yaml download -b master
|
||||||
# build and publish website
|
# build and publish website
|
||||||
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
||||||
|
|
|
@ -266,11 +266,11 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
|
@ -287,12 +287,12 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
- crowdin --config crowdin.yaml download -b master
|
- crowdin --config crowdin.yaml download -b master
|
||||||
# build and publish website
|
# build and publish website
|
||||||
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
||||||
|
|
|
@ -85,13 +85,13 @@
|
||||||
<h2><a class="anchor" aria-hidden="true" id="put-the-site-online"></a><a href="#put-the-site-online" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Put the Site Online</h2>
|
<h2><a class="anchor" aria-hidden="true" id="put-the-site-online"></a><a href="#put-the-site-online" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Put the Site Online</h2>
|
||||||
<p>Kill the web server first by pressing Cmd + C or Ctrl + C depending on your operating system.</p>
|
<p>Kill the web server first by pressing Cmd + C or Ctrl + C depending on your operating system.</p>
|
||||||
<p>In <code>website/siteConfig.js</code>, fill in the following fields:</p>
|
<p>In <code>website/siteConfig.js</code>, fill in the following fields:</p>
|
||||||
<pre><code class="hljs"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs">const siteConfig = {
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
||||||
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
||||||
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
||||||
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<ol start="2">
|
<ol start="2">
|
||||||
|
|
|
@ -85,13 +85,13 @@
|
||||||
<h2><a class="anchor" aria-hidden="true" id="put-the-site-online"></a><a href="#put-the-site-online" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Put the Site Online</h2>
|
<h2><a class="anchor" aria-hidden="true" id="put-the-site-online"></a><a href="#put-the-site-online" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Put the Site Online</h2>
|
||||||
<p>Kill the web server first by pressing Cmd + C or Ctrl + C depending on your operating system.</p>
|
<p>Kill the web server first by pressing Cmd + C or Ctrl + C depending on your operating system.</p>
|
||||||
<p>In <code>website/siteConfig.js</code>, fill in the following fields:</p>
|
<p>In <code>website/siteConfig.js</code>, fill in the following fields:</p>
|
||||||
<pre><code class="hljs"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs">const siteConfig = {
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
||||||
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
||||||
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
||||||
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<ol start="2">
|
<ol start="2">
|
||||||
|
|
|
@ -95,7 +95,7 @@
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Joel</span> <span class="hljs-string">Marcey</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Joel</span> <span class="hljs-string">Marcey</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/JoelMarcey</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/JoelMarcey</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">611217057</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">611217057</span>
|
||||||
<span class="hljs-attr">authorTwitter:</span> <span class="hljs-string">JoelMarcey</span>
|
<span class="hljs-attr">authorTwitter:</span> <span class="hljs-string">JoelMarcey</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -95,7 +95,7 @@
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Joel</span> <span class="hljs-string">Marcey</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Joel</span> <span class="hljs-string">Marcey</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/JoelMarcey</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/JoelMarcey</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">611217057</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">611217057</span>
|
||||||
<span class="hljs-attr">authorTwitter:</span> <span class="hljs-string">JoelMarcey</span>
|
<span class="hljs-attr">authorTwitter:</span> <span class="hljs-string">JoelMarcey</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -109,7 +109,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
||||||
|
@ -122,7 +122,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -109,7 +109,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
||||||
|
@ -122,7 +122,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -142,7 +142,7 @@
|
||||||
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
||||||
...
|
...
|
||||||
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
||||||
<span class="hljs-attr">baseUrl</span>: <span class="hljs-string">'/testProject/'</span>,
|
baseUrl: <span class="hljs-string">'/testProject/'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
||||||
...
|
...
|
||||||
|
@ -212,23 +212,23 @@
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
git config --global user.name "<YOUR_NAME>"
|
git config --global user.name "<YOUR_NAME>"
|
||||||
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
||||||
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
||||||
|
@ -265,7 +265,7 @@ e.g.</li>
|
||||||
<span class="hljs-attr"> branches:</span>
|
<span class="hljs-attr"> branches:</span>
|
||||||
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
<span class="hljs-attr"> - run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
||||||
|
@ -286,11 +286,11 @@ e.g.</li>
|
||||||
<span class="hljs-attr">cache:</span>
|
<span class="hljs-attr">cache:</span>
|
||||||
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
||||||
<span class="hljs-attr">script:</span>
|
<span class="hljs-attr">script:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">></span> <span class="hljs-string">~/.netrc</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">> ~/.netrc
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">cd</span> <span class="hljs-string">website</span> <span class="hljs-string">&&</span> <span class="hljs-string">yarn</span> <span class="hljs-string">install</span> <span class="hljs-string">&&</span> <span class="hljs-string">GIT_USER="${GH_NAME}"</span> <span class="hljs-string">yarn</span> <span class="hljs-string">run</span> <span class="hljs-string">publish-gh-pages</span>
|
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
|
||||||
</code></pre>
|
</span></code></pre>
|
||||||
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
||||||
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
||||||
|
|
|
@ -142,7 +142,7 @@
|
||||||
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
||||||
...
|
...
|
||||||
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
||||||
<span class="hljs-attr">baseUrl</span>: <span class="hljs-string">'/testProject/'</span>,
|
baseUrl: <span class="hljs-string">'/testProject/'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
||||||
...
|
...
|
||||||
|
@ -212,23 +212,23 @@
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
git config --global user.name "<YOUR_NAME>"
|
git config --global user.name "<YOUR_NAME>"
|
||||||
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
||||||
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
||||||
|
@ -265,7 +265,7 @@ e.g.</li>
|
||||||
<span class="hljs-attr"> branches:</span>
|
<span class="hljs-attr"> branches:</span>
|
||||||
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
<span class="hljs-attr"> - run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
||||||
|
@ -286,11 +286,11 @@ e.g.</li>
|
||||||
<span class="hljs-attr">cache:</span>
|
<span class="hljs-attr">cache:</span>
|
||||||
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
||||||
<span class="hljs-attr">script:</span>
|
<span class="hljs-attr">script:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">></span> <span class="hljs-string">~/.netrc</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">> ~/.netrc
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">cd</span> <span class="hljs-string">website</span> <span class="hljs-string">&&</span> <span class="hljs-string">yarn</span> <span class="hljs-string">install</span> <span class="hljs-string">&&</span> <span class="hljs-string">GIT_USER="${GH_NAME}"</span> <span class="hljs-string">yarn</span> <span class="hljs-string">run</span> <span class="hljs-string">publish-gh-pages</span>
|
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
|
||||||
</code></pre>
|
</span></code></pre>
|
||||||
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
||||||
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
||||||
|
|
|
@ -206,17 +206,17 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<p><a href="/docs/en/1.12.0/doc-markdown">Syntax highlighting</a> options:</p>
|
<p><a href="/docs/en/1.12.0/doc-markdown">Syntax highlighting</a> options:</p>
|
||||||
<pre><code class="hljs css language-js">{
|
<pre><code class="hljs css language-js">{
|
||||||
<span class="hljs-comment">// ...</span>
|
<span class="hljs-comment">// ...</span>
|
||||||
<span class="hljs-attr">highlight</span>: {
|
highlight: {
|
||||||
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
||||||
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
||||||
<span class="hljs-attr">theme</span>: <span class="hljs-string">'default'</span>,
|
theme: <span class="hljs-string">'default'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
||||||
<span class="hljs-attr">version</span>: <span class="hljs-string">'9.12.0'</span>,
|
version: <span class="hljs-string">'9.12.0'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
||||||
<span class="hljs-attr">hljs</span>: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
hljs: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
||||||
<span class="hljs-comment">// do something here</span>
|
<span class="hljs-comment">// do something here</span>
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -224,10 +224,10 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
||||||
|
|
||||||
<span class="hljs-attr">defaultLang</span>: <span class="hljs-string">'javascript'</span>,
|
defaultLang: <span class="hljs-string">'javascript'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
||||||
<span class="hljs-attr">themeUrl</span>: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
themeUrl: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
@ -301,12 +301,12 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
||||||
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
||||||
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
||||||
<span class="hljs-attr">defaultVersionShown</span>: <span class="hljs-string">'1.0.0'</span>,
|
defaultVersionShown: <span class="hljs-string">'1.0.0'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
||||||
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
||||||
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
||||||
<span class="hljs-attr">headerLinks</span>: [
|
headerLinks: [
|
||||||
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
||||||
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
||||||
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
||||||
|
|
|
@ -206,17 +206,17 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<p><a href="/docs/en/1.12.0/doc-markdown">Syntax highlighting</a> options:</p>
|
<p><a href="/docs/en/1.12.0/doc-markdown">Syntax highlighting</a> options:</p>
|
||||||
<pre><code class="hljs css language-js">{
|
<pre><code class="hljs css language-js">{
|
||||||
<span class="hljs-comment">// ...</span>
|
<span class="hljs-comment">// ...</span>
|
||||||
<span class="hljs-attr">highlight</span>: {
|
highlight: {
|
||||||
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
||||||
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
||||||
<span class="hljs-attr">theme</span>: <span class="hljs-string">'default'</span>,
|
theme: <span class="hljs-string">'default'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
||||||
<span class="hljs-attr">version</span>: <span class="hljs-string">'9.12.0'</span>,
|
version: <span class="hljs-string">'9.12.0'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
||||||
<span class="hljs-attr">hljs</span>: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
hljs: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
||||||
<span class="hljs-comment">// do something here</span>
|
<span class="hljs-comment">// do something here</span>
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -224,10 +224,10 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
||||||
|
|
||||||
<span class="hljs-attr">defaultLang</span>: <span class="hljs-string">'javascript'</span>,
|
defaultLang: <span class="hljs-string">'javascript'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
||||||
<span class="hljs-attr">themeUrl</span>: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
themeUrl: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
@ -301,12 +301,12 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
||||||
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
||||||
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
||||||
<span class="hljs-attr">defaultVersionShown</span>: <span class="hljs-string">'1.0.0'</span>,
|
defaultVersionShown: <span class="hljs-string">'1.0.0'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
||||||
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
||||||
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
||||||
<span class="hljs-attr">headerLinks</span>: [
|
headerLinks: [
|
||||||
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
||||||
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
||||||
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
||||||
|
|
|
@ -266,11 +266,11 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
|
@ -287,12 +287,12 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
- crowdin --config crowdin.yaml download -b master
|
- crowdin --config crowdin.yaml download -b master
|
||||||
# build and publish website
|
# build and publish website
|
||||||
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
||||||
|
|
|
@ -266,11 +266,11 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
|
@ -287,12 +287,12 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
- crowdin --config crowdin.yaml download -b master
|
- crowdin --config crowdin.yaml download -b master
|
||||||
# build and publish website
|
# build and publish website
|
||||||
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
||||||
|
|
|
@ -85,13 +85,13 @@
|
||||||
<h2><a class="anchor" aria-hidden="true" id="put-the-site-online"></a><a href="#put-the-site-online" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Put the Site Online</h2>
|
<h2><a class="anchor" aria-hidden="true" id="put-the-site-online"></a><a href="#put-the-site-online" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Put the Site Online</h2>
|
||||||
<p>Kill the web server first by pressing Cmd + C or Ctrl + C depending on your operating system.</p>
|
<p>Kill the web server first by pressing Cmd + C or Ctrl + C depending on your operating system.</p>
|
||||||
<p>In <code>website/siteConfig.js</code>, fill in the following fields:</p>
|
<p>In <code>website/siteConfig.js</code>, fill in the following fields:</p>
|
||||||
<pre><code class="hljs"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs">const siteConfig = {
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
||||||
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
||||||
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
||||||
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<ol start="2">
|
<ol start="2">
|
||||||
|
|
|
@ -85,13 +85,13 @@
|
||||||
<h2><a class="anchor" aria-hidden="true" id="put-the-site-online"></a><a href="#put-the-site-online" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Put the Site Online</h2>
|
<h2><a class="anchor" aria-hidden="true" id="put-the-site-online"></a><a href="#put-the-site-online" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Put the Site Online</h2>
|
||||||
<p>Kill the web server first by pressing Cmd + C or Ctrl + C depending on your operating system.</p>
|
<p>Kill the web server first by pressing Cmd + C or Ctrl + C depending on your operating system.</p>
|
||||||
<p>In <code>website/siteConfig.js</code>, fill in the following fields:</p>
|
<p>In <code>website/siteConfig.js</code>, fill in the following fields:</p>
|
||||||
<pre><code class="hljs"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs">const siteConfig = {
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
||||||
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
||||||
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
||||||
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<ol start="2">
|
<ol start="2">
|
||||||
|
|
|
@ -95,7 +95,7 @@
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Joel</span> <span class="hljs-string">Marcey</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Joel</span> <span class="hljs-string">Marcey</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/JoelMarcey</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/JoelMarcey</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">611217057</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">611217057</span>
|
||||||
<span class="hljs-attr">authorTwitter:</span> <span class="hljs-string">JoelMarcey</span>
|
<span class="hljs-attr">authorTwitter:</span> <span class="hljs-string">JoelMarcey</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -95,7 +95,7 @@
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Joel</span> <span class="hljs-string">Marcey</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Joel</span> <span class="hljs-string">Marcey</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/JoelMarcey</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/JoelMarcey</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">611217057</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">611217057</span>
|
||||||
<span class="hljs-attr">authorTwitter:</span> <span class="hljs-string">JoelMarcey</span>
|
<span class="hljs-attr">authorTwitter:</span> <span class="hljs-string">JoelMarcey</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -109,7 +109,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
||||||
|
@ -122,7 +122,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -109,7 +109,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
||||||
|
@ -122,7 +122,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -142,7 +142,7 @@
|
||||||
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
||||||
...
|
...
|
||||||
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
||||||
<span class="hljs-attr">baseUrl</span>: <span class="hljs-string">'/testProject/'</span>,
|
baseUrl: <span class="hljs-string">'/testProject/'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
||||||
...
|
...
|
||||||
|
@ -212,23 +212,23 @@
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
git config --global user.name "<YOUR_NAME>"
|
git config --global user.name "<YOUR_NAME>"
|
||||||
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
||||||
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
||||||
|
@ -265,7 +265,7 @@ e.g.</li>
|
||||||
<span class="hljs-attr"> branches:</span>
|
<span class="hljs-attr"> branches:</span>
|
||||||
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
<span class="hljs-attr"> - run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
||||||
|
@ -286,11 +286,11 @@ e.g.</li>
|
||||||
<span class="hljs-attr">cache:</span>
|
<span class="hljs-attr">cache:</span>
|
||||||
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
||||||
<span class="hljs-attr">script:</span>
|
<span class="hljs-attr">script:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">></span> <span class="hljs-string">~/.netrc</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">> ~/.netrc
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">cd</span> <span class="hljs-string">website</span> <span class="hljs-string">&&</span> <span class="hljs-string">yarn</span> <span class="hljs-string">install</span> <span class="hljs-string">&&</span> <span class="hljs-string">GIT_USER="${GH_NAME}"</span> <span class="hljs-string">yarn</span> <span class="hljs-string">run</span> <span class="hljs-string">publish-gh-pages</span>
|
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
|
||||||
</code></pre>
|
</span></code></pre>
|
||||||
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
||||||
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
||||||
|
|
|
@ -142,7 +142,7 @@
|
||||||
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
||||||
...
|
...
|
||||||
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
||||||
<span class="hljs-attr">baseUrl</span>: <span class="hljs-string">'/testProject/'</span>,
|
baseUrl: <span class="hljs-string">'/testProject/'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
||||||
...
|
...
|
||||||
|
@ -212,23 +212,23 @@
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
git config --global user.name "<YOUR_NAME>"
|
git config --global user.name "<YOUR_NAME>"
|
||||||
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
||||||
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
||||||
|
@ -265,7 +265,7 @@ e.g.</li>
|
||||||
<span class="hljs-attr"> branches:</span>
|
<span class="hljs-attr"> branches:</span>
|
||||||
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
<span class="hljs-attr"> - run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
||||||
|
@ -286,11 +286,11 @@ e.g.</li>
|
||||||
<span class="hljs-attr">cache:</span>
|
<span class="hljs-attr">cache:</span>
|
||||||
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
||||||
<span class="hljs-attr">script:</span>
|
<span class="hljs-attr">script:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">></span> <span class="hljs-string">~/.netrc</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">> ~/.netrc
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">cd</span> <span class="hljs-string">website</span> <span class="hljs-string">&&</span> <span class="hljs-string">yarn</span> <span class="hljs-string">install</span> <span class="hljs-string">&&</span> <span class="hljs-string">GIT_USER="${GH_NAME}"</span> <span class="hljs-string">yarn</span> <span class="hljs-string">run</span> <span class="hljs-string">publish-gh-pages</span>
|
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
|
||||||
</code></pre>
|
</span></code></pre>
|
||||||
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
||||||
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
||||||
|
|
|
@ -206,17 +206,17 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<p><a href="/docs/en/1.13.0/doc-markdown">Syntax highlighting</a> options:</p>
|
<p><a href="/docs/en/1.13.0/doc-markdown">Syntax highlighting</a> options:</p>
|
||||||
<pre><code class="hljs css language-js">{
|
<pre><code class="hljs css language-js">{
|
||||||
<span class="hljs-comment">// ...</span>
|
<span class="hljs-comment">// ...</span>
|
||||||
<span class="hljs-attr">highlight</span>: {
|
highlight: {
|
||||||
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
||||||
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
||||||
<span class="hljs-attr">theme</span>: <span class="hljs-string">'default'</span>,
|
theme: <span class="hljs-string">'default'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
||||||
<span class="hljs-attr">version</span>: <span class="hljs-string">'9.12.0'</span>,
|
version: <span class="hljs-string">'9.12.0'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
||||||
<span class="hljs-attr">hljs</span>: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
hljs: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
||||||
<span class="hljs-comment">// do something here</span>
|
<span class="hljs-comment">// do something here</span>
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -224,10 +224,10 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
||||||
|
|
||||||
<span class="hljs-attr">defaultLang</span>: <span class="hljs-string">'javascript'</span>,
|
defaultLang: <span class="hljs-string">'javascript'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
||||||
<span class="hljs-attr">themeUrl</span>: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
themeUrl: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
@ -301,12 +301,12 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
||||||
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
||||||
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
||||||
<span class="hljs-attr">defaultVersionShown</span>: <span class="hljs-string">'1.0.0'</span>,
|
defaultVersionShown: <span class="hljs-string">'1.0.0'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
||||||
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
||||||
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
||||||
<span class="hljs-attr">headerLinks</span>: [
|
headerLinks: [
|
||||||
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
||||||
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
||||||
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
||||||
|
|
|
@ -206,17 +206,17 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<p><a href="/docs/en/1.13.0/doc-markdown">Syntax highlighting</a> options:</p>
|
<p><a href="/docs/en/1.13.0/doc-markdown">Syntax highlighting</a> options:</p>
|
||||||
<pre><code class="hljs css language-js">{
|
<pre><code class="hljs css language-js">{
|
||||||
<span class="hljs-comment">// ...</span>
|
<span class="hljs-comment">// ...</span>
|
||||||
<span class="hljs-attr">highlight</span>: {
|
highlight: {
|
||||||
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
||||||
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
||||||
<span class="hljs-attr">theme</span>: <span class="hljs-string">'default'</span>,
|
theme: <span class="hljs-string">'default'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
||||||
<span class="hljs-attr">version</span>: <span class="hljs-string">'9.12.0'</span>,
|
version: <span class="hljs-string">'9.12.0'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
||||||
<span class="hljs-attr">hljs</span>: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
hljs: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
||||||
<span class="hljs-comment">// do something here</span>
|
<span class="hljs-comment">// do something here</span>
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -224,10 +224,10 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
||||||
|
|
||||||
<span class="hljs-attr">defaultLang</span>: <span class="hljs-string">'javascript'</span>,
|
defaultLang: <span class="hljs-string">'javascript'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
||||||
<span class="hljs-attr">themeUrl</span>: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
themeUrl: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
@ -301,12 +301,12 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
||||||
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
||||||
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
||||||
<span class="hljs-attr">defaultVersionShown</span>: <span class="hljs-string">'1.0.0'</span>,
|
defaultVersionShown: <span class="hljs-string">'1.0.0'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
||||||
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
||||||
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
||||||
<span class="hljs-attr">headerLinks</span>: [
|
headerLinks: [
|
||||||
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
||||||
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
||||||
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
||||||
|
|
|
@ -266,11 +266,11 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
|
@ -287,12 +287,12 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
- crowdin --config crowdin.yaml download -b master
|
- crowdin --config crowdin.yaml download -b master
|
||||||
# build and publish website
|
# build and publish website
|
||||||
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
||||||
|
|
|
@ -266,11 +266,11 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
|
@ -287,12 +287,12 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
- crowdin --config crowdin.yaml download -b master
|
- crowdin --config crowdin.yaml download -b master
|
||||||
# build and publish website
|
# build and publish website
|
||||||
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
||||||
|
|
|
@ -86,13 +86,13 @@
|
||||||
<ol>
|
<ol>
|
||||||
<li>Edit the file <code>docusaurus-tutorial/website/siteConfig.js</code> and fill in the following values:</li>
|
<li>Edit the file <code>docusaurus-tutorial/website/siteConfig.js</code> and fill in the following values:</li>
|
||||||
</ol>
|
</ol>
|
||||||
<pre><code class="hljs"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs">const siteConfig = {
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
||||||
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
||||||
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
||||||
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<ol start="2">
|
<ol start="2">
|
||||||
|
|
|
@ -86,13 +86,13 @@
|
||||||
<ol>
|
<ol>
|
||||||
<li>Edit the file <code>docusaurus-tutorial/website/siteConfig.js</code> and fill in the following values:</li>
|
<li>Edit the file <code>docusaurus-tutorial/website/siteConfig.js</code> and fill in the following values:</li>
|
||||||
</ol>
|
</ol>
|
||||||
<pre><code class="hljs"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs">const siteConfig = {
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
||||||
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
||||||
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
||||||
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<ol start="2">
|
<ol start="2">
|
||||||
|
|
|
@ -94,7 +94,7 @@
|
||||||
<p>For example, at <code>website/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
<p>For example, at <code>website/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">https://twitter.com/foobarbaz</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">https://twitter.com/foobarbaz</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -94,7 +94,7 @@
|
||||||
<p>For example, at <code>website/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
<p>For example, at <code>website/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">https://twitter.com/foobarbaz</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">https://twitter.com/foobarbaz</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -109,7 +109,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
||||||
|
@ -122,7 +122,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -109,7 +109,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
||||||
|
@ -122,7 +122,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -141,7 +141,7 @@
|
||||||
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
||||||
...
|
...
|
||||||
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
||||||
<span class="hljs-attr">baseUrl</span>: <span class="hljs-string">'/testProject/'</span>,
|
baseUrl: <span class="hljs-string">'/testProject/'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
||||||
...
|
...
|
||||||
|
@ -211,23 +211,23 @@
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
git config --global user.name "<YOUR_NAME>"
|
git config --global user.name "<YOUR_NAME>"
|
||||||
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
||||||
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
||||||
|
@ -264,7 +264,7 @@ e.g.</li>
|
||||||
<span class="hljs-attr"> branches:</span>
|
<span class="hljs-attr"> branches:</span>
|
||||||
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
<span class="hljs-attr"> - run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
||||||
|
@ -285,11 +285,11 @@ e.g.</li>
|
||||||
<span class="hljs-attr">cache:</span>
|
<span class="hljs-attr">cache:</span>
|
||||||
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
||||||
<span class="hljs-attr">script:</span>
|
<span class="hljs-attr">script:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">></span> <span class="hljs-string">~/.netrc</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">> ~/.netrc
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">cd</span> <span class="hljs-string">website</span> <span class="hljs-string">&&</span> <span class="hljs-string">yarn</span> <span class="hljs-string">install</span> <span class="hljs-string">&&</span> <span class="hljs-string">GIT_USER="${GH_NAME}"</span> <span class="hljs-string">yarn</span> <span class="hljs-string">run</span> <span class="hljs-string">publish-gh-pages</span>
|
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
|
||||||
</code></pre>
|
</span></code></pre>
|
||||||
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
||||||
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
||||||
|
|
|
@ -141,7 +141,7 @@
|
||||||
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
||||||
...
|
...
|
||||||
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
||||||
<span class="hljs-attr">baseUrl</span>: <span class="hljs-string">'/testProject/'</span>,
|
baseUrl: <span class="hljs-string">'/testProject/'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
||||||
...
|
...
|
||||||
|
@ -211,23 +211,23 @@
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
git config --global user.name "<YOUR_NAME>"
|
git config --global user.name "<YOUR_NAME>"
|
||||||
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
||||||
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
||||||
|
@ -264,7 +264,7 @@ e.g.</li>
|
||||||
<span class="hljs-attr"> branches:</span>
|
<span class="hljs-attr"> branches:</span>
|
||||||
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
<span class="hljs-attr"> - run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
||||||
|
@ -285,11 +285,11 @@ e.g.</li>
|
||||||
<span class="hljs-attr">cache:</span>
|
<span class="hljs-attr">cache:</span>
|
||||||
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
||||||
<span class="hljs-attr">script:</span>
|
<span class="hljs-attr">script:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">></span> <span class="hljs-string">~/.netrc</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">> ~/.netrc
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">cd</span> <span class="hljs-string">website</span> <span class="hljs-string">&&</span> <span class="hljs-string">yarn</span> <span class="hljs-string">install</span> <span class="hljs-string">&&</span> <span class="hljs-string">GIT_USER="${GH_NAME}"</span> <span class="hljs-string">yarn</span> <span class="hljs-string">run</span> <span class="hljs-string">publish-gh-pages</span>
|
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
|
||||||
</code></pre>
|
</span></code></pre>
|
||||||
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
||||||
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
||||||
|
|
|
@ -206,17 +206,17 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<p><a href="/docs/en/1.9.x/doc-markdown">Syntax highlighting</a> options:</p>
|
<p><a href="/docs/en/1.9.x/doc-markdown">Syntax highlighting</a> options:</p>
|
||||||
<pre><code class="hljs css language-js">{
|
<pre><code class="hljs css language-js">{
|
||||||
<span class="hljs-comment">// ...</span>
|
<span class="hljs-comment">// ...</span>
|
||||||
<span class="hljs-attr">highlight</span>: {
|
highlight: {
|
||||||
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
||||||
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
||||||
<span class="hljs-attr">theme</span>: <span class="hljs-string">'default'</span>,
|
theme: <span class="hljs-string">'default'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
||||||
<span class="hljs-attr">version</span>: <span class="hljs-string">'9.12.0'</span>,
|
version: <span class="hljs-string">'9.12.0'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
||||||
<span class="hljs-attr">hljs</span>: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
hljs: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
||||||
<span class="hljs-comment">// do something here</span>
|
<span class="hljs-comment">// do something here</span>
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -224,10 +224,10 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
||||||
|
|
||||||
<span class="hljs-attr">defaultLang</span>: <span class="hljs-string">'javascript'</span>,
|
defaultLang: <span class="hljs-string">'javascript'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
||||||
<span class="hljs-attr">themeUrl</span>: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
themeUrl: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
@ -289,12 +289,12 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
||||||
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
||||||
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
||||||
<span class="hljs-attr">defaultVersionShown</span>: <span class="hljs-string">'1.0.0'</span>,
|
defaultVersionShown: <span class="hljs-string">'1.0.0'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
||||||
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
||||||
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
||||||
<span class="hljs-attr">headerLinks</span>: [
|
headerLinks: [
|
||||||
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
||||||
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
||||||
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
||||||
|
|
|
@ -206,17 +206,17 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<p><a href="/docs/en/1.9.x/doc-markdown">Syntax highlighting</a> options:</p>
|
<p><a href="/docs/en/1.9.x/doc-markdown">Syntax highlighting</a> options:</p>
|
||||||
<pre><code class="hljs css language-js">{
|
<pre><code class="hljs css language-js">{
|
||||||
<span class="hljs-comment">// ...</span>
|
<span class="hljs-comment">// ...</span>
|
||||||
<span class="hljs-attr">highlight</span>: {
|
highlight: {
|
||||||
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
||||||
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
||||||
<span class="hljs-attr">theme</span>: <span class="hljs-string">'default'</span>,
|
theme: <span class="hljs-string">'default'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
||||||
<span class="hljs-attr">version</span>: <span class="hljs-string">'9.12.0'</span>,
|
version: <span class="hljs-string">'9.12.0'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
||||||
<span class="hljs-attr">hljs</span>: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
hljs: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
||||||
<span class="hljs-comment">// do something here</span>
|
<span class="hljs-comment">// do something here</span>
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -224,10 +224,10 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
||||||
|
|
||||||
<span class="hljs-attr">defaultLang</span>: <span class="hljs-string">'javascript'</span>,
|
defaultLang: <span class="hljs-string">'javascript'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
||||||
<span class="hljs-attr">themeUrl</span>: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
themeUrl: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
@ -289,12 +289,12 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
||||||
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
||||||
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
||||||
<span class="hljs-attr">defaultVersionShown</span>: <span class="hljs-string">'1.0.0'</span>,
|
defaultVersionShown: <span class="hljs-string">'1.0.0'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
||||||
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
||||||
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
||||||
<span class="hljs-attr">headerLinks</span>: [
|
headerLinks: [
|
||||||
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
||||||
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
||||||
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
||||||
|
|
|
@ -266,11 +266,11 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
|
@ -287,12 +287,12 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
- crowdin --config crowdin.yaml download -b master
|
- crowdin --config crowdin.yaml download -b master
|
||||||
# build and publish website
|
# build and publish website
|
||||||
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
||||||
|
|
|
@ -266,11 +266,11 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
|
@ -287,12 +287,12 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
- crowdin --config crowdin.yaml download -b master
|
- crowdin --config crowdin.yaml download -b master
|
||||||
# build and publish website
|
# build and publish website
|
||||||
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
||||||
|
|
|
@ -85,13 +85,13 @@
|
||||||
<h2><a class="anchor" aria-hidden="true" id="put-the-site-online"></a><a href="#put-the-site-online" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Put the Site Online</h2>
|
<h2><a class="anchor" aria-hidden="true" id="put-the-site-online"></a><a href="#put-the-site-online" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Put the Site Online</h2>
|
||||||
<p>Kill the web server first by pressing Cmd + C or Ctrl + C depending on your operating system.</p>
|
<p>Kill the web server first by pressing Cmd + C or Ctrl + C depending on your operating system.</p>
|
||||||
<p>In <code>website/siteConfig.js</code>, fill in the following fields:</p>
|
<p>In <code>website/siteConfig.js</code>, fill in the following fields:</p>
|
||||||
<pre><code class="hljs"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs">const siteConfig = {
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
||||||
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
||||||
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
||||||
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<ol start="2">
|
<ol start="2">
|
||||||
|
|
|
@ -85,13 +85,13 @@
|
||||||
<h2><a class="anchor" aria-hidden="true" id="put-the-site-online"></a><a href="#put-the-site-online" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Put the Site Online</h2>
|
<h2><a class="anchor" aria-hidden="true" id="put-the-site-online"></a><a href="#put-the-site-online" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Put the Site Online</h2>
|
||||||
<p>Kill the web server first by pressing Cmd + C or Ctrl + C depending on your operating system.</p>
|
<p>Kill the web server first by pressing Cmd + C or Ctrl + C depending on your operating system.</p>
|
||||||
<p>In <code>website/siteConfig.js</code>, fill in the following fields:</p>
|
<p>In <code>website/siteConfig.js</code>, fill in the following fields:</p>
|
||||||
<pre><code class="hljs"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs">const siteConfig = {
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
||||||
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
||||||
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
||||||
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<ol start="2">
|
<ol start="2">
|
||||||
|
|
|
@ -95,7 +95,7 @@
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Joel</span> <span class="hljs-string">Marcey</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Joel</span> <span class="hljs-string">Marcey</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/JoelMarcey</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/JoelMarcey</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">611217057</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">611217057</span>
|
||||||
<span class="hljs-attr">authorTwitter:</span> <span class="hljs-string">JoelMarcey</span>
|
<span class="hljs-attr">authorTwitter:</span> <span class="hljs-string">JoelMarcey</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -95,7 +95,7 @@
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Joel</span> <span class="hljs-string">Marcey</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Joel</span> <span class="hljs-string">Marcey</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/JoelMarcey</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/JoelMarcey</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">611217057</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">611217057</span>
|
||||||
<span class="hljs-attr">authorTwitter:</span> <span class="hljs-string">JoelMarcey</span>
|
<span class="hljs-attr">authorTwitter:</span> <span class="hljs-string">JoelMarcey</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -112,7 +112,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
||||||
|
@ -125,7 +125,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -112,7 +112,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
||||||
|
@ -125,7 +125,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -95,7 +95,7 @@
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Joel</span> <span class="hljs-string">Marcey</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Joel</span> <span class="hljs-string">Marcey</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/JoelMarcey</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/JoelMarcey</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">611217057</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">611217057</span>
|
||||||
<span class="hljs-attr">authorTwitter:</span> <span class="hljs-string">JoelMarcey</span>
|
<span class="hljs-attr">authorTwitter:</span> <span class="hljs-string">JoelMarcey</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -95,7 +95,7 @@
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Joel</span> <span class="hljs-string">Marcey</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Joel</span> <span class="hljs-string">Marcey</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/JoelMarcey</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/JoelMarcey</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">611217057</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">611217057</span>
|
||||||
<span class="hljs-attr">authorTwitter:</span> <span class="hljs-string">JoelMarcey</span>
|
<span class="hljs-attr">authorTwitter:</span> <span class="hljs-string">JoelMarcey</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -112,7 +112,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
||||||
|
@ -125,7 +125,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -112,7 +112,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Markdown</span> <span class="hljs-string">Features</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
<h3><a class="anchor" aria-hidden="true" id="blog-posts"></a><a href="#blog-posts" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Blog Posts</h3>
|
||||||
|
@ -125,7 +125,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">My</span> <span class="hljs-string">First</span> <span class="hljs-string">Blog</span> <span class="hljs-string">Post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -142,7 +142,7 @@
|
||||||
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
||||||
...
|
...
|
||||||
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
||||||
<span class="hljs-attr">baseUrl</span>: <span class="hljs-string">'/testProject/'</span>,
|
baseUrl: <span class="hljs-string">'/testProject/'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
||||||
...
|
...
|
||||||
|
@ -216,23 +216,23 @@
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
git config --global user.name "<YOUR_NAME>"
|
git config --global user.name "<YOUR_NAME>"
|
||||||
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
||||||
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
||||||
|
@ -269,7 +269,7 @@ e.g.</li>
|
||||||
<span class="hljs-attr"> branches:</span>
|
<span class="hljs-attr"> branches:</span>
|
||||||
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
<span class="hljs-attr"> - run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
||||||
|
@ -290,11 +290,11 @@ e.g.</li>
|
||||||
<span class="hljs-attr">cache:</span>
|
<span class="hljs-attr">cache:</span>
|
||||||
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
||||||
<span class="hljs-attr">script:</span>
|
<span class="hljs-attr">script:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">></span> <span class="hljs-string">~/.netrc</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">> ~/.netrc
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">cd</span> <span class="hljs-string">website</span> <span class="hljs-string">&&</span> <span class="hljs-string">yarn</span> <span class="hljs-string">install</span> <span class="hljs-string">&&</span> <span class="hljs-string">GIT_USER="${GH_NAME}"</span> <span class="hljs-string">yarn</span> <span class="hljs-string">run</span> <span class="hljs-string">publish-gh-pages</span>
|
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
|
||||||
</code></pre>
|
</span></code></pre>
|
||||||
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
||||||
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
||||||
|
|
|
@ -142,7 +142,7 @@
|
||||||
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
||||||
...
|
...
|
||||||
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
||||||
<span class="hljs-attr">baseUrl</span>: <span class="hljs-string">'/testProject/'</span>,
|
baseUrl: <span class="hljs-string">'/testProject/'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
||||||
...
|
...
|
||||||
|
@ -216,23 +216,23 @@
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
git config --global user.name "<YOUR_NAME>"
|
git config --global user.name "<YOUR_NAME>"
|
||||||
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
||||||
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
||||||
|
@ -269,7 +269,7 @@ e.g.</li>
|
||||||
<span class="hljs-attr"> branches:</span>
|
<span class="hljs-attr"> branches:</span>
|
||||||
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
<span class="hljs-attr"> - run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
||||||
|
@ -290,11 +290,11 @@ e.g.</li>
|
||||||
<span class="hljs-attr">cache:</span>
|
<span class="hljs-attr">cache:</span>
|
||||||
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
||||||
<span class="hljs-attr">script:</span>
|
<span class="hljs-attr">script:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">></span> <span class="hljs-string">~/.netrc</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">> ~/.netrc
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">cd</span> <span class="hljs-string">website</span> <span class="hljs-string">&&</span> <span class="hljs-string">yarn</span> <span class="hljs-string">install</span> <span class="hljs-string">&&</span> <span class="hljs-string">GIT_USER="${GH_NAME}"</span> <span class="hljs-string">yarn</span> <span class="hljs-string">run</span> <span class="hljs-string">publish-gh-pages</span>
|
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
|
||||||
</code></pre>
|
</span></code></pre>
|
||||||
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
||||||
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
||||||
|
|
|
@ -209,17 +209,17 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<p><a href="/docs/en/next/doc-markdown">Syntax highlighting</a> options:</p>
|
<p><a href="/docs/en/next/doc-markdown">Syntax highlighting</a> options:</p>
|
||||||
<pre><code class="hljs css language-js">{
|
<pre><code class="hljs css language-js">{
|
||||||
<span class="hljs-comment">// ...</span>
|
<span class="hljs-comment">// ...</span>
|
||||||
<span class="hljs-attr">highlight</span>: {
|
highlight: {
|
||||||
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
||||||
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
||||||
<span class="hljs-attr">theme</span>: <span class="hljs-string">'default'</span>,
|
theme: <span class="hljs-string">'default'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
||||||
<span class="hljs-attr">version</span>: <span class="hljs-string">'9.12.0'</span>,
|
version: <span class="hljs-string">'9.12.0'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
||||||
<span class="hljs-attr">hljs</span>: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
hljs: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
||||||
<span class="hljs-comment">// do something here</span>
|
<span class="hljs-comment">// do something here</span>
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -227,10 +227,10 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
||||||
|
|
||||||
<span class="hljs-attr">defaultLang</span>: <span class="hljs-string">'javascript'</span>,
|
defaultLang: <span class="hljs-string">'javascript'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
||||||
<span class="hljs-attr">themeUrl</span>: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
themeUrl: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
@ -312,12 +312,12 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
||||||
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
||||||
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
||||||
<span class="hljs-attr">defaultVersionShown</span>: <span class="hljs-string">'1.0.0'</span>,
|
defaultVersionShown: <span class="hljs-string">'1.0.0'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
||||||
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
||||||
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
||||||
<span class="hljs-attr">headerLinks</span>: [
|
headerLinks: [
|
||||||
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
||||||
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
||||||
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
||||||
|
|
|
@ -209,17 +209,17 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<p><a href="/docs/en/next/doc-markdown">Syntax highlighting</a> options:</p>
|
<p><a href="/docs/en/next/doc-markdown">Syntax highlighting</a> options:</p>
|
||||||
<pre><code class="hljs css language-js">{
|
<pre><code class="hljs css language-js">{
|
||||||
<span class="hljs-comment">// ...</span>
|
<span class="hljs-comment">// ...</span>
|
||||||
<span class="hljs-attr">highlight</span>: {
|
highlight: {
|
||||||
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
||||||
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
||||||
<span class="hljs-attr">theme</span>: <span class="hljs-string">'default'</span>,
|
theme: <span class="hljs-string">'default'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
||||||
<span class="hljs-attr">version</span>: <span class="hljs-string">'9.12.0'</span>,
|
version: <span class="hljs-string">'9.12.0'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
||||||
<span class="hljs-attr">hljs</span>: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
hljs: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
||||||
<span class="hljs-comment">// do something here</span>
|
<span class="hljs-comment">// do something here</span>
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -227,10 +227,10 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
||||||
|
|
||||||
<span class="hljs-attr">defaultLang</span>: <span class="hljs-string">'javascript'</span>,
|
defaultLang: <span class="hljs-string">'javascript'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
||||||
<span class="hljs-attr">themeUrl</span>: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
themeUrl: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
@ -312,12 +312,12 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
||||||
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
||||||
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
||||||
<span class="hljs-attr">defaultVersionShown</span>: <span class="hljs-string">'1.0.0'</span>,
|
defaultVersionShown: <span class="hljs-string">'1.0.0'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
||||||
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
||||||
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
||||||
<span class="hljs-attr">headerLinks</span>: [
|
headerLinks: [
|
||||||
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
||||||
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
||||||
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
||||||
|
|
|
@ -266,11 +266,11 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
|
@ -287,12 +287,12 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
- crowdin --config crowdin.yaml download -b master
|
- crowdin --config crowdin.yaml download -b master
|
||||||
# build and publish website
|
# build and publish website
|
||||||
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
||||||
|
|
|
@ -266,11 +266,11 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
|
@ -287,12 +287,12 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
- crowdin --config crowdin.yaml download -b master
|
- crowdin --config crowdin.yaml download -b master
|
||||||
# build and publish website
|
# build and publish website
|
||||||
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
||||||
|
|
|
@ -86,13 +86,13 @@
|
||||||
<ol>
|
<ol>
|
||||||
<li>Edit the file <code>docusaurus-tutorial/website/siteConfig.js</code> and fill in the following values:</li>
|
<li>Edit the file <code>docusaurus-tutorial/website/siteConfig.js</code> and fill in the following values:</li>
|
||||||
</ol>
|
</ol>
|
||||||
<pre><code class="hljs"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs">const siteConfig = {
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
||||||
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
||||||
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
||||||
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<ol start="2">
|
<ol start="2">
|
||||||
|
|
|
@ -86,13 +86,13 @@
|
||||||
<ol>
|
<ol>
|
||||||
<li>Edit the file <code>docusaurus-tutorial/website/siteConfig.js</code> and fill in the following values:</li>
|
<li>Edit the file <code>docusaurus-tutorial/website/siteConfig.js</code> and fill in the following values:</li>
|
||||||
</ol>
|
</ol>
|
||||||
<pre><code class="hljs"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs">const siteConfig = {
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
||||||
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
||||||
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
||||||
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<ol start="2">
|
<ol start="2">
|
||||||
|
|
|
@ -142,7 +142,7 @@
|
||||||
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
||||||
...
|
...
|
||||||
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
||||||
<span class="hljs-attr">baseUrl</span>: <span class="hljs-string">'/testProject/'</span>,
|
baseUrl: <span class="hljs-string">'/testProject/'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
||||||
...
|
...
|
||||||
|
@ -212,23 +212,23 @@
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
git config --global user.name "<YOUR_NAME>"
|
git config --global user.name "<YOUR_NAME>"
|
||||||
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
||||||
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
||||||
|
@ -265,7 +265,7 @@ e.g.</li>
|
||||||
<span class="hljs-attr"> branches:</span>
|
<span class="hljs-attr"> branches:</span>
|
||||||
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
<span class="hljs-attr"> - run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
||||||
|
@ -286,11 +286,11 @@ e.g.</li>
|
||||||
<span class="hljs-attr">cache:</span>
|
<span class="hljs-attr">cache:</span>
|
||||||
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
||||||
<span class="hljs-attr">script:</span>
|
<span class="hljs-attr">script:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">></span> <span class="hljs-string">~/.netrc</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">> ~/.netrc
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">cd</span> <span class="hljs-string">website</span> <span class="hljs-string">&&</span> <span class="hljs-string">yarn</span> <span class="hljs-string">install</span> <span class="hljs-string">&&</span> <span class="hljs-string">GIT_USER="${GH_NAME}"</span> <span class="hljs-string">yarn</span> <span class="hljs-string">run</span> <span class="hljs-string">publish-gh-pages</span>
|
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
|
||||||
</code></pre>
|
</span></code></pre>
|
||||||
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
||||||
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
||||||
|
|
|
@ -142,7 +142,7 @@
|
||||||
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
||||||
...
|
...
|
||||||
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
||||||
<span class="hljs-attr">baseUrl</span>: <span class="hljs-string">'/testProject/'</span>,
|
baseUrl: <span class="hljs-string">'/testProject/'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
||||||
...
|
...
|
||||||
|
@ -212,23 +212,23 @@
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
git config --global user.name "<YOUR_NAME>"
|
git config --global user.name "<YOUR_NAME>"
|
||||||
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
||||||
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
<p>Make sure to replace all <code><....></code> in the <code>command:</code> sequence with appropriate values. For <code><GIT_USER></code>, it should be a GitHub account that has access to push documentation to your GitHub repository. Many times <code><GIT_USER></code> and <code><GITHUB_USERNAME></code> will be the same.</p>
|
||||||
|
@ -265,7 +265,7 @@ e.g.</li>
|
||||||
<span class="hljs-attr"> branches:</span>
|
<span class="hljs-attr"> branches:</span>
|
||||||
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
<span class="hljs-attr"> - run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
||||||
|
@ -286,11 +286,11 @@ e.g.</li>
|
||||||
<span class="hljs-attr">cache:</span>
|
<span class="hljs-attr">cache:</span>
|
||||||
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
||||||
<span class="hljs-attr">script:</span>
|
<span class="hljs-attr">script:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">></span> <span class="hljs-string">~/.netrc</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">> ~/.netrc
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">cd</span> <span class="hljs-string">website</span> <span class="hljs-string">&&</span> <span class="hljs-string">yarn</span> <span class="hljs-string">install</span> <span class="hljs-string">&&</span> <span class="hljs-string">GIT_USER="${GH_NAME}"</span> <span class="hljs-string">yarn</span> <span class="hljs-string">run</span> <span class="hljs-string">publish-gh-pages</span>
|
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
|
||||||
</code></pre>
|
</span></code></pre>
|
||||||
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
<h3><a class="anchor" aria-hidden="true" id="hosting-on-zeit-now"></a><a href="#hosting-on-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hosting on ZEIT Now</h3>
|
||||||
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
<p>With <a href="#using-zeit-now">ZEIT Now</a>, you can deploy your site easily and connect it to <a href="https://zeit.co/github">GitHub</a> or <a href="https://zeit.co/gitlab">GitLab</a> to automatically receive a new deployment every time you push a commit.</p>
|
||||||
|
|
|
@ -209,17 +209,17 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<p><a href="/docs/en/doc-markdown">Syntax highlighting</a> options:</p>
|
<p><a href="/docs/en/doc-markdown">Syntax highlighting</a> options:</p>
|
||||||
<pre><code class="hljs css language-js">{
|
<pre><code class="hljs css language-js">{
|
||||||
<span class="hljs-comment">// ...</span>
|
<span class="hljs-comment">// ...</span>
|
||||||
<span class="hljs-attr">highlight</span>: {
|
highlight: {
|
||||||
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
||||||
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
||||||
<span class="hljs-attr">theme</span>: <span class="hljs-string">'default'</span>,
|
theme: <span class="hljs-string">'default'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
||||||
<span class="hljs-attr">version</span>: <span class="hljs-string">'9.12.0'</span>,
|
version: <span class="hljs-string">'9.12.0'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
||||||
<span class="hljs-attr">hljs</span>: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
hljs: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
||||||
<span class="hljs-comment">// do something here</span>
|
<span class="hljs-comment">// do something here</span>
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -227,10 +227,10 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
||||||
|
|
||||||
<span class="hljs-attr">defaultLang</span>: <span class="hljs-string">'javascript'</span>,
|
defaultLang: <span class="hljs-string">'javascript'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
||||||
<span class="hljs-attr">themeUrl</span>: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
themeUrl: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
@ -312,12 +312,12 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
||||||
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
||||||
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
||||||
<span class="hljs-attr">defaultVersionShown</span>: <span class="hljs-string">'1.0.0'</span>,
|
defaultVersionShown: <span class="hljs-string">'1.0.0'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
||||||
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
||||||
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
||||||
<span class="hljs-attr">headerLinks</span>: [
|
headerLinks: [
|
||||||
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
||||||
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
||||||
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
||||||
|
|
|
@ -209,17 +209,17 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<p><a href="/docs/en/doc-markdown">Syntax highlighting</a> options:</p>
|
<p><a href="/docs/en/doc-markdown">Syntax highlighting</a> options:</p>
|
||||||
<pre><code class="hljs css language-js">{
|
<pre><code class="hljs css language-js">{
|
||||||
<span class="hljs-comment">// ...</span>
|
<span class="hljs-comment">// ...</span>
|
||||||
<span class="hljs-attr">highlight</span>: {
|
highlight: {
|
||||||
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
||||||
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
||||||
<span class="hljs-attr">theme</span>: <span class="hljs-string">'default'</span>,
|
theme: <span class="hljs-string">'default'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
||||||
<span class="hljs-attr">version</span>: <span class="hljs-string">'9.12.0'</span>,
|
version: <span class="hljs-string">'9.12.0'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
||||||
<span class="hljs-attr">hljs</span>: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
hljs: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
||||||
<span class="hljs-comment">// do something here</span>
|
<span class="hljs-comment">// do something here</span>
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -227,10 +227,10 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
||||||
|
|
||||||
<span class="hljs-attr">defaultLang</span>: <span class="hljs-string">'javascript'</span>,
|
defaultLang: <span class="hljs-string">'javascript'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
||||||
<span class="hljs-attr">themeUrl</span>: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
themeUrl: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
@ -312,12 +312,12 @@ If unset, it is defaulted to <code>docs</code>.</p>
|
||||||
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
||||||
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
||||||
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
||||||
<span class="hljs-attr">defaultVersionShown</span>: <span class="hljs-string">'1.0.0'</span>,
|
defaultVersionShown: <span class="hljs-string">'1.0.0'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
||||||
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
||||||
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
||||||
<span class="hljs-attr">headerLinks</span>: [
|
headerLinks: [
|
||||||
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
||||||
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
||||||
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
||||||
|
|
|
@ -266,11 +266,11 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
|
@ -287,12 +287,12 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
- crowdin --config crowdin.yaml download -b master
|
- crowdin --config crowdin.yaml download -b master
|
||||||
# build and publish website
|
# build and publish website
|
||||||
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
||||||
|
|
|
@ -266,11 +266,11 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
<span class="hljs-attr"> deploy-website:</span>
|
<span class="hljs-attr"> deploy-website:</span>
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
|
@ -287,12 +287,12 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
- crowdin --config crowdin.yaml download -b master
|
- crowdin --config crowdin.yaml download -b master
|
||||||
# build and publish website
|
# build and publish website
|
||||||
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
||||||
|
|
|
@ -86,13 +86,13 @@
|
||||||
<ol>
|
<ol>
|
||||||
<li>Edit the file <code>docusaurus-tutorial/website/siteConfig.js</code> and fill in the following values:</li>
|
<li>Edit the file <code>docusaurus-tutorial/website/siteConfig.js</code> and fill in the following values:</li>
|
||||||
</ol>
|
</ol>
|
||||||
<pre><code class="hljs"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs">const siteConfig = {
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
||||||
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
||||||
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
||||||
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<ol start="2">
|
<ol start="2">
|
||||||
|
|
|
@ -86,13 +86,13 @@
|
||||||
<ol>
|
<ol>
|
||||||
<li>Edit the file <code>docusaurus-tutorial/website/siteConfig.js</code> and fill in the following values:</li>
|
<li>Edit the file <code>docusaurus-tutorial/website/siteConfig.js</code> and fill in the following values:</li>
|
||||||
</ol>
|
</ol>
|
||||||
<pre><code class="hljs"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs">const siteConfig = {
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
url: <span class="hljs-string">'https://USERNAME.github.io'</span>, <span class="hljs-comment">// Replace USERNAME with your GitHub username.</span>
|
||||||
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
baseUrl: <span class="hljs-string">'/docusaurus-tutorial/'</span>, <span class="hljs-comment">// The name of your GitHub project.</span>
|
||||||
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
projectName: <span class="hljs-string">'docusaurus-tutorial'</span>, <span class="hljs-comment">// The name of your GitHub project. Same as above.</span>
|
||||||
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
organizationName: <span class="hljs-string">'USERNAME'</span> <span class="hljs-comment">// Your GitHub username.</span>
|
||||||
...
|
<span class="hljs-params">...</span>
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<ol start="2">
|
<ol start="2">
|
||||||
|
|
|
@ -94,7 +94,7 @@
|
||||||
<p>Par exemple, dans <code>site/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
<p>Par exemple, dans <code>site/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">https://twitter.com/foobarbaz</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">https://twitter.com/foobarbaz</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -94,7 +94,7 @@
|
||||||
<p>Par exemple, dans <code>site/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
<p>Par exemple, dans <code>site/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">https://twitter.com/foobarbaz</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">https://twitter.com/foobarbaz</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -90,9 +90,9 @@
|
||||||
<p><code>sidebar_label</code>: The text shown in the document sidebar and in the next/previous button for this document. If this field is not present, the document's <code>sidebar_label</code> will default to its <code>title</code>.</p>
|
<p><code>sidebar_label</code>: The text shown in the document sidebar and in the next/previous button for this document. If this field is not present, the document's <code>sidebar_label</code> will default to its <code>title</code>.</p>
|
||||||
<p>Par exemple :</p>
|
<p>Par exemple :</p>
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id :</span> <span class="hljs-string">doc1</span>
|
<span class="hljs-string">id</span> <span class="hljs-string">:</span> <span class="hljs-string">doc1</span>
|
||||||
<span class="hljs-attr">titre :</span> <span class="hljs-string">Mon</span> <span class="hljs-string">Document</span>
|
<span class="hljs-string">titre</span> <span class="hljs-string">:</span> <span class="hljs-string">Mon</span> <span class="hljs-string">Document</span>
|
||||||
<span class="hljs-attr">sidebar_label :</span> <span class="hljs-string">Document</span>
|
<span class="hljs-string">sidebar_label</span> <span class="hljs-string">:</span> <span class="hljs-string">Document</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Versioned documents have their ids altered to include the version number when they get copied. The new <code>id</code> is <code>version-${version}-${id}</code> where <code>${version}</code> is the version number of that document and <code>${id}</code> is the original <code>id</code>. Additionally, versioned documents get an added <code>original_id</code> field with the original document id.</p>
|
<p>Versioned documents have their ids altered to include the version number when they get copied. The new <code>id</code> is <code>version-${version}-${id}</code> where <code>${version}</code> is the version number of that document and <code>${id}</code> is the original <code>id</code>. Additionally, versioned documents get an added <code>original_id</code> field with the original document id.</p>
|
||||||
|
@ -109,7 +109,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Fonctionnalités</span> <span class="hljs-string">de</span> <span class="hljs-string">Markdown</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Fonctionnalités</span> <span class="hljs-string">de</span> <span class="hljs-string">Markdown</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="publications-de-blog"></a><a href="#publications-de-blog" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Publications de blog</h3>
|
<h3><a class="anchor" aria-hidden="true" id="publications-de-blog"></a><a href="#publications-de-blog" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Publications de blog</h3>
|
||||||
|
@ -122,7 +122,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Mon</span> <span class="hljs-string">premier</span> <span class="hljs-string">post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Mon</span> <span class="hljs-string">premier</span> <span class="hljs-string">post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -90,9 +90,9 @@
|
||||||
<p><code>sidebar_label</code>: The text shown in the document sidebar and in the next/previous button for this document. If this field is not present, the document's <code>sidebar_label</code> will default to its <code>title</code>.</p>
|
<p><code>sidebar_label</code>: The text shown in the document sidebar and in the next/previous button for this document. If this field is not present, the document's <code>sidebar_label</code> will default to its <code>title</code>.</p>
|
||||||
<p>Par exemple :</p>
|
<p>Par exemple :</p>
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id :</span> <span class="hljs-string">doc1</span>
|
<span class="hljs-string">id</span> <span class="hljs-string">:</span> <span class="hljs-string">doc1</span>
|
||||||
<span class="hljs-attr">titre :</span> <span class="hljs-string">Mon</span> <span class="hljs-string">Document</span>
|
<span class="hljs-string">titre</span> <span class="hljs-string">:</span> <span class="hljs-string">Mon</span> <span class="hljs-string">Document</span>
|
||||||
<span class="hljs-attr">sidebar_label :</span> <span class="hljs-string">Document</span>
|
<span class="hljs-string">sidebar_label</span> <span class="hljs-string">:</span> <span class="hljs-string">Document</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Versioned documents have their ids altered to include the version number when they get copied. The new <code>id</code> is <code>version-${version}-${id}</code> where <code>${version}</code> is the version number of that document and <code>${id}</code> is the original <code>id</code>. Additionally, versioned documents get an added <code>original_id</code> field with the original document id.</p>
|
<p>Versioned documents have their ids altered to include the version number when they get copied. The new <code>id</code> is <code>version-${version}-${id}</code> where <code>${version}</code> is the version number of that document and <code>${id}</code> is the original <code>id</code>. Additionally, versioned documents get an added <code>original_id</code> field with the original document id.</p>
|
||||||
|
@ -109,7 +109,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Fonctionnalités</span> <span class="hljs-string">de</span> <span class="hljs-string">Markdown</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Fonctionnalités</span> <span class="hljs-string">de</span> <span class="hljs-string">Markdown</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="publications-de-blog"></a><a href="#publications-de-blog" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Publications de blog</h3>
|
<h3><a class="anchor" aria-hidden="true" id="publications-de-blog"></a><a href="#publications-de-blog" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Publications de blog</h3>
|
||||||
|
@ -122,7 +122,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Mon</span> <span class="hljs-string">premier</span> <span class="hljs-string">post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Mon</span> <span class="hljs-string">premier</span> <span class="hljs-string">post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -139,7 +139,7 @@
|
||||||
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
||||||
...
|
...
|
||||||
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
||||||
<span class="hljs-attr">baseUrl</span>: <span class="hljs-string">'/testProject/'</span>,
|
baseUrl: <span class="hljs-string">'/testProject/'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
||||||
...
|
...
|
||||||
|
@ -210,25 +210,25 @@
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
|
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
|
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
git config --global user.name "<YOUR_NAME>"
|
git config --global user.name "<YOUR_NAME>"
|
||||||
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
||||||
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
|
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Assurez-vous de remplacer tous les <code><....></code> dans la <code>commande:</code> avec des valeurs appropriées. Pour <code><GIT_USER></code>, c'est un compte GitHub qui a accès à la documentation pour push dans votre dépôt GitHub. De nombreuses fois <code><GIT_USER></code> et <code><GITHUB_USERNAME></code> seront les mêmes.</p>
|
<p>Assurez-vous de remplacer tous les <code><....></code> dans la <code>commande:</code> avec des valeurs appropriées. Pour <code><GIT_USER></code>, c'est un compte GitHub qui a accès à la documentation pour push dans votre dépôt GitHub. De nombreuses fois <code><GIT_USER></code> et <code><GITHUB_USERNAME></code> seront les mêmes.</p>
|
||||||
|
@ -262,7 +262,7 @@
|
||||||
<span class="hljs-attr"> branches:</span>
|
<span class="hljs-attr"> branches:</span>
|
||||||
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
<span class="hljs-attr"> - run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
||||||
|
@ -283,11 +283,11 @@
|
||||||
<span class="hljs-attr">cache:</span>
|
<span class="hljs-attr">cache:</span>
|
||||||
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
||||||
<span class="hljs-attr">script:</span>
|
<span class="hljs-attr">script:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">></span> <span class="hljs-string">~/.netrc</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">> ~/.netrc
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">cd</span> <span class="hljs-string">website</span> <span class="hljs-string">&&</span> <span class="hljs-string">yarn</span> <span class="hljs-string">install</span> <span class="hljs-string">&&</span> <span class="hljs-string">GIT_USER="${GH_NAME}"</span> <span class="hljs-string">yarn</span> <span class="hljs-string">run</span> <span class="hljs-string">publish-gh-pages</span>
|
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
|
||||||
</code></pre>
|
</span></code></pre>
|
||||||
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="hebergement-sur-zeit-now"></a><a href="#hebergement-sur-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hébergement sur ZEIT now</h3>
|
<h3><a class="anchor" aria-hidden="true" id="hebergement-sur-zeit-now"></a><a href="#hebergement-sur-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hébergement sur ZEIT now</h3>
|
||||||
<p>Avec <a href="#using-zeit-now">ZEIT Now</a>, vous pouvez déployer votre site facilement et le connecter à <a href="https://zeit.co/github">GitHub</a> ou <a href="https://zeit.co/gitlab">GitLab</a> pour recevoir automatiquement un nouveau déploiement à chaque fois que vous pousser un commit.</p>
|
<p>Avec <a href="#using-zeit-now">ZEIT Now</a>, vous pouvez déployer votre site facilement et le connecter à <a href="https://zeit.co/github">GitHub</a> ou <a href="https://zeit.co/gitlab">GitLab</a> pour recevoir automatiquement un nouveau déploiement à chaque fois que vous pousser un commit.</p>
|
||||||
|
|
|
@ -139,7 +139,7 @@
|
||||||
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
||||||
...
|
...
|
||||||
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
||||||
<span class="hljs-attr">baseUrl</span>: <span class="hljs-string">'/testProject/'</span>,
|
baseUrl: <span class="hljs-string">'/testProject/'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
||||||
...
|
...
|
||||||
|
@ -210,25 +210,25 @@
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
|
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
|
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
git config --global user.name "<YOUR_NAME>"
|
git config --global user.name "<YOUR_NAME>"
|
||||||
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
||||||
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
|
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Assurez-vous de remplacer tous les <code><....></code> dans la <code>commande:</code> avec des valeurs appropriées. Pour <code><GIT_USER></code>, c'est un compte GitHub qui a accès à la documentation pour push dans votre dépôt GitHub. De nombreuses fois <code><GIT_USER></code> et <code><GITHUB_USERNAME></code> seront les mêmes.</p>
|
<p>Assurez-vous de remplacer tous les <code><....></code> dans la <code>commande:</code> avec des valeurs appropriées. Pour <code><GIT_USER></code>, c'est un compte GitHub qui a accès à la documentation pour push dans votre dépôt GitHub. De nombreuses fois <code><GIT_USER></code> et <code><GITHUB_USERNAME></code> seront les mêmes.</p>
|
||||||
|
@ -262,7 +262,7 @@
|
||||||
<span class="hljs-attr"> branches:</span>
|
<span class="hljs-attr"> branches:</span>
|
||||||
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
<span class="hljs-attr"> - run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
||||||
|
@ -283,11 +283,11 @@
|
||||||
<span class="hljs-attr">cache:</span>
|
<span class="hljs-attr">cache:</span>
|
||||||
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
||||||
<span class="hljs-attr">script:</span>
|
<span class="hljs-attr">script:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">></span> <span class="hljs-string">~/.netrc</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">> ~/.netrc
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">cd</span> <span class="hljs-string">website</span> <span class="hljs-string">&&</span> <span class="hljs-string">yarn</span> <span class="hljs-string">install</span> <span class="hljs-string">&&</span> <span class="hljs-string">GIT_USER="${GH_NAME}"</span> <span class="hljs-string">yarn</span> <span class="hljs-string">run</span> <span class="hljs-string">publish-gh-pages</span>
|
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
|
||||||
</code></pre>
|
</span></code></pre>
|
||||||
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="hebergement-sur-zeit-now"></a><a href="#hebergement-sur-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hébergement sur ZEIT now</h3>
|
<h3><a class="anchor" aria-hidden="true" id="hebergement-sur-zeit-now"></a><a href="#hebergement-sur-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hébergement sur ZEIT now</h3>
|
||||||
<p>Avec <a href="#using-zeit-now">ZEIT Now</a>, vous pouvez déployer votre site facilement et le connecter à <a href="https://zeit.co/github">GitHub</a> ou <a href="https://zeit.co/gitlab">GitLab</a> pour recevoir automatiquement un nouveau déploiement à chaque fois que vous pousser un commit.</p>
|
<p>Avec <a href="#using-zeit-now">ZEIT Now</a>, vous pouvez déployer votre site facilement et le connecter à <a href="https://zeit.co/github">GitHub</a> ou <a href="https://zeit.co/gitlab">GitLab</a> pour recevoir automatiquement un nouveau déploiement à chaque fois que vous pousser un commit.</p>
|
||||||
|
|
|
@ -205,17 +205,17 @@
|
||||||
<p><a href="/docs/fr/1.10.x/doc-markdown">Syntax highlighting</a> options:</p>
|
<p><a href="/docs/fr/1.10.x/doc-markdown">Syntax highlighting</a> options:</p>
|
||||||
<pre><code class="hljs css language-js">{
|
<pre><code class="hljs css language-js">{
|
||||||
<span class="hljs-comment">// ...</span>
|
<span class="hljs-comment">// ...</span>
|
||||||
<span class="hljs-attr">highlight</span>: {
|
highlight: {
|
||||||
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
||||||
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
||||||
<span class="hljs-attr">theme</span>: <span class="hljs-string">'default'</span>,
|
theme: <span class="hljs-string">'default'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
||||||
<span class="hljs-attr">version</span>: <span class="hljs-string">'9.12.0'</span>,
|
version: <span class="hljs-string">'9.12.0'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
||||||
<span class="hljs-attr">hljs</span>: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
hljs: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
||||||
<span class="hljs-comment">// do something here</span>
|
<span class="hljs-comment">// do something here</span>
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -223,10 +223,10 @@
|
||||||
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
||||||
|
|
||||||
<span class="hljs-attr">defaultLang</span>: <span class="hljs-string">'javascript'</span>,
|
defaultLang: <span class="hljs-string">'javascript'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
||||||
<span class="hljs-attr">themeUrl</span>: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
themeUrl: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
@ -290,12 +290,12 @@
|
||||||
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
||||||
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
||||||
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
||||||
<span class="hljs-attr">defaultVersionShown</span>: <span class="hljs-string">'1.0.0'</span>,
|
defaultVersionShown: <span class="hljs-string">'1.0.0'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
||||||
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
||||||
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
||||||
<span class="hljs-attr">headerLinks</span>: [
|
headerLinks: [
|
||||||
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
||||||
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
||||||
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
||||||
|
|
|
@ -205,17 +205,17 @@
|
||||||
<p><a href="/docs/fr/1.10.x/doc-markdown">Syntax highlighting</a> options:</p>
|
<p><a href="/docs/fr/1.10.x/doc-markdown">Syntax highlighting</a> options:</p>
|
||||||
<pre><code class="hljs css language-js">{
|
<pre><code class="hljs css language-js">{
|
||||||
<span class="hljs-comment">// ...</span>
|
<span class="hljs-comment">// ...</span>
|
||||||
<span class="hljs-attr">highlight</span>: {
|
highlight: {
|
||||||
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
<span class="hljs-comment">// The name of the theme used by Highlight.js when highlighting code.</span>
|
||||||
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
<span class="hljs-comment">// You can find the list of supported themes here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/styles</span>
|
||||||
<span class="hljs-attr">theme</span>: <span class="hljs-string">'default'</span>,
|
theme: <span class="hljs-string">'default'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
<span class="hljs-comment">// The particular version of Highlight.js to be used.</span>
|
||||||
<span class="hljs-attr">version</span>: <span class="hljs-string">'9.12.0'</span>,
|
version: <span class="hljs-string">'9.12.0'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
<span class="hljs-comment">// Escape valve by passing an instance of Highlight.js to the function specified here, allowing additional languages to be registered for syntax highlighting.</span>
|
||||||
<span class="hljs-attr">hljs</span>: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
hljs: <span class="hljs-function"><span class="hljs-keyword">function</span>(<span class="hljs-params">highlightJsInstance</span>) </span>{
|
||||||
<span class="hljs-comment">// do something here</span>
|
<span class="hljs-comment">// do something here</span>
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -223,10 +223,10 @@
|
||||||
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
<span class="hljs-comment">// It will be used if one is not specified at the top of the code block. You can find the list of supported languages here:</span>
|
||||||
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
<span class="hljs-comment">// https://github.com/isagalaev/highlight.js/tree/master/src/languages</span>
|
||||||
|
|
||||||
<span class="hljs-attr">defaultLang</span>: <span class="hljs-string">'javascript'</span>,
|
defaultLang: <span class="hljs-string">'javascript'</span>,
|
||||||
|
|
||||||
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
<span class="hljs-comment">// custom URL of CSS theme file that you want to use with Highlight.js. If this is provided, the `theme` and `version` fields will be ignored.</span>
|
||||||
<span class="hljs-attr">themeUrl</span>: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
themeUrl: <span class="hljs-string">'http://foo.bar/custom.css'</span>
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
@ -290,12 +290,12 @@
|
||||||
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
<span class="hljs-comment">// For github.io type URLS, you would combine the URL and baseUrl like:</span>
|
||||||
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
<span class="hljs-comment">// url: 'https://reasonml.github.io',</span>
|
||||||
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
<span class="hljs-comment">// baseUrl: '/reason-react/',</span>
|
||||||
<span class="hljs-attr">defaultVersionShown</span>: <span class="hljs-string">'1.0.0'</span>,
|
defaultVersionShown: <span class="hljs-string">'1.0.0'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'facebook'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'docusaurus'</span>,
|
||||||
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
<span class="hljs-attr">noIndex</span>: <span class="hljs-literal">false</span>,
|
||||||
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
<span class="hljs-comment">// For no header links in the top nav bar -> headerLinks: [],</span>
|
||||||
<span class="hljs-attr">headerLinks</span>: [
|
headerLinks: [
|
||||||
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
{<span class="hljs-attr">doc</span>: <span class="hljs-string">'doc1'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Docs'</span>},
|
||||||
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
{<span class="hljs-attr">page</span>: <span class="hljs-string">'help'</span>, <span class="hljs-attr">label</span>: <span class="hljs-string">'Help'</span>},
|
||||||
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
{<span class="hljs-attr">search</span>: <span class="hljs-literal">true</span>},
|
||||||
|
|
|
@ -261,12 +261,12 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
|
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
|
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
|
@ -283,13 +283,13 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
- crowdin --config crowdin.yaml download -b master
|
- crowdin --config crowdin.yaml download -b master
|
||||||
# build and publish website
|
# build and publish website
|
||||||
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
|
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
||||||
|
|
|
@ -261,12 +261,12 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
|
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
|
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
|
@ -283,13 +283,13 @@ CROWDIN_DOCUSAURUS_PROJECT_ID=YOUR_CROWDIN_PROJECT_ID CROWDIN_DOCUSAURUS_API_KEY
|
||||||
- crowdin --config crowdin.yaml download -b master
|
- crowdin --config crowdin.yaml download -b master
|
||||||
# build and publish website
|
# build and publish website
|
||||||
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
|
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
<p>The <code>crowdin</code> command uses the <code>crowdin.yaml</code> file generated with the <code>examples</code> script. It should be placed in your project directory to configure how and what files are uploaded/downloaded.</p>
|
||||||
|
|
|
@ -94,7 +94,7 @@
|
||||||
<p>Par exemple, dans <code>site/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
<p>Par exemple, dans <code>site/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">https://twitter.com/foobarbaz</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">https://twitter.com/foobarbaz</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -94,7 +94,7 @@
|
||||||
<p>Par exemple, dans <code>site/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
<p>Par exemple, dans <code>site/blog/2017-08-18-Introducing-Docusaurus.md</code>:</p>
|
||||||
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">https://twitter.com/foobarbaz</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">https://twitter.com/foobarbaz</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">503283835</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Introducing</span> <span class="hljs-string">Docusaurus</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
|
|
|
@ -90,9 +90,9 @@
|
||||||
<p><code>sidebar_label</code>: The text shown in the document sidebar and in the next/previous button for this document. If this field is not present, the document's <code>sidebar_label</code> will default to its <code>title</code>.</p>
|
<p><code>sidebar_label</code>: The text shown in the document sidebar and in the next/previous button for this document. If this field is not present, the document's <code>sidebar_label</code> will default to its <code>title</code>.</p>
|
||||||
<p>Par exemple :</p>
|
<p>Par exemple :</p>
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id :</span> <span class="hljs-string">doc1</span>
|
<span class="hljs-string">id</span> <span class="hljs-string">:</span> <span class="hljs-string">doc1</span>
|
||||||
<span class="hljs-attr">titre :</span> <span class="hljs-string">Mon</span> <span class="hljs-string">Document</span>
|
<span class="hljs-string">titre</span> <span class="hljs-string">:</span> <span class="hljs-string">Mon</span> <span class="hljs-string">Document</span>
|
||||||
<span class="hljs-attr">sidebar_label :</span> <span class="hljs-string">Document</span>
|
<span class="hljs-string">sidebar_label</span> <span class="hljs-string">:</span> <span class="hljs-string">Document</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Versioned documents have their ids altered to include the version number when they get copied. The new <code>id</code> is <code>version-${version}-${id}</code> where <code>${version}</code> is the version number of that document and <code>${id}</code> is the original <code>id</code>. Additionally, versioned documents get an added <code>original_id</code> field with the original document id.</p>
|
<p>Versioned documents have their ids altered to include the version number when they get copied. The new <code>id</code> is <code>version-${version}-${id}</code> where <code>${version}</code> is the version number of that document and <code>${id}</code> is the original <code>id</code>. Additionally, versioned documents get an added <code>original_id</code> field with the original document id.</p>
|
||||||
|
@ -109,7 +109,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Fonctionnalités</span> <span class="hljs-string">de</span> <span class="hljs-string">Markdown</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Fonctionnalités</span> <span class="hljs-string">de</span> <span class="hljs-string">Markdown</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="publications-de-blog"></a><a href="#publications-de-blog" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Publications de blog</h3>
|
<h3><a class="anchor" aria-hidden="true" id="publications-de-blog"></a><a href="#publications-de-blog" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Publications de blog</h3>
|
||||||
|
@ -122,7 +122,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Mon</span> <span class="hljs-string">premier</span> <span class="hljs-string">post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Mon</span> <span class="hljs-string">premier</span> <span class="hljs-string">post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -90,9 +90,9 @@
|
||||||
<p><code>sidebar_label</code>: The text shown in the document sidebar and in the next/previous button for this document. If this field is not present, the document's <code>sidebar_label</code> will default to its <code>title</code>.</p>
|
<p><code>sidebar_label</code>: The text shown in the document sidebar and in the next/previous button for this document. If this field is not present, the document's <code>sidebar_label</code> will default to its <code>title</code>.</p>
|
||||||
<p>Par exemple :</p>
|
<p>Par exemple :</p>
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id :</span> <span class="hljs-string">doc1</span>
|
<span class="hljs-string">id</span> <span class="hljs-string">:</span> <span class="hljs-string">doc1</span>
|
||||||
<span class="hljs-attr">titre :</span> <span class="hljs-string">Mon</span> <span class="hljs-string">Document</span>
|
<span class="hljs-string">titre</span> <span class="hljs-string">:</span> <span class="hljs-string">Mon</span> <span class="hljs-string">Document</span>
|
||||||
<span class="hljs-attr">sidebar_label :</span> <span class="hljs-string">Document</span>
|
<span class="hljs-string">sidebar_label</span> <span class="hljs-string">:</span> <span class="hljs-string">Document</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Versioned documents have their ids altered to include the version number when they get copied. The new <code>id</code> is <code>version-${version}-${id}</code> where <code>${version}</code> is the version number of that document and <code>${id}</code> is the original <code>id</code>. Additionally, versioned documents get an added <code>original_id</code> field with the original document id.</p>
|
<p>Versioned documents have their ids altered to include the version number when they get copied. The new <code>id</code> is <code>version-${version}-${id}</code> where <code>${version}</code> is the version number of that document and <code>${id}</code> is the original <code>id</code>. Additionally, versioned documents get an added <code>original_id</code> field with the original document id.</p>
|
||||||
|
@ -109,7 +109,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
<span class="hljs-attr">id:</span> <span class="hljs-string">doc-markdown</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Fonctionnalités</span> <span class="hljs-string">de</span> <span class="hljs-string">Markdown</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Fonctionnalités</span> <span class="hljs-string">de</span> <span class="hljs-string">Markdown</span>
|
||||||
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-string">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
<span class="hljs-attr">custom_edit_url:</span> <span class="hljs-attr">https://github.com/facebook/docusaurus/edit/master/docs/api-doc-markdown.md</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="publications-de-blog"></a><a href="#publications-de-blog" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Publications de blog</h3>
|
<h3><a class="anchor" aria-hidden="true" id="publications-de-blog"></a><a href="#publications-de-blog" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Publications de blog</h3>
|
||||||
|
@ -122,7 +122,7 @@
|
||||||
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
<pre><code class="hljs css language-yaml"><span class="hljs-meta">---</span>
|
||||||
<span class="hljs-attr">title:</span> <span class="hljs-string">Mon</span> <span class="hljs-string">premier</span> <span class="hljs-string">post</span>
|
<span class="hljs-attr">title:</span> <span class="hljs-string">Mon</span> <span class="hljs-string">premier</span> <span class="hljs-string">post</span>
|
||||||
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
<span class="hljs-attr">author:</span> <span class="hljs-string">Frank</span> <span class="hljs-string">Li</span>
|
||||||
<span class="hljs-attr">authorURL:</span> <span class="hljs-string">http://twitter.com/franchementli</span>
|
<span class="hljs-attr">authorURL:</span> <span class="hljs-attr">http://twitter.com/franchementli</span>
|
||||||
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
<span class="hljs-attr">authorFBID:</span> <span class="hljs-number">100002976521003</span>
|
||||||
<span class="hljs-meta">---</span>
|
<span class="hljs-meta">---</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
|
|
|
@ -139,7 +139,7 @@
|
||||||
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
<pre><code class="hljs css language-js"><span class="hljs-keyword">const</span> siteConfig = {
|
||||||
...
|
...
|
||||||
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
url: <span class="hljs-string">'https://__userName__.github.io'</span>, <span class="hljs-comment">// Your website URL</span>
|
||||||
<span class="hljs-attr">baseUrl</span>: <span class="hljs-string">'/testProject/'</span>,
|
baseUrl: <span class="hljs-string">'/testProject/'</span>,
|
||||||
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
<span class="hljs-attr">projectName</span>: <span class="hljs-string">'testProject'</span>,
|
||||||
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
<span class="hljs-attr">organizationName</span>: <span class="hljs-string">'userName'</span>
|
||||||
...
|
...
|
||||||
|
@ -210,25 +210,25 @@
|
||||||
<span class="hljs-attr"> docker:</span>
|
<span class="hljs-attr"> docker:</span>
|
||||||
<span class="hljs-comment"># specify the version you desire here</span>
|
<span class="hljs-comment"># specify the version you desire here</span>
|
||||||
|
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
<span class="hljs-attr"> - image:</span> <span class="hljs-string">circleci/node:8.11.1</span>
|
||||||
|
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
|
|
||||||
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">checkout</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span>
|
<span class="hljs-attr"> - run:</span>
|
||||||
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
<span class="hljs-attr"> name:</span> <span class="hljs-string">Deploying</span> <span class="hljs-string">to</span> <span class="hljs-string">GitHub</span> <span class="hljs-string">Pages</span>
|
||||||
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
<span class="hljs-attr"> command:</span> <span class="hljs-string">|
|
||||||
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
git config --global user.email "<GITHUB_USERNAME>@users.noreply.github.com"
|
||||||
git config --global user.name "<YOUR_NAME>"
|
git config --global user.name "<YOUR_NAME>"
|
||||||
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
echo "machine github.com login <GITHUB_USERNAME> password $GITHUB_TOKEN" > ~/.netrc
|
||||||
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
cd website && yarn install && GIT_USER=<GIT_USER> yarn run publish-gh-pages
|
||||||
</span>
|
|
||||||
<span class="hljs-attr">workflows:</span>
|
</span><span class="hljs-attr">workflows:</span>
|
||||||
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
<span class="hljs-attr"> version:</span> <span class="hljs-number">2</span>
|
||||||
<span class="hljs-attr"> build_and_deploy:</span>
|
<span class="hljs-attr"> build_and_deploy:</span>
|
||||||
<span class="hljs-attr"> jobs:</span>
|
<span class="hljs-attr"> jobs:</span>
|
||||||
|
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">deploy-website:</span>
|
<span class="hljs-attr"> - deploy-website:</span>
|
||||||
<span class="hljs-comment"># filters: *filter-only-master</span>
|
<span class="hljs-comment"># filters: *filter-only-master</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Assurez-vous de remplacer tous les <code><....></code> dans la <code>commande:</code> avec des valeurs appropriées. Pour <code><GIT_USER></code>, c'est un compte GitHub qui a accès à la documentation pour push dans votre dépôt GitHub. De nombreuses fois <code><GIT_USER></code> et <code><GITHUB_USERNAME></code> seront les mêmes.</p>
|
<p>Assurez-vous de remplacer tous les <code><....></code> dans la <code>commande:</code> avec des valeurs appropriées. Pour <code><GIT_USER></code>, c'est un compte GitHub qui a accès à la documentation pour push dans votre dépôt GitHub. De nombreuses fois <code><GIT_USER></code> et <code><GITHUB_USERNAME></code> seront les mêmes.</p>
|
||||||
|
@ -262,7 +262,7 @@
|
||||||
<span class="hljs-attr"> branches:</span>
|
<span class="hljs-attr"> branches:</span>
|
||||||
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
<span class="hljs-attr"> ignore:</span> <span class="hljs-string">gh-pages</span>
|
||||||
<span class="hljs-attr"> steps:</span>
|
<span class="hljs-attr"> steps:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-attr">run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
<span class="hljs-attr"> - run:</span> <span class="hljs-string">echo</span> <span class="hljs-string">"Skipping tests on gh-pages branch"</span>
|
||||||
</code></pre>
|
</code></pre>
|
||||||
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
<p>Save this file as <code>config.yml</code> and place it in a <code>.circleci</code> directory inside your <code>website/static</code> directory.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
<h3><a class="anchor" aria-hidden="true" id="using-travis-ci"></a><a href="#using-travis-ci" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Using Travis CI</h3>
|
||||||
|
@ -283,11 +283,11 @@
|
||||||
<span class="hljs-attr">cache:</span>
|
<span class="hljs-attr">cache:</span>
|
||||||
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
<span class="hljs-attr"> yarn:</span> <span class="hljs-literal">true</span>
|
||||||
<span class="hljs-attr">script:</span>
|
<span class="hljs-attr">script:</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.name</span> <span class="hljs-string">"${GH_NAME}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-string">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">git</span> <span class="hljs-string">config</span> <span class="hljs-bullet">--global</span> <span class="hljs-string">user.email</span> <span class="hljs-string">"${GH_EMAIL}"</span>
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">></span> <span class="hljs-string">~/.netrc</span>
|
<span class="hljs-bullet"> -</span> <span class="hljs-string">echo</span> <span class="hljs-string">"machine github.com login ${GH_NAME} password ${GH_TOKEN}"</span> <span class="hljs-string">> ~/.netrc
|
||||||
<span class="hljs-bullet">-</span> <span class="hljs-string">cd</span> <span class="hljs-string">website</span> <span class="hljs-string">&&</span> <span class="hljs-string">yarn</span> <span class="hljs-string">install</span> <span class="hljs-string">&&</span> <span class="hljs-string">GIT_USER="${GH_NAME}"</span> <span class="hljs-string">yarn</span> <span class="hljs-string">run</span> <span class="hljs-string">publish-gh-pages</span>
|
- cd website && yarn install && GIT_USER="${GH_NAME}" yarn run publish-gh-pages
|
||||||
</code></pre>
|
</span></code></pre>
|
||||||
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
<p>Now, whenever a new commit lands in <code>master</code>, Travis CI will run your suite of tests and, if everything passes, your website will be deployed via the <code>publish-gh-pages</code> script.</p>
|
||||||
<h3><a class="anchor" aria-hidden="true" id="hebergement-sur-zeit-now"></a><a href="#hebergement-sur-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hébergement sur ZEIT now</h3>
|
<h3><a class="anchor" aria-hidden="true" id="hebergement-sur-zeit-now"></a><a href="#hebergement-sur-zeit-now" aria-hidden="true" class="hash-link"><svg class="hash-link-icon" aria-hidden="true" height="16" version="1.1" viewBox="0 0 16 16" width="16"><path fill-rule="evenodd" d="M4 9h1v1H4c-1.5 0-3-1.69-3-3.5S2.55 3 4 3h4c1.45 0 3 1.69 3 3.5 0 1.41-.91 2.72-2 3.25V8.59c.58-.45 1-1.27 1-2.09C10 5.22 8.98 4 8 4H4c-.98 0-2 1.22-2 2.5S3 9 4 9zm9-3h-1v1h1c1 0 2 1.22 2 2.5S13.98 12 13 12H9c-.98 0-2-1.22-2-2.5 0-.83.42-1.64 1-2.09V6.25c-1.09.53-2 1.84-2 3.25C6 11.31 7.55 13 9 13h4c1.45 0 3-1.69 3-3.5S14.5 6 13 6z"></path></svg></a>Hébergement sur ZEIT now</h3>
|
||||||
<p>Avec <a href="#using-zeit-now">ZEIT Now</a>, vous pouvez déployer votre site facilement et le connecter à <a href="https://zeit.co/github">GitHub</a> ou <a href="https://zeit.co/gitlab">GitLab</a> pour recevoir automatiquement un nouveau déploiement à chaque fois que vous pousser un commit.</p>
|
<p>Avec <a href="#using-zeit-now">ZEIT Now</a>, vous pouvez déployer votre site facilement et le connecter à <a href="https://zeit.co/github">GitHub</a> ou <a href="https://zeit.co/gitlab">GitLab</a> pour recevoir automatiquement un nouveau déploiement à chaque fois que vous pousser un commit.</p>
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue