From adb60ff86356115aa0050aea989bdd92fc9fbb45 Mon Sep 17 00:00:00 2001 From: Joe Hand Date: Sat, 17 Dec 2016 13:45:55 -0800 Subject: autodeploy on deploy branch. update readmes --- .travis.yml | 2 +- README.md | 33 +++++++++------------------------ docs/readme.md | 18 +++++++++++++----- 3 files changed, 23 insertions(+), 30 deletions(-) diff --git a/.travis.yml b/.travis.yml index 9c03b91..70dbd85 100644 --- a/.travis.yml +++ b/.travis.yml @@ -4,7 +4,7 @@ node_js: branches: only: - - master + - deploy before_script: - git config --global user.email "robot@overlord.industries" diff --git a/README.md b/README.md index b8903c7..9402a50 100644 --- a/README.md +++ b/README.md @@ -8,46 +8,31 @@ Repository for the documentation of the Dat Project ecosystem. View the docs at ## Writing & Editing Docs -[See docs folder](docs/readme.md) for information on editing and adding docs. Once you finish editing the docs, follow the update & deploy docs instructions. +[See docs folder](docs/readme.md) for information on editing and adding docs. Once you finish editing the docs, send a PR to the `deploy` branch to get the edits automatically deployed. -## Installation & Usage +## Development -This documentation uses [minidocs](https://www.npmjs.com/package/minidocs). +This documentation uses [minidocs](https://github.com/freeman-lab/minidocs) for layout, [ecosystem-docs](https://github.com/hughsk/ecosystem-docs) to get documentation from other modules, and ideas from [pull-stream-docs](https://github.com/pull-stream/pull-stream-docs) for auto travis deployment. ### Viewing Docs Locally 1. Clone Repository 2. `npm install` 3. `npm run build:local` to build the docs for local viewing +4. `npm run update` to update external modules 4. `npm run start` to view the docs in browser -### Updating & Deploying Docs +### Deployment -1. Clone Repository -2. `npm install` -3. Make documentation edits -4. `npm run deploy` to build docs & deploy to GitHub pages.` - -### Updating External Module Docs - -We use [ecosystem-docs](https://github.com/hughsk/ecosystem-docs) to get documentation from other modules. +Deployment happens automatically via Travis when updates are pushed to the deploy branch. -1. `npm run update` will update the list of repositories and download the latest docs. -2. Deploy! +### NPM Commands -## NPM Commands - -All the npm commands - -* `npm run deploy`: build and deploy to github -* `npm run build:deploy`: build full html pages & css for deployment -* `npm run build:local`: build app & css for local viewing * `npm start`: start budo server to view locally +* `npm update`: update external module readme files +* `npm run build:local`: build app & css for local viewing * `npm run build:css`: build css, runs with both build commands * `npm run watch:css`: watch css live and build:local with changes -* `npm update`: run both update commands -* `npm run update:list` updates the repository list only -* `npm run update:build` downloads the latest readme to the docs folder. * `npm run paper`: create the paper with pandoc ## License diff --git a/docs/readme.md b/docs/readme.md index 6597fc3..0b0302c 100644 --- a/docs/readme.md +++ b/docs/readme.md @@ -1,6 +1,14 @@ -## Writing Documentation +# Writing & Updating Documentation -1. Add file to this folder -2. Write docs -3. Add to table of contents in `contents.json` -4. Build & Deploy (see main readme) +This documentation uses [minidocs](https://github.com/freeman-lab/minidocs). + +## Adding New Pages + +1. Add the page as a markdown file in this directory. +2. Edit `contents.json` to add to the TOC. + +## Deploying to Website + +1. Write documentation +2. Open PR to the `deploy` branch +3. When PR is merged, Travis will automatically deploy the docs! -- cgit v1.2.3