Skip to content

Commit

Permalink
Merge pull request #248 from simphony/dev
Browse files Browse the repository at this point in the history
Merge release 3.9.0
  • Loading branch information
kysrpex authored Dec 7, 2022
2 parents 7de48b7 + 6883e2f commit 5e814c1
Show file tree
Hide file tree
Showing 39 changed files with 2,629 additions and 2,281 deletions.
2 changes: 1 addition & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
.vscode/
build/
build/
11 changes: 0 additions & 11 deletions .github/issue-branch.yml

This file was deleted.

35 changes: 17 additions & 18 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,23 @@ on: pull_request

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Set up Python 3.7
uses: actions/setup-python@v2
with:
python-version: 3.7
- name: Install OS dependencies
run: |
sudo apt-get update
sudo apt-get install pandoc latexmk
sudo apt-get install texlive-fonts-recommended texlive-latex-recommended texlive-latex-extra
- name: Install python dependencies
run: |
python -m pip install --upgrade pip
pip install wheel
pip install -r requirements.txt
- name: Build docs
run: sphinx-build docs/source docs/build/html
- uses: actions/checkout@v3
- name: Set up Python 3.10
uses: actions/setup-python@v3
with:
python-version: "3.10"
- name: Install OS dependencies
run: |
sudo apt-get update
sudo apt-get install pandoc latexmk
sudo apt-get install texlive-fonts-recommended texlive-latex-recommended texlive-latex-extra
- name: Install python dependencies
run: |
python -m pip install --upgrade pip
pip install wheel
pip install -r requirements.txt
- name: Build docs
run: sphinx-build docs/source docs/build/html
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
.vscode/
build/
build/
36 changes: 36 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
---
ci:
autoupdate_branch: "dev"

repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.2.0
hooks:
- id: check-json
- id: pretty-format-json
args: ["--autofix", "--no-sort-keys"]
- id: check-yaml
- id: end-of-file-fixer
- id: trailing-whitespace

- repo: https://github.com/pre-commit/mirrors-prettier
rev: v2.6.2
hooks:
- id: prettier
files: \.(js|ts|jsx|tsx|css|less|html|markdown|md|yaml|yml)$

- repo: https://github.com/psf/black
rev: 22.6.0
hooks:
- id: black
args:
- --line-length=79

- repo: https://github.com/pycqa/isort
rev: 5.10.1
hooks:
- id: isort
args:
- --profile=black
- --filter-files
- --line-length=79
23 changes: 19 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,52 +1,67 @@
## Build Status
**latest** - [![Documentation latest](https://readthedocs.org/projects/simphony/badge/?version=latest)](https://simphony.readthedocs.io/en/latest/?badge=latest)

**latest** - [![Documentation latest](https://readthedocs.org/projects/simphony/badge/?version=latest)](https://simphony.readthedocs.io/en/latest/?badge=latest)
**dev** - [![Documentation dev](https://readthedocs.org/projects/simphony/badge/?version=dev)](https://simphony.readthedocs.io/en/latest/?badge=dev)

# SimPhoNy docs

To access the documentation, please visit: [https://simphony.readthedocs.io](https://simphony.readthedocs.io).

If you find any error or problem with the documentation, please [create an issue](https://github.com/simphony/docs/issues).

## Local Rendering

### HTML

A server will start, generate the docs and listen for changes in the source files.
This can be done by using docker or installing the development environment directly on the you machine. Next are installation guides for Docker and Linux OS.

#### Docker

First, build the Docker image by running the following command:

```shell
$ docker build -f local_build.Dockerfile -t simphony-docs .
```

Then, start the program by running:

```shell
$ docker run --rm -v $PWD:/app -p 8000:8000 simphony-docs
```

#### Linux

At an OS level (these commands work on Linux Debian):

```shell
$ sudo apt install pandoc graphviz default-jre
$ sudo apt-get install texlive-latex-recommended \
texlive-latex-extra \
texlive-fonts-recommended \
latexmk
latexmk
```

The python dependencies:

```shell
$ pip install -r requirements.txt
```

Now you can start the server and render the docs:

```
$ sphinx-autobuild docs/source docs/build/html
```
The documentation will be available on [`http://127.0.0.1:8000`](http://127.0.0.1:8000).

The documentation will be available on [`http://127.0.0.1:8000`](http://127.0.0.1:8000).

### PDF (LaTeX)

To generate a PDF of the documentation, simply run (from the root project folder):

```sh
make -C docs latexpdf
```
The generated PDF can be found under docs/build/latex/SymPhoNy_docs.pdf

The generated PDF can be found under docs/build/latex/SymPhoNy_docs.pdf
25 changes: 25 additions & 0 deletions docs/source/_static/custom.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
.caption-text,
h1,
h2,
h3,
h4 {
color: #6580a1 !important;
}

.btn-outline-primary {
border-color: #6580a1 !important;
}

.btn-outline-primary:hover {
background-color: #6580a1 !important;
color: azure !important;
}

@media (min-width: 1200px) {
.container-xl {
max-width: 1550px;
}
#site-navigation {
max-width: 20%;
}
}
2 changes: 1 addition & 1 deletion docs/source/_static/img/branch_workflow.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion docs/source/_static/img/mergedlinkeddata.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 5e814c1

Please sign in to comment.