This repository has been archived by the owner on Mar 7, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Added community files. * Minor README change * License in pre block * Updated classifiers. * Added black formatting step (#12) * Renamed fastx_barber for consistency and switched to poetry. * Minor edit. * Switching from pip to poetry in github actions * Added missing step arguments. * Added pip steps and split flake8 install and run * Switched to different poetry action. * Merged pip upgrade and flake8 install steps.
- Loading branch information
Showing
22 changed files
with
166 additions
and
99 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,10 +7,6 @@ on: | |
pull_request: | ||
branches: | ||
- master | ||
- dev | ||
release: | ||
types: | ||
- created | ||
|
||
jobs: | ||
build: | ||
|
@@ -22,8 +18,7 @@ jobs: | |
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v1 | ||
- uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Cache pip | ||
|
@@ -35,18 +30,22 @@ jobs: | |
restore-keys: | | ||
${{ runner.os }}-pip- | ||
${{ runner.os }}- | ||
- name: Install dependencies | ||
- name: Upgrade pip and install flake8 | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install -r requirements.txt | ||
pip install flake8 | ||
- uses: dschep/[email protected] | ||
- name: Install package with poetry | ||
run: poetry install | ||
- uses: lgeiger/[email protected] | ||
with: | ||
args: ". --check" | ||
- name: Lint with flake8 | ||
run: | | ||
pip install flake8 | ||
# stop the build if there are Python syntax errors or undefined names | ||
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics | ||
# exit-zero treats all errors as warnings | ||
flake8 . --count --exit-zero --max-complexity=5 --max-line-length=88 --ignore=E203 --statistics | ||
- name: Check with Mypy | ||
uses: jpetrucciani/[email protected] | ||
- uses: jpetrucciani/[email protected] | ||
with: | ||
path: '.' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
# fastx-barber Code of Conduct | ||
|
||
## Our Pledge | ||
|
||
In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, religion, or sexual identity and orientation. | ||
|
||
## Our Standards | ||
|
||
Examples of behavior that contributes to creating a positive environment include: | ||
|
||
* Using welcoming and inclusive language | ||
* Being respectful of differing viewpoints and experiences | ||
* Gracefully accepting constructive criticism | ||
* Focusing on what is best for the community | ||
* Showing empathy towards other community members | ||
|
||
Examples of unacceptable behavior by participants include: | ||
|
||
* The use of sexualized language or imagery and unwelcome sexual attention or advances | ||
* Trolling, insulting/derogatory comments, and personal or political attacks | ||
* Public or private harassment | ||
* Publishing others' private information, such as a physical or electronic address, without explicit permission | ||
* Other conduct which could reasonably be considered inappropriate in a professional setting | ||
|
||
## Our Responsibilities | ||
|
||
Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior brought to their. | ||
|
||
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful. | ||
|
||
## Scope | ||
|
||
This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers. | ||
|
||
## Enforcement | ||
|
||
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at [email protected]. All complaints will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately. | ||
|
||
Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership. | ||
|
||
## Attribution | ||
|
||
This Code of Conduct is adapted from the [Contributor Covenant][contributor_covenant_homepage], version 1.4, available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html | ||
|
||
[contributor_covenant_homepage]: https://www.contributor-covenant.org |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# Introduction | ||
|
||
Hi there, and thank you for considering contributing to `fastx-barber` to help us make our code a better version of itself! | ||
|
||
`fastx-barber` is an open source project, and as such any kind of contribution is welcome! There are many ways in which you can contribute: improve the code or the documentation, submit bug reports, request new features or write tutorials or blog posts. | ||
|
||
# Ground Rules | ||
|
||
To see what kinds of behavior are acceptable when contributing to `fastx-barber`, please refer to our [code of conduct](https://github.com/ggirelli/fastx-barber/blob/master/CODE_OF_CONDUCT.md). | ||
|
||
# Getting started | ||
|
||
We host `fastx-barber` on GitHub, where we also track issues and feature requests, as well as handle pull requests. | ||
|
||
Please, note that any contributions you make will be under the MIT Software License. In other words, all your submissions are understood to be under the same [MIT License](http://choosealicense.com/licenses/mit/) that covers the `fastx-barber` project. Feel free to contact us if that's a concern. | ||
|
||
## How to submit a contribution | ||
|
||
To process code change, we follow the [Github Flow](https://guides.github.com/introduction/flow/index.html). All code changes to our `master` branch happen through pull requests from the `dev` branch. We actively welcome your pull requests to the `dev` branch! | ||
|
||
## How to report a bug | ||
|
||
If you want to report a **bug**, please use the github [issue tracker](https://github.com/ggirelli/fastx-barber/issues) and follow the issue template that should automatically show up. | ||
|
||
## How to suggest a feature or enhancement | ||
|
||
If you would like to see a new feature implemented in `fastx-barber`, or to have an already existing feature improved, please use the github [issue tracker](https://github.com/ggirelli/fastx-barber/issues) and follow the template that should automatically show up. | ||
|
||
# Style your contributions | ||
|
||
We like to have `fastx-barber` code styled with [`black`](https://github.com/psf/black) and checked with `mypy`. `mypy` and `flake8` conforming checks are automatically ran on all pull requests through GitHub Actions. |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,21 @@ | ||
# fastx-barber | ||
|
||
Python package for trimming and sequence extraction from FASTA and FASTQ files. | ||
Python package to trim and extract flags from FASTA and FASTQ files. | ||
|
||
## Requirements | ||
|
||
`fastx-barber` has been tested with Python 3.6, 3.7, and 3.8. We recommend installing it using `pipx` (see [below](#install)) to avoid dependency conflicts with other packages. The packages it depends on are listed in our [dependency graph](https://github.com/ggirelli/fastx-barber/network/dependencies). We use [`poetry`](https://github.com/python-poetry/poetry) to handle our dependencies. | ||
|
||
## Install | ||
|
||
We recommend installing `fastx-barber` using [`pipx`](https://github.com/pipxproject/pipx). Check how to install `pipx` [here](https://github.com/pipxproject/pipx#install-pipx) if you don't have it yet! | ||
|
||
Once you have `pipx` ready on your system, install the latest stable release of `fastx-barber` by running: `pipx install fastx-barber`. If you see the stars (✨ 🌟 ✨), then the installation went well! | ||
|
||
# Contribute | ||
## Contributing | ||
|
||
We welcome any contributions to `fastx-barber`. In short, we use [`black`](https://github.com/psf/black) to standardize code format. Any code change also needs to pass `mypy` checks. For more details, please refer to our [contribution guidelines](CONTRIBUTING.md) if this is your first time contributing! Also, check out our [code of conduct](CODE_OF_CONDUCT.md). | ||
|
||
## License | ||
|
||
We use [`black`](https://github.com/psf/black) to standardize code format. Any code change also needs to pass `mypy` checks. | ||
`MIT License - Copyright (c) 2020 Gabriele Girelli` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
""" | ||
@author: Gabriele Girelli | ||
@contact: [email protected] | ||
""" | ||
|
||
from fastx_barber.const import __version__ | ||
from fastx_barber import const, scripts | ||
from fastx_barber import io, seqio | ||
from fastx_barber import extract, match, trim | ||
|
||
__all__ = ["__version__", "const", "scripts", "io", "seqio", "extract", "match", "trim"] |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,7 @@ | |
@contact: [email protected] | ||
""" | ||
|
||
from fbarber.scripts import common | ||
from fbarber.scripts import extract, match, trim | ||
from fastx_barber.scripts import common | ||
from fastx_barber.scripts import extract, match, trim | ||
|
||
__all__ = ["common", "extract", "match", "trim"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
[tool.poetry] | ||
name = "fastx-barber" | ||
version = "0.0.1" | ||
description = "FASTX trimming tools" | ||
authors = ["Gabriele Girelli <[email protected]>"] | ||
license = "MIT" | ||
readme = "README.md" | ||
homepage = "https://github.com/ggirelli/fastx-barber" | ||
repository = "https://github.com/ggirelli/fastx-barber" | ||
keywords = ["fasta", "fastq", "trimming", "bioinformatics"] | ||
classifiers = [ | ||
"Development Status :: 4 - Beta", | ||
"Environment :: Console", | ||
"Intended Audience :: Science/Research", | ||
"Topic :: Scientific/Engineering :: Bio-Informatics", | ||
"Operating System :: Unix", | ||
"Operating System :: POSIX :: Linux", | ||
] | ||
include = ["CHANGELOG.md", "LICENSE"] | ||
|
||
[tool.poetry.dependencies] | ||
python = "^3.6" | ||
biopython = "^1.77" | ||
regex = "^2020.7.14" | ||
tqdm = "^4.48.0" | ||
|
||
[build-system] | ||
requires = ["poetry>=0.12"] | ||
build-backend = "poetry.masonry.api" | ||
|
||
[tool.poetry.scripts] | ||
"fbarber" = "fastx_barber.scripts.barber:main" |
This file was deleted.
Oops, something went wrong.