Skip to content

Commit

Permalink
Merge branch 'master' into testing-fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
jonwinton committed Feb 14, 2019
2 parents c5b5305 + 377987b commit 4ebb832
Show file tree
Hide file tree
Showing 18 changed files with 12,521 additions and 0 deletions.
12 changes: 12 additions & 0 deletions .gitignore
Expand Up @@ -38,3 +38,15 @@ jspm_packages

# ide
.idea

# docusaurus
.DS_Store

lib/core/metadata.js
lib/core/MetadataBlog.js

website/translated_docs
website/build/
website/yarn.lock
website/node_modules
website/i18n/*
884 changes: 884 additions & 0 deletions docs/cli.md

Large diffs are not rendered by default.

67 changes: 67 additions & 0 deletions website/README.md
@@ -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
```
69 changes: 69 additions & 0 deletions website/core/Footer.js
@@ -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;

0 comments on commit 4ebb832

Please sign in to comment.