Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move to mkdocs #66

Merged
merged 12 commits into from
Nov 1, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
38 changes: 0 additions & 38 deletions .github/workflows/gh-pages.yml

This file was deleted.

43 changes: 43 additions & 0 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@

name: main

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

jobs:
build:
runs-on: ubuntu-latest
concurrency:
group: ci-${{ github.ref }}
cancel-in-progress: true
defaults:
run:
shell: bash -l {0}
steps:
- uses: actions/checkout@v2

- uses: conda-incubator/setup-miniconda@v2
with:
miniconda-version: "latest"
mamba-version: "*"
environment-file: conda/dev.yaml
channels: conda-forge,nodefaults
activate-environment: osl-web
use-mamba: true
miniforge-variant: Mambaforge

- name: Build the book
run: |
makim pages.build
echo "opensciencelabs.org" > build/CNAME

# Push the book's HTML to github-pages
- name: GitHub Pages action
uses: peaceiris/[email protected]
if: ${{ github.event_name == 'push' }}
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./build
131 changes: 128 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,129 @@
themes/hugo-clarity/.vscode/
themes/hugo-clarity/.github/
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class

public
# C extensions
*.so

# Distribution / packaging
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
pip-wheel-metadata/
share/python-wheels/
*.egg-info/
.installed.cfg
*.egg
MANIFEST

# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.nox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*.cover
*.py,cover
.hypothesis/
.pytest_cache/

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py
db.sqlite3
db.sqlite3-journal

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
docs/_build/

# PyBuilder
target/

# Jupyter Notebook
.ipynb_checkpoints

# IPython
profile_default/
ipython_config.py

# pyenv
.python-version

# pipenv
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
# However, in case of collaboration, if having platform-specific dependencies or dependencies
# having no cross-platform support, pipenv may install dependencies that don't work, or not
# install all needed dependencies.
#Pipfile.lock

# PEP 582; used by e.g. github.com/David-OConnor/pyflow
__pypackages__/

# Celery stuff
celerybeat-schedule
celerybeat.pid

# SageMath parsed files
*.sage.py

# Environments
.env
.venv
env/
venv/
ENV/
env.bak/
venv.bak/

# Spyder project settings
.spyderproject
.spyproject

# Rope project settings
.ropeproject

# mkdocs documentation
/site

# mypy
.mypy_cache/
.dmypy.json
dmypy.json

# Pyre type checker
.pyre/
6 changes: 3 additions & 3 deletions .makim.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ groups:
pages:
targets:
build:
help: build the static page with hugo
run: hugo --minify
help: build the static page
run: mkdocs build --verbose --clean
preview:
help: preview the web page dynamically
run: hugo server
run: mkdocs serve --watch build --watch theme
29 changes: 29 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
BSD 3-Clause License

Copyright (c) 2022, thegraphnetwork
All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:

1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.

2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.

3. Neither the name of the copyright holder nor the names of its
contributors may be used to endorse or promote products derived from
this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
22 changes: 7 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,28 +1,20 @@
# osl-hugo.github.io
# opensciencelabs.github.io

A blog page for OpenScienceLabs with Hugo site generator.
A blog page for OpenScienceLabs with mkdocs site generator.

## To deploy locally

Install Hugo via [Homebrew](https://brew.sh/) or you can install it via another options [Install Hugo](https://gohugo.io/getting-started/installing/)
Clone the repository

```bash
brew install hugo
git clone [email protected]:opensciencelabs/opensciencelabs.github.io
cd opensciencelabs.github.io
```

Clone the repository

```bash
git clone [email protected]:osl-incubator/osl-hugo.github.io.git
mamba env create -f conda/dev.yaml
```

Run locally

```bash
cd osl-hugo.github.io
hugo server
makim pages.preview
```
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This command is not working I used to start the preview mkdocs serve

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

weird .. that is working here XD
I will take a look into that .. also it is not working something on CI

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@EverVino it seems it was installing python 3.12 and it was breaking the mkdocs command


## To check how it works see the template

[Hugo Clarity](https://github.com/chipzoller/hugo-clarity)
26 changes: 0 additions & 26 deletions archetypes/default.md

This file was deleted.

Loading
Loading