• Stars
    star
    130
  • Rank 277,575 (Top 6 %)
  • Language
    TypeScript
  • License
    Other
  • Created about 12 years ago
  • Updated 6 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Source website for openrefine.org

OpenRefine.org website

We use Docusaurus 2 for our website.

If you want to run it locally, you can follow the instructions below, otherwise you should be able to edit most pages directly with a Markdown editor. Opening a pull request for your changes will generate a preview that you can browse to check the rendering.

Requirements

Assuming you have Node.js (LTS recommended) installed (which includes npm), you can install Docusaurus with:

You will need to install Yarn before you can build the site.

npm install -g yarn

Installation

Once you have installed yarn, navigate to docs directory & set-up the dependencies.

cd docs
yarn

Local Development

yarn start

This command starts a local development server and opens up a browser window. Usually at the URL http://localhost:3000 Most changes are reflected live without having to restart the server.

If you get an error starting yarn mentioning update.latest such as

>yarn start

if (notifier.update && semver.gt(this.update.latest, this.update.current)) {
TypeError: Cannot read property 'latest' of undefined
    at Object.<anonymous> (E:\GitHubRepos\OpenRefine\docs\node_modules\@docusaurus\core\bin\docusaurus.js:49:46)
error Command failed with exit code 1.

then it is likely that you will need to first run

yarn upgrade

which will update all dependencies and store them in the yarn.lock file to also be committed.

Next version of OpenRefine docs

If you wish to work on the next version of docs for OpenRefine (master branch) then you will need to:

  1. Git checkout our master branch
  2. Edit files under docs/docs/
  3. Preview changes with the URL kept pointing to http://localhost:3000/next which will automatically show changes live with yarn after you save a file.

Build

yarn build

This command generates static content into the build directory and can be served using any static contents hosting service.

(Optional) Test Build Locally

You can locally test (with parameters) the static content in the build directory (in case you don't have access to a hosting service) by using:

yarn serve

or to build and then serve locally with one command:

yarn serve --build

Deployment

GIT_USER=<Your GitHub username> USE_SSH=true yarn deploy

If you are using GitHub pages for hosting, this command is a convenient way to build the website and push to the gh-pages branch.

License

This website is published under the Creative Commons Attribution 4.0 International License.