Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into testing-fixes
- Loading branch information
Showing
18 changed files
with
12,521 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
You will need to to have `Node >= 8.x` and `Yarn >= 1.5`. | ||
|
||
# Run the local server | ||
|
||
1. Make sure all the dependencies for the website are installed: | ||
|
||
```sh | ||
$ yarn | ||
``` | ||
or | ||
```sh | ||
$ npm install | ||
``` | ||
|
||
2. Go to the `website` directory and run your dev server: | ||
|
||
```sh | ||
$ yarn start | ||
``` | ||
or | ||
```sh | ||
$ npm run start | ||
``` | ||
|
||
## Directory Structure | ||
|
||
Your project file structure should look something like this | ||
|
||
``` | ||
my-docusaurus/ | ||
docs/ | ||
cli.md | ||
website/ | ||
blog/ | ||
core/ | ||
node_modules/ | ||
pages/ | ||
static/ | ||
css/ | ||
img/ | ||
versioned_docs/ | ||
versioned_sidebars/ | ||
README.md | ||
package.json | ||
sidebar.json | ||
siteConfig.js | ||
versions.json | ||
``` | ||
|
||
# Publish the website | ||
The Claycli website will live on GitHub page. You just need to run the following commands: | ||
``` | ||
$ yarn build | ||
``` | ||
or | ||
``` | ||
$ npm run build | ||
``` | ||
|
||
Then you just need to deploy the static files generated. These files will be pushed to the `gh-page` branch. | ||
``` | ||
$ yarn deploy | ||
``` | ||
or | ||
``` | ||
$ npm run deploy | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
/** | ||
* Copyright (c) 2017-present, Facebook, Inc. | ||
* | ||
* This source code is licensed under the MIT license found in the | ||
* LICENSE file in the root directory of this source tree. | ||
*/ | ||
|
||
const React = require('react'); | ||
|
||
class Footer extends React.Component { | ||
docUrl(doc, language) { | ||
const baseUrl = this.props.config.baseUrl; | ||
const docsUrl = this.props.config.docsUrl; | ||
const docsPart = `${docsUrl ? `${docsUrl}/` : ''}`; | ||
const langPart = `${language ? `${language}/` : ''}`; | ||
return `${baseUrl}${docsPart}${langPart}${doc}`; | ||
} | ||
|
||
pageUrl(doc, language) { | ||
const baseUrl = this.props.config.baseUrl; | ||
return baseUrl + (language ? `${language}/` : '') + doc; | ||
} | ||
|
||
render() { | ||
return ( | ||
<footer className="nav-footer" id="footer"> | ||
<section className="sitemap"> | ||
<a href={this.props.config.baseUrl} className="nav-home"> | ||
{this.props.config.footerIcon && ( | ||
<img | ||
src={this.props.config.baseUrl + this.props.config.footerIcon} | ||
alt={this.props.config.title} | ||
width="66" | ||
height="58" | ||
/> | ||
)} | ||
</a> | ||
<div> | ||
<h5>Docs</h5> | ||
<a href={this.docUrl('cli.html', this.props.language)}> | ||
Claycli | ||
</a> | ||
</div> | ||
<div> | ||
<h5>Community</h5> | ||
</div> | ||
<div> | ||
<h5>More</h5> | ||
<a href="https://github.com/clay/claycli">GitHub</a> | ||
<a | ||
className="github-button" | ||
href={this.props.config.repoUrl} | ||
data-icon="octicon-star" | ||
data-count-href="/clay/claycli/stargazers" | ||
data-show-count="true" | ||
data-count-aria-label="# stargazers on GitHub" | ||
aria-label="Star Claycli on GitHub"> | ||
Star | ||
</a> | ||
</div> | ||
</section> | ||
|
||
<section className="copyright">{this.props.config.copyright}</section> | ||
</footer> | ||
); | ||
} | ||
} | ||
|
||
module.exports = Footer; |
Oops, something went wrong.