Skip to content

Commit

Permalink
Merge pull request #499 from killbill/new-branding
Browse files Browse the repository at this point in the history
New branding
  • Loading branch information
pierre authored Aug 28, 2023
2 parents 52bdafa + 8947b90 commit bebc743
Show file tree
Hide file tree
Showing 140 changed files with 3,872 additions and 3,908 deletions.
19 changes: 19 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: CI

on:
push:
workflow_dispatch:

jobs:
ci:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.2.2
bundler-cache: true
- name: Build pages
run: |
bash make.sh
28 changes: 6 additions & 22 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,37 +6,21 @@ on:
- v3
workflow_dispatch:

env:
DEBIAN_FRONTEND: noninteractive

jobs:
publish:
runs-on: ubuntu-20.04
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install packages
run: |
sudo apt update -qy
sudo apt-get install -y curl
- name: Set up RVM
run: |
curl -sSL https://get.rvm.io | bash
- uses: actions/checkout@v3
- name: Set up Ruby
run: |
source $HOME/.rvm/scripts/rvm
rvm install 2.7.2 --binary
rvm --default use 2.7.2
- name: Install Ruby dependencies
run: |
source $HOME/.rvm/scripts/rvm
bundle install
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.2.2
bundler-cache: true
- name: Build pages
run: |
source $HOME/.rvm/scripts/rvm
bash make.sh
- name: Publish pages
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
run: |
source $HOME/.rvm/scripts/rvm
bash update_gh-pages.sh
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,11 @@ Gemfile.lock
.env
/.asciidoctorconfig.adoc
/.project
node_modules
.bundle
latest
.ruby-version
package.json
package-lock.json
page.sh
vendor
10 changes: 5 additions & 5 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
source 'https://rubygems.org'

gem 'asciidoctor', '~> 2.0.0'
gem 'concurrent-ruby', '~> 1.1.0'
gem 'pygments.rb', '~> 2.0.0'
gem 'slim', '~> 4.0.0'
gem 'tilt', '~> 2.0.0'
gem 'asciidoctor', '~> 2.0'
gem 'concurrent-ruby', '~> 1.2'
gem 'pygments.rb', '~> 2.0'
gem 'slim', '~> 5.0'
gem 'tilt', '~> 2.0'
47 changes: 38 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,47 @@
killbill-docs
=============
# Docs

Kill Bill documentation (user guides and tutorials).

To generate the documentation locally, run ```make.sh```. Generated html files are in the *build* directory (only selfcontained HTML files are generated today).
The site is built using [Asciidoctor](http://asciidoctor.org/docs/).

Pages are automatically built and pushed to https://docs.killbill.io/ by GitHub Actions.
## Edit and Syntax

Setup
-----
The documentation is in the `userguide` directory.

AsciiDoc syntax: https://docs.asciidoctor.org/asciidoc/latest/syntax-quick-reference/

## Development

To generate the documentation locally:

```
make.sh
```

Generated html files are in the `build` directory.

To run the site locally:

```
ruby server.rb
```

Prerequisites:

* Make sure to work off branch `v3`
* Install Ruby (use [RVM](https://rvm.io/) or [RubyInstaller](https://rubyinstaller.org/))
* Run `bundle install`
* Verify documentation can be built by running the `make.sh` script

Documentation on AsciiDoc can be found [here](http://asciidoctor.org/docs/). A quick reference is available [here](http://asciidoctor.org/docs/asciidoc-syntax-quick-reference/).
## Deployment

To deploy the docs:

```
make.sh
update_gh-pages.sh
```

Notes:

* The generated static pages under `build/selfcontained` are pushed to the `gh-pages` branch (not served by GitHub pages)
* The `gh-pages` branch is then deployed by Cloudflare (https://docs.killbill.io/)
* Minification of assets is handled by Cloudflare (check-in the unminified version)
17 changes: 17 additions & 0 deletions cloudflare_deploy.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/usr/bin/env bash

# Check if Gemfile exists (no need to build on gh-pages)
if [ -f Gemfile ]
then
./make.sh
cp -fr build/selfcontained/* build/
mv build/selfcontained build/latest
else
rm -f .gitignore latest.txt *.sh

ALL_BUILT_FILES_TMP_DIR=`mktemp -d "${TMPDIR:-/tmp}"/foo.XXXX`
mv * $ALL_BUILT_FILES_TMP_DIR/

mkdir -p build/latest
mv $ALL_BUILT_FILES_TMP_DIR/* build/latest/
fi
20 changes: 0 additions & 20 deletions faqs.adoc

This file was deleted.

10 changes: 0 additions & 10 deletions html5/_attribution.html.slim

This file was deleted.

8 changes: 0 additions & 8 deletions html5/_footer.html.slim

This file was deleted.

6 changes: 0 additions & 6 deletions html5/_footnotes.html.slim

This file was deleted.

20 changes: 0 additions & 20 deletions html5/_hdlist.html.slim

This file was deleted.

29 changes: 0 additions & 29 deletions html5/_header.html.slim

This file was deleted.

Loading

0 comments on commit bebc743

Please sign in to comment.