Skip to content

Commit 07f2b31

Browse files
committed
Merge branch 'develop'
* develop: feat: add documentation website (#37) improv: move away from monorepo due to change in direction (#36) fix: #35 duplicate changelog to project root
2 parents b9f2bc1 + e51dd10 commit 07f2b31

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

80 files changed

+22043
-988
lines changed

Diff for: python/.flake8 renamed to .flake8

File renamed without changes.

Diff for: .github/workflows/python.yml

+1-8
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,18 @@
1-
name: Powertools Python
1+
name: Build
22

33
on:
44
pull_request:
55
branches:
66
- develop
77
- master
8-
paths:
9-
- "python/**"
108
push:
119
branches:
1210
- develop
1311
- master
14-
paths:
15-
- "python/**"
1612

1713
jobs:
1814
build:
1915
runs-on: ubuntu-latest
20-
defaults:
21-
run:
22-
working-directory: ./python/
2316
strategy:
2417
max-parallel: 4
2518
matrix:

Diff for: .github/workflows/python_docs.yml

+5-14
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,26 @@
1-
name: Powertools Python Docs
1+
name: Docs
22

33
on:
44
pull_request:
55
branches:
66
- master
7-
paths:
8-
- "python/**"
97
push:
108
branches:
119
- master
12-
paths:
13-
- "python/**"
1410

1511
jobs:
1612
docs:
1713
runs-on: ubuntu-latest
18-
defaults:
19-
run:
20-
working-directory: ./python/
2114
steps:
2215
- uses: actions/checkout@v1
2316
- name: Set up Python
2417
uses: actions/setup-python@v1
2518
with:
2619
python-version: "3.8"
27-
- name: Install dependencies
28-
run: make dev
29-
- name: build docs
30-
run: make docs
31-
- name: deploy docs
20+
- name: Build docs website
21+
run: make build-docs
22+
- name: Deploy docs
3223
uses: peaceiris/actions-gh-pages@v3
3324
with:
3425
github_token: ${{ secrets.GITHUB_TOKEN }}
35-
publish_dir: python/docs/aws_lambda_powertools/
26+
publish_dir: ./dist

Diff for: .gitignore

+9-2
Original file line numberDiff line numberDiff line change
@@ -291,5 +291,12 @@ $RECYCLE.BIN/
291291
# End of https://www.gitignore.io/api/osx,linux,python,windows,pycharm,visualstudiocode
292292

293293
# Misc
294-
test_report
295-
/.idea/*
294+
test_report
295+
wheelhouse
296+
/.idea/*
297+
*.html
298+
299+
# Docs files
300+
docs/.cache/
301+
docs/public
302+
node_modules

Diff for: python/CHANGELOG.md renamed to CHANGELOG.md

File renamed without changes.

Diff for: python/MANIFEST.in renamed to MANIFEST.in

File renamed without changes.

Diff for: python/Makefile renamed to Makefile

+19-2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@ dev:
66
pip install --upgrade pip poetry
77
poetry install
88

9+
dev-docs:
10+
cd docs && npm install
11+
912
format:
1013
poetry run isort -rc .
1114
poetry run black aws_lambda_powertools
@@ -25,10 +28,24 @@ pr: lint test security-baseline complexity-baseline
2528
build: pr
2629
poetry run build
2730

28-
docs: dev
29-
poetry run pdoc --html --output-dir docs ./aws_lambda_powertools --force
31+
build-docs:
32+
mkdir -p dist/api
33+
@$(MAKE) build-docs-website
34+
@$(MAKE) build-docs-api
35+
36+
build-docs-api: dev
37+
poetry run pdoc --html --output-dir dist/api/ ./aws_lambda_powertools --force
38+
mv dist/api/aws_lambda_powertools/* dist/api/
39+
rm -rf dist/api/aws_lambda_powertools
40+
41+
build-docs-website: dev-docs
42+
cd docs && npm run build
43+
cp -R docs/public/* dist/
3044

3145
docs-dev:
46+
cd docs && npm run start
47+
48+
docs-api-dev:
3249
poetry run pdoc --http : aws_lambda_powertools
3350

3451
security-baseline:

0 commit comments

Comments
 (0)