Skip to content

Commit 6e52d6e

Browse files
committed
Undo yaml formatting changes, update spotless to Spotless
1 parent 06325f8 commit 6e52d6e

File tree

2 files changed

+6
-18
lines changed

2 files changed

+6
-18
lines changed

.github/workflows/ci.yml

Lines changed: 4 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
on:
66
pull_request:
77
push:
8-
branches: [ main ]
8+
branches: [main]
99
workflow_dispatch:
1010

1111
concurrency:
@@ -23,32 +23,28 @@ jobs:
2323
uses: actions/checkout@v4
2424
with:
2525
fetch-depth: 0
26-
2726
- name: Install JDK 11
2827
uses: actions/setup-java@v4
2928
with:
3029
distribution: "temurin"
3130
java-version: 11
32-
3331
- name: gradle caching
3432
uses: gradle/actions/setup-gradle@v3
3533
with:
3634
gradle-home-cache-cleanup: true
37-
3835
- name: spotlessCheck
3936
run: ./gradlew spotlessCheck
40-
4137
- name: assemble testClasses
4238
run: ./gradlew assemble testClasses
4339
build:
4440
needs: sanityCheck
4541
strategy:
4642
fail-fast: false
4743
matrix:
48-
kind: [ maven, gradle ]
44+
kind: [maven, gradle]
4945
# Test on the latest Java version once Gradle & Maven support it.
50-
jre: [ 11, 17, 21 ]
51-
os: [ ubuntu-latest ]
46+
jre: [11, 17, 21]
47+
os: [ubuntu-latest]
5248
include:
5349
# test windows at the diagonals of the above matrix
5450
- kind: maven
@@ -69,40 +65,32 @@ jobs:
6965
steps:
7066
- name: Checkout
7167
uses: actions/checkout@v4
72-
7368
- name: Install JDK ${{ matrix.distribution }} ${{ matrix.java_version }}
7469
uses: actions/setup-java@v4
7570
with:
7671
distribution: "temurin"
7772
java-version: ${{ matrix.jre }}
78-
7973
- name: gradle caching
8074
uses: gradle/actions/setup-gradle@v3
8175
with:
8276
gradle-home-cache-cleanup: true
83-
8477
- name: build (maven-only)
8578
if: matrix.kind == 'maven'
8679
run: ./gradlew :plugin-maven:build -x spotlessCheck
87-
8880
- name: build (everything-but-maven)
8981
if: matrix.kind == 'gradle'
9082
run: ./gradlew build -x spotlessCheck -PSPOTLESS_EXCLUDE_MAVEN=true
91-
9283
- name: test npm
9384
if: matrix.kind == 'npm'
9485
run: ./gradlew testNpm
95-
9686
- name: Install shfmt
9787
if: matrix.kind == 'shfmt'
9888
run: |
9989
curl -sSfL "https://github.com/mvdan/sh/releases/download/v${{ matrix.shfmt-version }}/shfmt_v${{ matrix.shfmt-version }}_linux_amd64" -o /usr/local/bin/shfmt
10090
chmod +x /usr/local/bin/shfmt
101-
10291
- name: Test shfmt
10392
if: matrix.kind == 'shfmt'
10493
run: ./gradlew testShfmt
105-
10694
- name: junit result
10795
uses: mikepenz/action-junit-report@v4
10896
if: always() # always run even if the previous step fails

lib/src/main/java/com/diffplug/spotless/shell/ShfmtStep.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,8 +100,8 @@ static class State implements Serializable {
100100

101101
String format(ProcessRunner runner, String input, File file) throws IOException, InterruptedException {
102102
if (args == null) {
103-
// args will be reused during a single spotless task execution,
104-
// so this "prefix" is being "cached" for each spotless format with shfmt.
103+
// args will be reused during a single Spotless task execution,
104+
// so this "prefix" is being "cached" for each Spotless format with shfmt.
105105
args = List.of(exe.confirmVersionAndGetAbsolutePath(), "--filename");
106106
}
107107

0 commit comments

Comments
 (0)