Commit 4b9e8ca6 authored by Roberto Porcu's avatar Roberto Porcu
Browse files

Merge branch 'master' of https://github.com/AMReX-Codes/MFIX-Exa

parents f3470fcc 23e7a640
Loading
Loading
Loading
Loading
+47 −0
Original line number Diff line number Diff line
name: Build-and-Deploy

# Run this workflow every time a new commit pushed to your repository
on: push

jobs:
  # Set the job key. The key is displayed as the job name
  # when a job name is not provided
  publish:
    # Name the Job
    name: Build Sphinx manual HTML target
    # Set the type of machine to run on
    runs-on: ubuntu-latest

    steps:
      - name: Checkout
        uses: actions/checkout@v2

      - name: Install Doxygen
        run: sudo apt install doxygen

      - name: Install Sphinx
        run: pip install sphinx sphinx-rtd-theme sphinx-tabs

      - name: Checkout code
        uses: actions/checkout@v2

      - name: Build MFiX-Exa Documentation
        run: make -C docs
        env:
          DEFAULT_BRANCH: main
          GITLAB_TOKEN: ${{ secrets.GITLAB_TOKEN }}

      - name: Build MFiX-Exa PIC VVA Manual
        run: make -C docs/picvva
        env:
          DEFAULT_BRANCH: main
          GITLAB_TOKEN: ${{ secrets.GITLAB_TOKEN }}

      - name: Deploy to GitHub Pages
        if: success()
        uses: crazy-max/ghaction-github-pages@v2
        with:
          target_branch: gh-pages
          build_dir: docs/webroot
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.travis.yml

deleted100644 → 0
+0 −31
Original line number Diff line number Diff line
dist: xenial

language: generic

python:
  - 3.6

install:
  - python -m pip install --user sphinx sphinx-rtd-theme

script: bash ./build_and_deploy.sh

env:
  global:
  - COMMIT_AUTHOR_EMAIL: "jpblaschke@lbl.gov"

addons:
  apt:
    packages:
      - doxygen

deploy:
  provider: pages
  target-branch: gh-pages
  local-dir: docs/webroot
  skip-cleanup: true
  github-token: $GITHUB_TOKEN  # Set in travis-ci.org dashboard, marked secure
  keep-history: true
  verbose: true
  on:
    branch: master
+34 −9
Original line number Diff line number Diff line
# MFIX-Exa
This is the public face of the MFiX-Exa project.
This is the public face of the MFiX-Exa project, hosting the documentation,
gallery of results, etc. The website is: https://amrex-codes.github.io/MFIX-Exa/

The code for now lives at NETL; instructions for how to get access to the code
will be given below.
## Editing

This repo is designed to host the documentation, gallery of results, etc.
The documentation source is in `docs/source/` and the html source for the cover
page is in `docs/webroot/`.

## Editing
:warning: **Do not push any edits to the `gh-pages` branch** as these will be
overwritten. Instead, commit your changes to the `master` branch, and the
`gh-pages` branch will be updated automatically a few minutes later.

### Documentation

The documentation is built using
[sphinx](https://www.sphinx-doc.org/en/master/). The `docs/source/config.py`
file contains the settings for building this documentation. The documentation
can be built locally by:

1. Install sphinx:

```shell
> pip install sphinx sphinx_rtd_theme sphinx-tabs
```

2. Build the documentation:

```shell
> mkdir build
> sphinx-build -b html docs/source_docs/ build
```

The HTML pages will now be located in the `build` directory. Open the
`index.html` with your favorite browser:

Do not push any edits to the `gh-pages` branch as these will be overwritten.
Instead, commit your changes to the `master` branch, and the `gh-pages` branch
will be updated automatially a few minutes later. The documentation source is
in `docs/source/` and the html source for the cover page is in `docs/webroot/`.
```shell
> firefox build/index.html
```

### Doxygen

build_and_deploy.sh

deleted100755 → 0
+0 −20
Original line number Diff line number Diff line
#!/bin/bash -ex
set -e # Exit with nonzero exit code if anything fails

# Then we build and deploy the sphinx / doxygen documentation
SOURCE_BRANCH="master"
#TARGET_BRANCH="gh-pages"

# Pull requests and commits to other branches shouldn't try to deploy
if [ "$TRAVIS_PULL_REQUEST" != "false" -o "$TRAVIS_BRANCH" != "$SOURCE_BRANCH" ]; then
    echo "Skipping deploy."
    exit 0
fi

# Save some useful information
#REPO=`git config remote.origin.url`
#SSH_REPO=${REPO/https:\/\/github.com\//git@github.com:}
#SHA=`git rev-parse --verify HEAD`

# build Doxygen docs and Sphinx docs
make -C docs
+1 −1
Original line number Diff line number Diff line
# You can set these variables from the command line.
SPHINXOPTS    =
SPHINXBUILD   = python -msphinx
SOURCEDIR     = source
SOURCEDIR     = source_docs
BUILDDIR      = webroot

all: html webroot/doxygen
Loading