Skip to content

Commit

Permalink
fix: rename documentation folder, closes #27, closes #5
Browse files Browse the repository at this point in the history
the previous edit_docs folder is now documentation. The README in the folder is changed to describe the automatic build. Commands need to only be run when in local development. The documentation is automatically build with GitHub actions and deployed to the gh-pages branch.
  • Loading branch information
berntpopp committed Dec 20, 2023
1 parent 1d2fcfc commit 0f6d723
Show file tree
Hide file tree
Showing 28 changed files with 18 additions and 14 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/gh-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
runs-on: ubuntu-20.04
defaults:
run:
working-directory: ./edit_docs
working-directory: ./documentation
steps:
- uses: actions/checkout@v4
- uses: r-lib/actions/setup-r@v2
Expand Down Expand Up @@ -54,7 +54,7 @@ jobs:
- uses: actions/upload-artifact@v4
with:
name: build
path: ./edit_docs/build
path: ./documentation/build
if-no-files-found: error
checkout-and-deploy:
runs-on: ubuntu-20.04
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<p align="center">
<img src="edit_docs/static/img/logo/kidney-genetics_logo.png" alt="Kidney-Genetics logo" width="192" height="192">
<img src="documentation/static/img/logo/kidney-genetics_logo.png" alt="Kidney-Genetics logo" width="192" height="192">
</p>

# Kidney-Genetics - Designing a reproducible and curated database of kidney-related genes
Expand Down
5 changes: 4 additions & 1 deletion edit_docs/.gitignore → documentation/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,7 @@ _main.*
*.utf8.md
!ga.html
libs/
nul
nul

# the build directory of bookdown
build/
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
17 changes: 9 additions & 8 deletions edit_docs/README.md → documentation/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,13 @@

The repository subfolder for the Kidney-Genetics documentation.

To build the documentation execute following commands:
<mark style="background-color: red">The documentation is automatically built and deployed to [https://halbritter-lab.github.io/kidney-genetics/](https://halbritter-lab.github.io/kidney-genetics/) using GitHub Actions into the branch hg-pages.</mark>
The configuration for the GitHub Pages build is in the `.github/workflows` folder.

For local development only, the documentation can be built using the following commands:

```
To build the documentation locally execute following commands:
```
## load libraries
Expand All @@ -11,7 +17,7 @@ library(config)

project_topic <- "nephrology"
project_name <- "kidney-genetics"
script_path <- "/edit_docs/"
script_path <- "/documentation/"

## read configs
config_vars_proj <- config::get(file = Sys.getenv("CONFIG_FILE"),
Expand Down Expand Up @@ -44,9 +50,4 @@ Rendering HTML widgets for PDF requires webshot and phantomjs [FROM:](https://bo
```
install.packages("webshot")
webshot::install_phantomjs()
```

## TODO
- automatic loading and filtering of current result tables in all Rmd files
- change scripts to load the gzipped files
- make a script that runs the above commands to re-generate the pages website
```
2 changes: 1 addition & 1 deletion edit_docs/_bookdown.yml → documentation/_bookdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,5 @@ download:
- ["KidneyGenetics_documentation.epub", "EPUB"]
- ["KidneyGenetics_documentation.docx", "DOCX"]
view: https://github.com/halbritter-lab/kidney-genetics/tree/master/docs/%s
edit: https://github.com/halbritter-lab/kidney-genetics/tree/master/edit_docs/%s
edit: https://github.com/halbritter-lab/kidney-genetics/tree/master/documentation/%s
output_dir: "build"
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion edit_docs/index.Rmd → documentation/index.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ library(shinyLP) # needed to plot presentations
```{r, echo=FALSE, message=FALSE, warning=FALSE}
project_topic <- "nephrology"
project_name <- "kidney-genetics"
script_path <- "/edit_docs/"
script_path <- "/documentation/"
## read configs
config_vars_proj <- config::get(file = Sys.getenv("CONFIG_FILE"),
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 0f6d723

Please sign in to comment.