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

Make CI more "poetic" #5

Merged
merged 3 commits into from
Jul 19, 2024
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
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,4 @@ trim_trailing_whitespace = false
[*.{yaml,yml}]
indent_style = space
indent_size = 2
trim_trailing_whitespace = true
26 changes: 26 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Build
on:
pull_request:
paths-ignore:
- 'README.md'
workflow_dispatch:

permissions: {}

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Python
id: py
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install poetry
run: pipx install --python '${{ steps.py.outputs.python-path }}' poetry
- name: Install dependencies
run: poetry install --no-interaction
- name: Build website
run: poetry run mkdocs --color build --strict
24 changes: 0 additions & 24 deletions .github/workflows/ci.yml

This file was deleted.

29 changes: 29 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Deploy
on:
push:
branches:
- master
paths-ignore:
- 'README.md'
workflow_dispatch:

permissions:
contents: write

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Python
id: py
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install poetry
run: pipx install --python '${{ steps.py.outputs.python-path }}' poetry
- name: Install dependencies
run: poetry install --no-interaction
- name: Deploy website
run: poetry run mkdocs --color gh-deploy --ignore-version --no-history
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# NDN 101

A introductory website for NDN.
An introductory website on Named Data Networking (NDN).

Link: [101.named-data.net](https://101.named-data.net/)

Expand All @@ -9,7 +9,8 @@ Link: [101.named-data.net](https://101.named-data.net/)
Install dependencies:

```shell
poetry install --no-root
pipx install poetry
poetry install
```

Live preview:
Expand Down
7 changes: 2 additions & 5 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
[tool.poetry]
name = "ndn101-md"
version = "0.1.0"
description = ""
authors = ["Varun Patil <[email protected]>"]
readme = "README.md"
package-mode = false
name = "ndn-101"

[tool.poetry.dependencies]
python = "^3.11"
Expand Down