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

Use julia-format action #965

Merged
merged 4 commits into from
Jul 29, 2024
Merged
Show file tree
Hide file tree
Changes from 3 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
29 changes: 6 additions & 23 deletions .github/workflows/FormatPR.yml
Original file line number Diff line number Diff line change
@@ -1,28 +1,11 @@
name: FormatPR
name: Format suggestions
on:
push:
branches:
- master
pull_request

jobs:
build:
code-style:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install JuliaFormatter and format
run: |
julia -e 'import Pkg; Pkg.add("JuliaFormatter")'
julia -e 'using JuliaFormatter; format(".")'
- name: Create Pull Request
id: cpr
uses: peter-evans/create-pull-request@v6
- uses: julia-actions/julia-format@v3
with:
token: ${{ secrets.GITHUB_TOKEN }}
commit-message: ":robot: Format .jl files"
title: '[AUTO] JuliaFormatter.jl run'
branch: auto-juliaformatter-pr
delete-branch: true
labels: formatting, automated pr, no changelog
- name: Check outputs
run: |
echo "Pull Request Number - ${{ steps.cpr.outputs.pull-request-number }}"
echo "Pull Request URL - ${{ steps.cpr.outputs.pull-request-url }}"
version: '1' # Set `version` to '1.0.54' if you need to use JuliaFormatter.jl v1.0.54 (default: '1')
2 changes: 1 addition & 1 deletion src/Meshes.jl
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ import TransformsBase: parameters, preprocess
import CoordRefSystems: lentype

# unit utils
include("units.jl")
include("units.jl")
juliohm marked this conversation as resolved.
Show resolved Hide resolved
juliohm marked this conversation as resolved.
Show resolved Hide resolved

# IO utils
include("ioutils.jl")
Expand Down
Loading