Skip to content

Commit f97ba66

Browse files
committed
Rename master branch to main and add GitHub CI
1 parent c3e5fd4 commit f97ba66

File tree

12 files changed

+268
-9
lines changed

12 files changed

+268
-9
lines changed
Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
name: 🐞 Bug Report
2+
description: File a bug/issue
3+
title: "[BUG] <title>"
4+
labels: [bug, triage]
5+
assignees: ghiggi
6+
body:
7+
- type: checkboxes
8+
attributes:
9+
label: Is there an existing issue for this?
10+
description: Please search to see if an issue already exists for the bug you encountered.
11+
options:
12+
- label: I have searched the existing issues
13+
required: true
14+
- type: textarea
15+
attributes:
16+
label: Current Behavior
17+
description: A concise description of what you're experiencing.
18+
validations:
19+
required: false
20+
- type: textarea
21+
attributes:
22+
label: Expected Behavior
23+
description: A concise description of what you expected to happen.
24+
validations:
25+
required: false
26+
- type: textarea
27+
attributes:
28+
label: Steps To Reproduce
29+
description: Steps to reproduce the behavior.
30+
placeholder: |
31+
1. In this environment...
32+
2. With this config...
33+
3. Run '...'
34+
4. See error...
35+
validations:
36+
required: false
37+
- type: textarea
38+
attributes:
39+
label: Environment
40+
description: |
41+
examples:
42+
- **OS**: Ubuntu 20.04
43+
- **Python**: 3.8.2
44+
value: |
45+
- OS:
46+
- python:
47+
render: markdown
48+
validations:
49+
required: false
50+
- type: textarea
51+
attributes:
52+
label: Anything else?
53+
description: |
54+
Links? References? Anything that will give us more context about the issue you are encountering!
55+
56+
Tip: You can attach images or log files by clicking this area to highlight it and then dragging files in.
57+
validations:
58+
required: false

.github/ISSUE_TEMPLATE/config.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
blank_issues_enabled: false
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
---
2+
name: ➕ Feature request
3+
about: Suggest an idea for this project
4+
title: ''
5+
description: What is your feature request ?
6+
title: "[FEATURE] <title>"
7+
labels: [enhancement, triage]
8+
assignees: ghiggi
9+
10+
---
11+
12+
**Is your feature request related to a problem? Please describe.**
13+
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
14+
15+
**Describe the solution you'd like**
16+
A clear and concise description of what you want to happen. Please explain why and how it helps your users.
17+
18+
**Describe alternatives you've considered**
19+
A clear and concise description of any alternative solutions or features you've considered.
20+
21+
**Additional context**
22+
Add any other context or screenshots about the feature request here.
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
---
2+
name: 🐢 Performance
3+
about: "Runtime, memory, speed, or storage inefficiency"
4+
title: ""
5+
labels: "topic: performance"
6+
assignees: ghiggi
7+
---
8+
9+
## Prework
10+
11+
- [ ] Read and agree to the [code of conduct](https://github.com/ltelab/pymascdb/blob/main/CODE_OF_CONDUCT.md).
12+
- [ ] If there is [already a relevant issue](https://github.com/ltelab/pymascdb/issues), whether open or closed, comment on the existing thread instead of posting a new issue.
13+
- [ ] Post a minimal reproducible example so the maintainer can troubleshoot the problems you identify. A reproducible example is:
14+
- [ ] **Runnable**
15+
- [ ] **Minimal**: reduce runtime wherever possible and remove complicated details that are irrelevant to the issue at hand.
16+
17+
## Description
18+
19+
Please describe the performance issue.
20+
21+
## Benchmarks
22+
23+
How poorly does pymascdb perform?

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
# Prework
2+
3+
- [ ] I understand and agree to this repository's [code of conduct](https://github.com/ltelab/pymascdb/blob/main/CODE_OF_CONDUCT.md).
4+
- [ ] I understand and agree to this repository's [contributing guidelines](https://github.com/ltelab/pymascdb/blob/main/CONTRIBUTING.rst).
5+
- [ ] I have already submitted an [issue](https://github.com/ltelab/pymascdb/issues) or [discussion thread](https://github.com/ltelab/pymascdb/discussions) to discuss my idea with the maintainers.
6+
7+
<!-- PULL REQUEST TEMPLATE -->
8+
9+
<!-- (Update "[ ]" to "[x]" to check a box) -->
10+
11+
**What kind of change does this PR introduce?** (check at least one)
12+
13+
- [ ] Bugfix
14+
- [ ] Feature
15+
- [ ] Code style update
16+
- [ ] Refactor
17+
- [ ] Build-related changes
18+
- [ ] Other, please describe:
19+
20+
**Does this PR introduce a breaking change?** (check one)
21+
22+
- [ ] Yes
23+
- [ ] No
24+
25+
If yes, please describe the impact and communicate accordingly:
26+
27+
**The PR fulfills these requirements:**
28+
29+
- [ ] It's submitted to the branch named as follow :
30+
- Add a reader: `reader-<institute>-<campaign>`
31+
- Fix a bug: `bugfix-<some_key>-<word>`
32+
- Improve the doc: `doc-<some_key>-<word>`
33+
- Add a new feature: `feature-<some_key>-<word>`
34+
- Refactor some code: `refactor-<some_key>-<word>`
35+
- Optimize some code: `optimize-<some_key>-<word>`
36+
- [ ] When resolving a specific issue, it's referenced in the PR's title (e.g. `fix #xxx[,#xxx]`, where "xxx" is the issue number)
37+
- [ ] Don't forget to link PR to issue if you are solving one.
38+
- [ ] All tests are passing.
39+
- [ ] New/updated tests are included
40+
41+
If adding a **new feature**, the PR's description includes:
42+
43+
- [ ] A convincing reason for adding this feature (to avoid wasting your time, it's best to open a suggestion issue first and wait for approval before working on it)
44+
45+
**Other information:**
46+
47+
# Related GitHub issues and Pull Requests
48+
49+
- Ref: #
50+
51+
# Summary
52+
53+
Please explain the purpose and scope of your contribution.

.github/dependabot.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# To get started with Dependabot version updates, you'll need to specify which
2+
# package ecosystems to update and where the package manifests are located.
3+
# Please see the documentation for all configuration options:
4+
# https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file
5+
6+
version: 2
7+
updates:
8+
- package-ecosystem: "github-actions" # See documentation for possible values
9+
directory: "/" # Location of package manifests
10+
schedule:
11+
interval: "monthly"

.github/workflows/lint.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Lint
2+
on: [push, pull_request, workflow_dispatch]
3+
4+
jobs:
5+
lint:
6+
runs-on: ubuntu-latest
7+
steps:
8+
- uses: actions/checkout@v6
9+
10+
- name: Setup Python
11+
uses: actions/setup-python@v6
12+
with:
13+
python-version: "3.11"
14+
15+
- name: Ruff
16+
if: success() || failure()
17+
uses: pre-commit/action@v3.0.1
18+
with:
19+
extra_args: ruff --all-files
20+
21+
- name: Black
22+
if: success() || failure()
23+
uses: pre-commit/action@v3.0.1
24+
with:
25+
extra_args: black --all-files --verbose
26+
27+
- name: Blackdoc
28+
if: success() || failure()
29+
uses: pre-commit/action@v3.0.1
30+
with:
31+
extra_args: blackdoc --all-files
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
name: Package Release to PyPI
2+
on:
3+
push:
4+
tags:
5+
- "v*"
6+
7+
jobs:
8+
build-n-publish:
9+
name: Build and publish to PyPI
10+
runs-on: ubuntu-latest
11+
permissions:
12+
contents: write
13+
14+
steps:
15+
- name: Checkout source
16+
uses: actions/checkout@v6
17+
18+
- name: Set up Python
19+
uses: actions/setup-python@v6
20+
with:
21+
python-version: "3.x"
22+
23+
- name: Install pypa/build
24+
run: >-
25+
python -m
26+
pip install build
27+
28+
- name: Build a binary wheel
29+
run: >-
30+
python -m build
31+
32+
- name: Publish distribution to PyPI
33+
uses: pypa/gh-action-pypi-publish@release/v1
34+
with:
35+
user: __token__
36+
password: ${{ secrets.PYPI_API_TOKEN }}
37+
38+
- name: Get Asset name
39+
if: success() || failure()
40+
run: |
41+
export PKG=$(ls dist/ | grep tar)
42+
set -- $PKG
43+
echo "asset_name=$1" >> $GITHUB_ENV
44+
45+
- name: Create GitHub Release
46+
if: success() || failure()
47+
id: create_release
48+
uses: softprops/action-gh-release@v2
49+
with:
50+
name: ${{ github.ref_name }}
51+
tag_name: ${{ github.ref_name }}
52+
files: |
53+
dist/${{ env.asset_name }}
54+
draft: false
55+
prerelease: false
56+
token: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,8 @@ The data should be downloaded from Zenodo at: https://doi.org/10.5281/zenodo.557
7474

7575
The content of this repository is released under the terms of the [MIT license](LICENSE.txt).
7676

77-
[`00_download_mascdb.py`]: https://github.com/ltelab/pymascdb/tree/master/tutorials/00_download_mascdb.py
78-
[`01_data_manipulation.py`]: https://github.com/ltelab/pymascdb/tree/master/tutorials/01_data_manipulation.py
79-
[`02_eda.py`]: https://github.com/ltelab/pymascdb/tree/master/tutorials/02_eda.py
80-
[`03_image_processing.py`]: https://github.com/ltelab/pymascdb/tree/master/tutorials/03_image_processing.py
77+
[`00_download_mascdb.py`]: https://github.com/ltelab/pymascdb/tree/main/tutorials/00_download_mascdb.py
78+
[`01_data_manipulation.py`]: https://github.com/ltelab/pymascdb/tree/main/tutorials/01_data_manipulation.py
79+
[`02_eda.py`]: https://github.com/ltelab/pymascdb/tree/main/tutorials/02_eda.py
80+
[`03_image_processing.py`]: https://github.com/ltelab/pymascdb/tree/main/tutorials/03_image_processing.py
8181
[`online documentation`]: https://pymascdb.readthedocs.io/en/latest/examples.html

docs/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,5 +45,5 @@ It first cleans previous builds (`make clean`) and then generates fresh document
4545

4646
**Note**: It's important to review the output of the command. Look out for warnings or errors and address them to ensure the documentation is accurate and complete.
4747

48-
By following these steps, you should have a local version of the DISDRODB documentation in the `docs/build/html/` directory,
48+
By following these steps, you should have a local version of the pymascdb documentation in the `docs/build/html/` directory,
4949
ready for review or deployment!

0 commit comments

Comments
 (0)