File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -21,38 +21,67 @@ import dapi
2121print (dapi.__version__ )
2222```
2323
24- ## Development version
24+ ## Update
25+
26+ ``` bash
27+ pip install --upgrade dapi
28+ ```
29+
30+ ## Development
31+
32+ ### Install the dev branch
33+
34+ To test unreleased features from the ` dev ` branch:
2535
2636``` bash
2737pip install git+https://github.com/DesignSafe-CI/dapi.git@dev
2838```
2939
30- Or in a notebook:
40+ Or in a DesignSafe Jupyter notebook:
3141
3242``` python
3343% pip uninstall dapi -- yes
3444% pip install git+ https:// github.com/ DesignSafe- CI / dapi.git@ dev -- quiet
3545```
3646
37- ## Local editable install
47+ Restart the kernel after installing.
48+
49+ ### Local editable install
50+
51+ For local development where changes take effect immediately:
3852
3953``` bash
4054git clone https://github.com/DesignSafe-CI/dapi.git
4155cd dapi
56+ git checkout dev
4257pip install -e .
4358```
4459
45- ### Set up pre -commit hook
60+ ### Pre -commit hook
4661
47- The repo includes a pre-commit hook that auto-formats with ` ruff format ` and blocks commits that fail ` ruff check ` :
62+ The repo includes a pre-commit hook that auto-formats code with ` ruff format ` and blocks commits that fail ` ruff check ` :
4863
4964``` bash
5065cp scripts/pre-commit .git/hooks/pre-commit
5166chmod +x .git/hooks/pre-commit
5267```
5368
54- ## Update
69+ ### Running tests
5570
5671``` bash
57- pip install --upgrade dapi
72+ pip install pytest
73+ pytest tests/ -v
74+ ```
75+
76+ ### Linting
77+
78+ ``` bash
79+ ruff format --check .
80+ ruff check .
81+ ```
82+
83+ To auto-fix lint errors:
84+
85+ ``` bash
86+ ruff check --fix .
5887```
You can’t perform that action at this time.
0 commit comments