From 20aa3dcbf7943a825d2d1b9e288dedda4afaf9f5 Mon Sep 17 00:00:00 2001 From: Jerome Guterl Date: Tue, 14 May 2024 15:35:57 -0700 Subject: [PATCH] add Format --- .github/workflows/Format.yml | 30 ++++++++++++++++++++++++++++++ README.md | 4 +--- 2 files changed, 31 insertions(+), 3 deletions(-) create mode 100644 .github/workflows/Format.yml diff --git a/.github/workflows/Format.yml b/.github/workflows/Format.yml new file mode 100644 index 0000000..226e8e3 --- /dev/null +++ b/.github/workflows/Format.yml @@ -0,0 +1,30 @@ +name: Format +on: + push: + branches: [master] + tags: [v*] + pull_request: + +jobs: + format: + name: "Format Check" + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: julia-actions/setup-julia@v2 + with: + version: 1 + - uses: julia-actions/cache@v2 + - name: Install JuliaFormatter and format + run: | + using Pkg + Pkg.add(PackageSpec(name="JuliaFormatter")) + using JuliaFormatter + format("."; verbose=true) + shell: julia --color=yes {0} + - name: Suggest formatting changes + uses: reviewdog/action-suggester@v1 + if: github.event_name == 'pull_request' + with: + tool_name: JuliaFormatter + fail_on_error: true \ No newline at end of file diff --git a/README.md b/README.md index 8c0480d..4a9116b 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,4 @@ -[![CI][ci-img]][ci-url] -[ci-img]: https://github.com/ProjectTorreyPines/ADAS.jl/.github/workflows/ci.yml/badge.svg?branch=master -[ci-url]: https://github.com/ProjectTorreyPines/ADAS.jl/.github/workflows/ci.yml?query=workflow +![CI](https://github.com/ProjectTorreyPines/ADAS.jl/.github/workflows/ci.yml/badge.svg?branch=master) # ADAS.jl This package provides ADAS ionization, recombination, radiation, ... rates and some functions to retrieve cooling rates, Zeff and effective charge state.