Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pre-commit for formatting #66

Merged
merged 3 commits into from
Jan 21, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 17 additions & 1 deletion .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,21 +48,37 @@ jobs:
arch: x64
steps:
- uses: actions/checkout@v4

# Set up Julia
- uses: julia-actions/setup-julia@v2
with:
version: ${{ matrix.version }}
arch: ${{ matrix.arch }}

# Update Julia packages
- name: Update Julia packages
run: |
julia -e 'using Pkg; Pkg.update()' # Automatically update packages

# Cache dependencies
- uses: julia-actions/cache@v2

# Build Julia package
- uses: julia-actions/julia-buildpkg@v1

# Run tests
- uses: julia-actions/julia-runtest@v1
with:
coverage: ${{ matrix.version == '1' && matrix.os == 'ubuntu-latest' && matrix.arch == 'x64' }}

# Process coverage (optional)
- uses: julia-actions/julia-processcoverage@v1
if: matrix.version == '1' && matrix.os == 'ubuntu-latest' && matrix.arch == 'x64'

# Upload to Codecov (optional)
- uses: codecov/codecov-action@v5
if: matrix.version == '1' && matrix.os == 'ubuntu-latest' && matrix.arch == 'x64'
with:
fail_ci_if_error: true
token: ${{ secrets.CODECOV_TOKEN }}
files: lcov.info

8 changes: 8 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
repos:
- repo: https://github.com/qiaojunfeng/pre-commit-julia-format
rev: v0.2.0
hooks:
- id: julia-format
files: ^src/.*\.jl$
#exclude: '(\.(py|json|toml|md)$|^(attic|docs|config|inputs)/.*$)'
args: [--project=./src/]
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
[![Codecov](https://img.shields.io/codecov/c/github/legend-exp/ZeroNuFit.jl?logo=codecov)](https://app.codecov.io/gh/legend-exp/ZeroNuFit.jl)
[![GitHub issues](https://img.shields.io/github/issues/legend-exp/ZeroNuFit.jl?logo=github)](https://github.com/legend-exp/ZeroNuFit.jl/issues)
[![GitHub pull requests](https://img.shields.io/github/issues-pr/legend-exp/ZeroNuFit.jl?logo=github)](https://github.com/legend-exp/ZeroNuFit.jl/pulls)
[![pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit)](https://github.com/pre-commit/pre-commit)

A generic and fully customisable JSON Bayesian unbinned likelihood fit based on [BAT.jl](https://github.com/bat/BAT.jl) developed for neutrinoless double beta decay searches.
For more details about the ZeroNuFit.jl tool, read our online [documentation](https://legend-exp.github.io/ZeroNuFit.jl/).
Loading