Skip to content

Commit ab458cb

Browse files
committed
Cleanup
1 parent a6f34fe commit ab458cb

File tree

6 files changed

+18
-32
lines changed

6 files changed

+18
-32
lines changed

.gitignore

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ __pycache__/
33
.pytest_cache/
44
.*.swp
55
*.swo
6-
microhapulator.egg-info/
76
hg38.fasta
87
hg38.fasta.fai
98
.coverage.*
@@ -18,7 +17,5 @@ microhapulator/data/hg38.fasta.gz*
1817
.snakemake/
1918
.vscode/
2019
microhapulator/data/hg38.mmi
21-
22-
# pixi environments
2320
.pixi
2421
*.egg-info

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ This project adheres to [Semantic Versioning](http://semver.org/).
1212
- Updated working directory organization to provide additional structure (#194).
1313
- Snakemake is now invoked using its new Python API, requiring a minimum version of 8.0 and Python 3.11+ (#195).
1414
- FASTQ intake is now handled by a dedicated package ezfastq, which was based on MicroHapulator code (#196).
15+
- Switched from conda to pixi for project and dependency management (#197).
1516

1617
### Fixed
1718
- Bug with handling marker vs. locus identifiers when running `mhpl8r seq` (#190).

docs/devel.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ The documentation for MicroHapulator's [command line interface](cli.md) and [Pyt
66

77
## Automated test suite
88

9-
- Invoke test suite with `make test`
9+
- Invoke test suite with `pixi run test`
1010
- Most tests reside in `microhapulator/tests/test_*.py`
1111
- Some tests (doctests) reside in docstrings in module implementations in `microhapulator/*.py`
1212

docs/install.md

Lines changed: 5 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -20,27 +20,15 @@ pytest --pyargs microhapulator
2020
```
2121

2222

23-
## Dependencies
24-
25-
MicroHapulator depends on several Python packages.
26-
These are listed in `setup.py` in the main source code distribution.
27-
If performing a non-standard installation with `pip`, these dependencies will automatically be installed from the Python Package Index (PyPI).
28-
29-
Preparing Illumina reads for analysis and interpretation with MicroHapulator also depends on several bioinformatics tools, including [FLASH](https://ccb.jhu.edu/software/FLASH/), [Minimap2](https://lh3.github.io/minimap2/minimap2.html) (or an alternative short read aligner), [SAMtools](http://www.htslib.org/), and [FastQC](https://www.bioinformatics.babraham.ac.uk/projects/fastqc/).
30-
These software tools are installed automatically when performing a standard installation with Conda.
31-
Otherwise, they must be installed manually.
32-
33-
3423
## Development quick start
3524

36-
If you're setting up an environment for developing MicroHapulator, you may want to skip the procedure outlined above and use the following instead.
25+
If you're setting up an environment for developing MicroHapulator, you probably want to skip the procedure outlined above and use the following instead, after [installing pixi](https://pixi.sh/latest/installation/).
3726

3827
```bash
39-
conda create --name microhapulator python=3.11 flash minimap2 samtools fastqc
40-
conda activate microhapulator
4128
git clone https://github.com/bioforensics/MicroHapulator.git
4229
cd MicroHapulator/
43-
pip install -e . # Install the package and its Python dependencies
44-
make devdeps # Install development packages
45-
make devhooks # Register pre-commit hooks for development
30+
pixi install
31+
pixi install -e test
32+
pixi task list
33+
pixi run hooks
4634
```

pixi.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -71,16 +71,16 @@ sphinx = "*"
7171
sphinx-argparse = "*"
7272

7373
[tool.pixi.feature.test.tasks]
74-
docs = "sphinx-build -b html docs/ docs/_build/"
75-
hooks = "echo 'set -eo pipefail\npixi run style\npixi run docs' > .git/hooks/pre-commit && chmod 755 .git/hooks/pre-commit"
76-
format_py = "black --line-length=99 microhapulator/*.py microhapulator/*/*.py microhapulator/*/*/*.py"
77-
format_smk = "snakefmt --line-length=99 microhapulator/workflows/*.smk"
78-
format = { depends-on = ["format_py", "format_smk"] }
79-
style_py = "black --line-length=99 --check microhapulator/*.py microhapulator/*/*.py microhapulator/*/*/*.py"
80-
style_smk = "snakefmt --line-length=99 --check microhapulator/workflows/*.smk"
81-
style = { depends-on = ["style_py", "style_smk"] }
82-
test = "pytest --cov=microhapulator --doctest-modules --pyargs microhapulator"
83-
test4 = "pytest --cov=microhapulator --doctest-modules --pyargs microhapulator -n 4"
74+
docs = { cmd = "sphinx-build -b html docs/ docs/_build/", description = "Build documentation" }
75+
hooks = { cmd = "echo 'set -eo pipefail\npixi run style\npixi run docs' > .git/hooks/pre-commit && chmod 755 .git/hooks/pre-commit", description = "Install development hooks"}
76+
_format_py = "black --line-length=99 microhapulator/*.py microhapulator/*/*.py microhapulator/*/*/*.py"
77+
_format_smk = "snakefmt --line-length=99 microhapulator/workflows/*.smk"
78+
format = { depends-on = ["_format_py", "_format_smk"], description = "Autoformat Python and Snakemake code" }
79+
_style_py = "black --line-length=99 --check microhapulator/*.py microhapulator/*/*.py microhapulator/*/*/*.py"
80+
_style_smk = "snakefmt --line-length=99 --check microhapulator/workflows/*.smk"
81+
style = { depends-on = ["_style_py", "_style_smk"], description = "Check Python and Snakemake code style" }
82+
test = { cmd = "pytest --cov=microhapulator --doctest-modules --pyargs microhapulator", description = "Run automated test suite" }
83+
test4 = { cmd = "pytest --cov=microhapulator --doctest-modules --pyargs microhapulator -n 4", description = "Run automated test suite with 4 parallel jobs" }
8484

8585
[tool.pixi.environments]
8686
test = ["test"]

0 commit comments

Comments
 (0)