danger.systems

danger.systems

The website generator for danger.systems, which is staticly generated on gh-pages

Name Last Update
.vscode Loading commit data...
docs Loading commit data...
scripts Loading commit data...
static Loading commit data...
webhooks Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
.gitlab-ci.yml Loading commit data...
.travis.yml Loading commit data...
Dangerfile Loading commit data...
Gemfile Loading commit data...
Gemfile.lock Loading commit data...
LICENSE Loading commit data...
Makefile Loading commit data...
Procfile Loading commit data...
README.md Loading commit data...
Rakefile Loading commit data...
circle.yml Loading commit data...
example_oss_dangerfiles.json Loading commit data...
package.json Loading commit data...
plugins-search-generated.json Loading commit data...
plugins.json Loading commit data...
yarn.lock Loading commit data...

danger.systems

The website generator for danger.systems, which is staticly generated to GitLab Pages.

Key Components

danger.systems

danger-systems-webhook.herokuapp.com

And some metadata

plugins.json

example_oss_.json

To install, you need a working copy of Ruby and Node with yarn installed

git clone https://gitlab.com/danger-systems/danger.systems.git
cd danger.systems
bundle
yarn install
rake generate

danger.systems

The static generator for the site.

It is a similar concept to CocoaPods.org, in that there is a collection of generated data that come from Rake tasks. This data is then used to generate the web page.

The website's data is generate from rake generate which pulls out plugins, then grabs the gems and generates the documentation.

You can run a copy of the static site via:

bundle install
bundle exec rake generate
# You may need to re-run `bundle install` here
bundle exec rake serve

danger-systems-webhook.herokuapp.com

This is a web service, whose job is to listen out for webhook notificatiosn for new tags on any danger-plugin. It will trigger a call to generate the new version of danger.systems, and deploy that on gh-pages. It does this by triggering new builds on this repo from Travis CI.

You can add http://danger-systems-webhook.herokuapp.com/gem/update as webhook for new tags, in order to have Danger always be up-to-date in documentation on the website.

You can find the webhooks settings page at: https://github.com/[your name]/[your repo]/settings/hooks/new

Webhook Preview

You can run a copy of the webhook site via:

bundle
bundle exec foreman start

Deployment

  • The static site is deployed using GitLab CI and GitLab Pages
  • The webhooks site is deployed via Heroku, it is set to automatically re-deploy when a new commit is sent to master.

plugins.json

The master list of all plugins to show in Danger.Systems, right now it is just the name of your plugin on RubyGems.

If you'd like to add a new plugin (awesome) this is where you want to put it.

We'll be checking for whether you get useful metadata when you run danger plugins lint [gem_name] for your plugin, so please take the time to add all the extra metadata. You can see a reference plugin here (and a class). This is considered the central source of truth with respect to public plugins for Danger.

example_oss_.json

It's hard to cover all the use cases of Danger, so rather than trying to do that, we're instead going to pull the Dangerfiles from different repos and show them in the Dangerfile guide. We'd love more examples, the only thing we ask is that you aim to keep it very well commented ( ideally, over commented, non-rubyists will be reading it.)