Skip to content

Commit 2bb8873

Browse files
authored
[Chore] Couple of small chores (#49)
* use working dir instead of cd * urls * add docs build to contributing * upgrade gha step versions in lint * remoce extra empty line in unit test * use livehtml
1 parent 8247faf commit 2bb8873

File tree

6 files changed

+22
-6
lines changed

6 files changed

+22
-6
lines changed

.github/workflows/docs.yaml

+3-3
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,12 @@ jobs:
1111
runs-on: ubuntu-latest
1212
steps:
1313
- name: Setup Python
14-
uses: actions/setup-python@v3
14+
uses: actions/setup-python@v5
1515
with:
1616
python-version: "3.10"
1717
architecture: x64
1818
- name: Checkout
19-
uses: actions/checkout@v3
19+
uses: actions/checkout@v4
2020
- name: Install Dependencies
2121
run: |
2222
set -eux
@@ -27,10 +27,10 @@ jobs:
2727
2828
pip install -r docs/requirements.txt
2929
- name: Build Sphinx Docs
30+
working-directory: docs
3031
run: |
3132
set -eux
3233
33-
cd docs
3434
make html
3535
- name: Upload static files as artifact
3636
id: deployment

.github/workflows/lint.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,12 @@ jobs:
1111
runs-on: ubuntu-latest
1212
steps:
1313
- name: Setup Python
14-
uses: actions/setup-python@v3
14+
uses: actions/setup-python@v5
1515
with:
1616
python-version: "3.10"
1717
architecture: x64
1818
- name: Checkout
19-
uses: actions/checkout@v3
19+
uses: actions/checkout@v4
2020
- name: Install Dependencies
2121
run: |
2222
set -eux

.github/workflows/unittest.yaml

-1
Original file line numberDiff line numberDiff line change
@@ -40,4 +40,3 @@ jobs:
4040
4141
pytest -v
4242
cargo test -v
43-

CONTRIBUTING.md

+11
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,17 @@ To run the entire suite of tests:
8585
$ scripts/test.sh
8686
```
8787

88+
### Build Docs
89+
To build the docs run:
90+
```sh
91+
pip install -r docs/requirements.txt
92+
cd docs
93+
make livehtml
94+
```
95+
96+
The docs will be built in the `docs/build/html` directory and served at http://localhost:8000.
97+
The page will be automatically re-built as long as the process is kept running.
98+
8899
## Contributor License Agreement ("CLA")
89100

90101
In order to accept your pull request, we need you to submit a CLA. You only need to do this once to work on any of

docs/requirements.txt

+1
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,4 @@ papermill
66
ipykernel
77
ipython_genutils
88
jinja2==3.1.4
9+
sphinx-autobuild

pyproject.toml

+5
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,11 @@ dependencies = [
1515
"torch"
1616
]
1717

18+
[project.urls]
19+
Documentation = "https://pytorch-labs.github.io/torchft"
20+
Repository = "https://github.com/pytorch-labs/torchft"
21+
Issues = "https://github.com/pytorch-labs/torchft/issues"
22+
1823
[project.optional-dependencies]
1924
dev = [
2025
"pytest",

0 commit comments

Comments
 (0)