-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #19 from astronomy-commons/delucchi/copier
Re-run copier
- Loading branch information
Showing
9 changed files
with
112 additions
and
5 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 |
---|---|---|
@@ -1,5 +1,5 @@ | ||
# Changes here will be overwritten by Copier | ||
_commit: v0.0.3 | ||
_commit: v0.0.5 | ||
_src_path: gh:lincc-frameworks/python-project-template | ||
author_email: [email protected] | ||
author_name: Melissa DeLucchi | ||
|
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 |
---|---|---|
@@ -0,0 +1,60 @@ | ||
repos: | ||
|
||
# Clear output from jupyter notebooks so that only the input cells are committed. | ||
- repo: local | ||
hooks: | ||
- id: jupyter-nb-clear-output | ||
name: jupyter-nb-clear-output | ||
description: Clear output from Jupyter notebooks. | ||
files: \.ipynb$ | ||
stages: [commit] | ||
language: system | ||
entry: jupyter nbconvert --ClearOutputPreprocessor.enabled=True --inplace | ||
|
||
# Run unit tests, verify that they pass | ||
- repo: local | ||
hooks: | ||
- id: pytest-check | ||
name: pytest-check | ||
description: Run unit tests with pytest. | ||
entry: pytest --cov=. --cov-report=html | ||
language: system | ||
pass_filenames: false | ||
always_run: true | ||
|
||
# prevents committing directly branches named 'main' and 'master'. | ||
- repo: https://github.com/pre-commit/pre-commit-hooks | ||
rev: v4.4.0 | ||
hooks: | ||
- id: no-commit-to-branch | ||
name: Don't commit to main or master branch | ||
description: Prevent the user from committing directly to the primary branch. | ||
|
||
# verify that pyproject.toml is well formed | ||
- repo: https://github.com/abravalheri/validate-pyproject | ||
rev: v0.12.1 | ||
hooks: | ||
- id: validate-pyproject | ||
name: Validate syntax of pyproject.toml | ||
description: Verify that pyproject.toml adheres to the established schema. | ||
|
||
# Automatically sort the imports used in .py files | ||
- repo: https://github.com/pycqa/isort | ||
rev: 5.12.0 | ||
hooks: | ||
- id: isort | ||
name: isort (python) | ||
description: Sort and organize imports in .py files. | ||
|
||
- repo: local | ||
hooks: | ||
- id: pylint | ||
name: pylint | ||
entry: pylint | ||
language: system | ||
types: [python] | ||
args: | ||
[ | ||
"-rn", # Only display messages | ||
"-sn", # Don't display the score | ||
] |
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 @@ | ||
Put your Jupyter notebooks here :) |
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 @@ | ||
{ | ||
"cells": [ | ||
{ | ||
"cell_type": "code", | ||
"execution_count": null, | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"a = 2 + 2" | ||
] | ||
} | ||
], | ||
"metadata": { | ||
"kernelspec": { | ||
"display_name": "copier_test", | ||
"language": "python", | ||
"name": "python3" | ||
}, | ||
"language_info": { | ||
"name": "python", | ||
"version": "3.10.8 | packaged by conda-forge | (main, Nov 22 2022, 08:25:29) [Clang 14.0.6 ]" | ||
}, | ||
"orig_nbformat": 4, | ||
"vscode": { | ||
"interpreter": { | ||
"hash": "49ec39369c99805342b11327ac0d7c4ce794e7071ab73521f56ecad9648013da" | ||
} | ||
} | ||
}, | ||
"nbformat": 4, | ||
"nbformat_minor": 2 | ||
} |
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