okdaithi / flux-website-v2

Voteflux.org website. Version 2

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Instructions

If a build fails you can check logs at: https://voteflux.org/build-logs/

Dependencies

Docker

If you have docker installed just run ./dev-docker.sh - that should get you developing straight away (well, minus the minutes required to build and install deps)

Manually

We presume your environment is OSX.

  • Install node, npm, ruby, yarn first
  • macOS: brew install ruby node npm yarn
  • Ubuntu: sudo apt install ruby nodejs (aside: does this include npm?)
  • Ubuntu: Note: you'll need to install yarn yourself
  • Fedora: redhat-rpm-config
  • Install dependencies: ./dev-install-deps.sh or if that doesn't work: gem install bundle then bundle install then yarn install

Note: Node v11 doesn't seem to work building for some deps

Development

  • To run a development copy for everything run ./dev-watch-all.sh or npm run flux
  • To simulate a build run npm run build

Spellcheck

To run the interactive spellchecker: npm run spellcheck. By default it runs in interactive mode with suggestions. Run npm run spellcheck -- -x to disable suggestions, which is much faster.

Deployment

  • Deployments automatically happen via the master branch.
  • All merges require a PR.

Hints and Tips

  • macOS: brew install ruby for ruby
  • gem install bundle for bundle
  • bundle install to install jekyll dependencies
  • bundle exec jekyll serve --watch to run a dev server for just jekyll stuff.
  • ./dev-docker.sh to run jekyll and webpack in a docker container
  • React is used for the sign-up form but not for anything else.
  • Some widgets are written in Elm

Kip's notes on contributing

MK note: if you need to use sudo to run ./dev-docker.sh you should add yourself to the docker group (or google what to do for your OS); typically you shouldn't need sudo for docker, or at least it's good not to run it like that on your dev machine.

CICD Notes

  • Changes to bundler/ruby (maybe node stuff too) might break the build process due to docker volumes. Removing the volumes on the docker host seems to fix.
  • If CICD stuff doesn't happen then things are broken, please contact @XertroV

About

Voteflux.org website. Version 2

License:MIT License


Languages

Language:HTML 63.2%Language:SCSS 17.1%Language:Elm 9.9%Language:JavaScript 7.8%Language:Ruby 0.6%Language:CSS 0.6%Language:Dockerfile 0.3%Language:Shell 0.3%Language:TypeScript 0.2%