File tree Expand file tree Collapse file tree 2 files changed +65
-0
lines changed
Expand file tree Collapse file tree 2 files changed +65
-0
lines changed Original file line number Diff line number Diff line change 1+ name : build_documentation
2+
3+ # build the documentation whenever there are new commits on main
4+ on :
5+ push :
6+ branches :
7+ # - main
8+ - pdoc
9+ # TODO only build on releases once this works
10+ # Alternative: only build for tags.
11+ # tags:
12+ # - '*'
13+
14+ # security: restrict permissions for CI jobs.
15+ permissions :
16+ contents : read
17+
18+ jobs :
19+ # Build the documentation and upload the static HTML files as an artifact.
20+ build :
21+ runs-on : ubuntu-latest
22+ steps :
23+ - name : Checkout
24+ uses : actions/checkout@v2
25+
26+ - name : Setup miniconda
27+ uses : conda-incubator/setup-miniconda@v2
28+ with :
29+ activate-environment : sam
30+ mamba-version : " *"
31+ auto-update-conda : true
32+ environment-file : environment_cpu.yaml
33+ python-version : ${{ matrix.python-version }}
34+ auto-activate-base : false
35+ env :
36+ ACTIONS_ALLOW_UNSECURE_COMMANDS : true
37+
38+ - name : Install package
39+ shell : bash -l {0}
40+ run : pip install --no-deps -e .
41+
42+ # We use a custom build script for pdoc itself, ideally you just run `pdoc -o docs/ ...` here.
43+ - name : Run pdoc
44+ shell : bash -l {0}
45+ run : pdoc --docformat google --logo "https://raw.githubusercontent.com/computational-cell-analytics/micro-sam/master/doc/images/micro-sam-logo.png" -o docs/ micro_sam
46+
47+ - uses : actions/upload-pages-artifact@v1
48+ with :
49+ path : docs/
50+
51+ # Deploy the artifact to GitHub pages.
52+ # This is a separate job so that only actions/deploy-pages has the necessary permissions.
53+ deploy :
54+ needs : build
55+ runs-on : ubuntu-latest
56+ permissions :
57+ pages : write
58+ id-token : write
59+ environment :
60+ name : github-pages
61+ url : ${{ steps.deployment.outputs.page_url }}
62+ steps :
63+ - id : deployment
64+ uses : actions/deploy-pages@v2
Original file line number Diff line number Diff line change 66dependencies :
77 - cpuonly
88 - napari
9+ - pdoc
910 - pooch
1011 - python-elf
1112 - pytorch
You can’t perform that action at this time.
0 commit comments