diff --git a/.codespellrc b/.codespellrc new file mode 100644 index 0000000..eb38789 --- /dev/null +++ b/.codespellrc @@ -0,0 +1,6 @@ +[codespell] +# Ref: https://github.com/codespell-project/codespell#using-a-config-file +skip = .git,*.svg,*.css,.codespellrc,cspell.json +check-hidden = true +# ignore-regex = +# ignore-words-list = diff --git a/.github/workflows/codespell.yml b/.github/workflows/codespell.yml new file mode 100644 index 0000000..7c9eafb --- /dev/null +++ b/.github/workflows/codespell.yml @@ -0,0 +1,23 @@ +# Codespell configuration is within .codespellrc +--- +name: Codespell + +on: + push: + branches: [main] + pull_request: + branches: [main] + +permissions: + contents: read + +jobs: + codespell: + name: Check for spelling errors + runs-on: ubuntu-latest + + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Codespell + uses: codespell-project/actions-codespell@v2 diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 2c685f6..7b836e4 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -54,3 +54,10 @@ repos: # W605 - a backslash-character pair that is not a valid escape sequence now # generates a DeprecationWarning. This will eventually become a SyntaxError. # Needed because we use \d as an escape sequence + + # codespell + - repo: https://github.com/codespell-project/codespell + # Configuration for codespell is in .codespellrc + rev: v2.2.6 + hooks: + - id: codespell diff --git a/CHANGELOG.md b/CHANGELOG.md index b7dfd0b..787b107 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,7 +6,7 @@ Observes [Semantic Versioning](https://semver.org/spec/v2.0.0.html) standard and ## [0.6.1] - 2023-08-02 -+ Update DANDI upload funtionality to improve useability ++ Update DANDI upload functionality to improve usability ## [0.6.0] - 2023-07-26 diff --git a/element_interface/caiman_loader.py b/element_interface/caiman_loader.py index 3726afd..6d9e528 100644 --- a/element_interface/caiman_loader.py +++ b/element_interface/caiman_loader.py @@ -79,7 +79,7 @@ def __init__(self, caiman_dir: str): else: raise FileNotFoundError( "No CaImAn analysis output file found at {}" - " containg all required fields ({})".format( + " containing all required fields ({})".format( caiman_dir, _required_hdf5_fields ) ) diff --git a/element_interface/extract_trigger.py b/element_interface/extract_trigger.py index 103e3e0..a31068a 100644 --- a/element_interface/extract_trigger.py +++ b/element_interface/extract_trigger.py @@ -11,7 +11,7 @@ class EXTRACT_trigger: data = load('{scanfile}'); M = data.M; - % Input Paramaters + % Input Parameters config = struct(); {parameters_list_string} @@ -31,7 +31,7 @@ def __init__( Args: scanfile (Union[str, Path]): Full path of the scan - parameters (dict): EXTRACT input paramaters. + parameters (dict): EXTRACT input parameters. output_dir (Union[str, Path]): Directory to store the outputs of EXTRACT analysis. """ assert isinstance(parameters, dict) diff --git a/element_interface/suite2p_loader.py b/element_interface/suite2p_loader.py index 07dbff1..a6c2377 100644 --- a/element_interface/suite2p_loader.py +++ b/element_interface/suite2p_loader.py @@ -64,7 +64,7 @@ def __init__(self, suite2p_dir: str): self.creation_time = min( [p.creation_time for p in self.planes.values()] - ) # ealiest file creation time + ) # earliest file creation time self.curation_time = max( [p.curation_time for p in self.planes.values()] ) # most recent curation time