Skip to content

Commit

Permalink
chore: updated marko and updated readme and config
Browse files Browse the repository at this point in the history
  • Loading branch information
agliga committed Aug 19, 2024
1 parent ab472df commit f030e4f
Show file tree
Hide file tree
Showing 7 changed files with 3,963 additions and 7,610 deletions.
File renamed without changes.
36 changes: 9 additions & 27 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,6 @@ This page contains instructions and guidelines for anybody contributing code to
## System Requirements

- [Node.js](https://nodejs.org/en/)
- [Ruby](https://www.ruby-lang.org/en/)<sup>\*</sup>
- [Bundler](http://bundler.io)
- [Jekyll](https://jekyllrb.com) ([install via Bundler](https://help.github.com/articles/setting-up-your-github-pages-site-locally-with-jekyll/#step-2-install-jekyll-using-bundler))

<sup>\*</sup> macOS users may encounter issues with their pre-installed system version of Ruby; in which case we recommend [rbenv](https://github.com/rbenv/rbenv) as a way to manage your Ruby environment.

## Contribution Steps

Expand Down Expand Up @@ -389,34 +384,22 @@ As internal contributors may see in `package.json`, there are two other scripts,

First, be sure to Run `npm install` to install all dependencies from NPM.

We use [Jekyll](http://jekyllrb.com) to generate HTML from templates, [LESS](https://lesscss.org) to preprocess and compile CSS, and [Babel](https://babeljs.io/) with [Webpack](https://webpack.js.org/) to compile and bundle JS. The website can be run and hosted locally (see next section) during development.

We use [Bundler](http://bundler.io) to install, update and run Jekyll in our dev environment. This ensures the same Jekyll environment as GitHub Pages. GitHub have created a nice guide called [Setting up your GitHub Pages site locally with Jekyll](https://help.github.com/articles/setting-up-your-github-pages-site-locally-with-jekyll/) which we recommend you follow.

Once Jekyll is setup successfully, running a build should create the following file structure under `./_site`:
We use [Marko Run](https://github.com/marko-js/run) to generate HTML from templates, [SASS](https://sass-lang.com/) to preprocess and compile CSS. The website can be run and hosted locally (see next section) during development.

- `./_site/static/common/docs.min.js`
- this is the Babel & Webpack output of `./docs/src/js/main.js`
- `./_site/static/dsx/docs.min.css`
- this is the SASS compiler output of `./docs/src/sass/dsx.less`
- `./_site/static/dsx/skin.min.css`
- the full, minified skin css bundle (only used in development environment)
- `./_site/index.html`
- homepage
- `./_site/archive`
- archive of old versions of website
In order to run a dev server of the site, you can run `npm run dev`. This launches the server which should allow you to see updates as you change your CSS or HTML. This will launch the site at http://localhost:3000

This is the exact same structure that will be generated by GitHub Pages.
Our site source is located in `src/routes`. These provide the basic site routing. Inside `src/components` are our common components which we use to show repeated parts of the site (such as syntax highlighting our code). Finally, all top level modules are located in `src/modules`. All these files will be used as the component name as well as in the nav. These are auto discoverable.

Our GitHub Pages source is located in the `docs` folder.
To build the site, run `npm run deploy`. This will create all the site assets in `_site`.

In order to start developing the website simply run: `npm start` which will build, bundle and run a BrowserSync server at http://localhost:3000.
All CSS files are read directly from the source from `src/bundles/skin-full.scss`

## Scripts

The following scripts are available via npm:

- `npm start` - Runs a build and starts local BrowserSync server on port 3000
- `npm start` - Builds the server and launches it at post 3000 (This does not have live reloading)
- `npm run dev` - Starts local BrowserSync server on port 3000 (This has live reloading)
- `npm test` - Runs a build and lints CSS and LESS files
- `npm run build` - Runs a build only (no server)

Expand Down Expand Up @@ -487,7 +470,6 @@ Git tags to the rescue! Git tags allow us to go back to any moment in time that
The website archive under `/docs/archive` should be updated each time a minor or major release is published.

1. In a local branch, checkout the tag of the previous version, e.g. `git checkout v10.7.5`
1. Run `yarn`
1. Run `yarn build`
1. Copy relevant generated files only from `/_site` to a subfolder of `/docs/archive`
1. Run `npm i`
1. Run `npx marko-run build -o /docs/archive/v0.7.5`
1. Create a pull request
4 changes: 0 additions & 4 deletions Gemfile

This file was deleted.

314 changes: 0 additions & 314 deletions Gemfile.lock

This file was deleted.

Loading

0 comments on commit f030e4f

Please sign in to comment.