Skip to content
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
2 changes: 1 addition & 1 deletion .github/workflows/claude-code-review.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:

- name: Run Claude Code Review
id: claude-review
uses: anthropics/claude-code-action@c0949c50a78c1ec8ce2647db36629b870e715d0c # v1
uses: anthropics/claude-code-action@61a9c274fa7110a66dfafc1bbbced03833eb25fe # v1
with:
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}
prompt: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/claude.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:

- name: Run Claude Code
id: claude
uses: anthropics/claude-code-action@c0949c50a78c1ec8ce2647db36629b870e715d0c # v1
uses: anthropics/claude-code-action@61a9c274fa7110a66dfafc1bbbced03833eb25fe # v1
with:
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ permissions:

jobs:
analyze:
uses: bernardladenthin/actions/.github/workflows/java-codeql.yml@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/.github/workflows/java-codeql.yml@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
permissions:
actions: read
contents: read
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/dependency-submission.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,6 @@ permissions:

jobs:
submit:
uses: bernardladenthin/actions/.github/workflows/java-maven-dependency-submission.yml@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/.github/workflows/java-maven-dependency-submission.yml@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
permissions:
contents: write
2 changes: 1 addition & 1 deletion .github/workflows/osv-scanner.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ permissions:

jobs:
scan:
uses: bernardladenthin/actions/.github/workflows/osv-scanner.yml@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/.github/workflows/osv-scanner.yml@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
permissions:
actions: read
contents: read
Expand Down
54 changes: 27 additions & 27 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,15 +77,15 @@ jobs:
with:
persist-credentials: false
- name: Files equal their templates in bernardladenthin/actions
uses: bernardladenthin/actions/common/check-templates@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/common/check-templates@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
- name: Release gate (every job gates both publish jobs, or release-gate-exemptions.txt says why)
uses: bernardladenthin/actions/common/check-release-gate@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/common/check-release-gate@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
- name: Run scripts parse (bash -n over every bash run script of the workflows and actions)
uses: bernardladenthin/actions/common/check-run-scripts@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/common/check-run-scripts@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
- name: Maven versions (warns where a dependency or plugin differs from a sibling repository)
uses: bernardladenthin/actions/java/check-maven-versions@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/java/check-maven-versions@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
- name: Publication wiring and release asset contract (dry run)
uses: bernardladenthin/actions/java/check-publication@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/java/check-publication@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1

# ---------------------------------------------------------------------------
# GPG signing-key preflight: what maven-gpg-plugin does at deploy time, so a
Expand All @@ -104,7 +104,7 @@ jobs:
runs-on: ubuntu-latest
environment: maven-central
steps:
- uses: bernardladenthin/actions/common/verify-gpg-key@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
- uses: bernardladenthin/actions/common/verify-gpg-key@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
with:
private-key: ${{ secrets.GPG_PRIVATE_KEY }}
passphrase: ${{ secrets.GPG_PASSPHRASE }}
Expand All @@ -125,7 +125,7 @@ jobs:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
with:
persist-credentials: false
- uses: bernardladenthin/actions/java/verify-signing-key-gradle@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
- uses: bernardladenthin/actions/java/verify-signing-key-gradle@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
with:
private-key: ${{ secrets.GPG_PRIVATE_KEY }}
passphrase: ${{ secrets.GPG_PASSPHRASE }}
Expand Down Expand Up @@ -192,7 +192,7 @@ jobs:
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
- name: Display CPU Info
uses: bernardladenthin/actions/common/print-host-info@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/common/print-host-info@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
- uses: actions/setup-java@77dd5b2ce225ea11469928ac317850245a74ae78 # v6.2.0
with:
java-version-file: .java-version
Expand Down Expand Up @@ -282,7 +282,7 @@ jobs:
# Echo the crash logs into the job log (workspace/policies/ci-test-diagnostics.md 3.1).
- name: Print crash logs (on failure)
if: failure()
uses: bernardladenthin/actions/java/print-crash-logs@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/java/print-crash-logs@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
with:
modules: srcmorph srcmorph-cli srcmorph-maven-plugin
- name: Upload crash & surefire dumps
Expand Down Expand Up @@ -333,7 +333,7 @@ jobs:
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
- name: Display CPU Info
uses: bernardladenthin/actions/common/print-host-info@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/common/print-host-info@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
- uses: actions/setup-java@77dd5b2ce225ea11469928ac317850245a74ae78 # v6.2.0
with: { java-version-file: .java-version, distribution: temurin, cache: maven }
- name: Test under vmlens (one class — staged scope)
Expand Down Expand Up @@ -405,13 +405,13 @@ jobs:
# META-INF/versions/** are skipped because a classpath JVM never loads them. The
# java/verify-bytecode action of bernardladenthin/actions.
- name: Verify Java 8 bytecode (no class newer than major 52)
uses: bernardladenthin/actions/java/verify-bytecode@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/java/verify-bytecode@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
with:
max-major: "52"
paths: |
smoke-jars
- name: Run the jar
uses: bernardladenthin/actions/java/smoke-fatjar-cli@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/java/smoke-fatjar-cli@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
with:
jar-dir: smoke-jars
jar-glob: 'srcmorph.jar'
Expand All @@ -423,7 +423,7 @@ jobs:
# the working directory, so a launch that resolves them anywhere else (a wrong base directory,
# a lost subtree) fails here; run from examples/, the two would be the same directory.
- name: Run the jar from the root and count the planned files
uses: bernardladenthin/actions/java/smoke-fatjar-cli@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/java/smoke-fatjar-cli@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
with:
jar-dir: smoke-jars
jar-glob: 'srcmorph.jar'
Expand Down Expand Up @@ -531,7 +531,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
- uses: actions/setup-java@b843ebf9b913146b38da2eaa7aeddf76074ae1ad # v6
- uses: actions/setup-java@77dd5b2ce225ea11469928ac317850245a74ae78 # v6.2.0
with:
java-version-file: .java-version
distribution: temurin
Expand All @@ -544,7 +544,7 @@ jobs:
-DincludeScope=runtime -Dmdep.outputFile="$PWD/runtime.classpath"
javac --release 8 -Xlint:-options -cp srcmorph/target/classes -d linearity \
srcmorph/src/test/java/net/ladenthin/srcmorph/facts/FactPatternLinearity.java
- uses: actions/setup-java@b843ebf9b913146b38da2eaa7aeddf76074ae1ad # v6
- uses: actions/setup-java@77dd5b2ce225ea11469928ac317850245a74ae78 # v6.2.0
with:
java-version: '8'
distribution: temurin
Expand Down Expand Up @@ -604,7 +604,7 @@ jobs:
# a release is tagged on.
- name: Require a SNAPSHOT version
if: inputs.publish_to_central
uses: bernardladenthin/actions/java/check-release-ref@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/java/check-release-ref@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
with:
channel: snapshot

Expand All @@ -619,7 +619,7 @@ jobs:
persist-credentials: false
# The tag names exactly the project version (v1.2.3 for 1.2.3), which is no SNAPSHOT.
- name: Require the release version the tag names
uses: bernardladenthin/actions/java/check-release-ref@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/java/check-release-ref@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
with:
channel: release

Expand Down Expand Up @@ -664,7 +664,7 @@ jobs:
*) echo "::error::Refusing to publish non-SNAPSHOT version '$VERSION' from the snapshot job. Snapshot publishing requires a -SNAPSHOT version; releases go through the v* tag path."; exit 1 ;;
esac
# The collect step runs actionlib of bernardladenthin/actions (on PYTHONPATH from here).
- uses: bernardladenthin/actions/common/setup@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
- uses: bernardladenthin/actions/common/setup@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
- name: Show effective POM (debug)
run: mvn --batch-mode --no-transfer-progress -P release -DskipUpload=true help:effective-pom
- name: Stage snapshot
Expand All @@ -675,7 +675,7 @@ jobs:
run: python3 -m actionlib.java.releaseassets central-assets --maven-only
- name: Finalize and secure the signed publication
id: finalize
uses: bernardladenthin/actions/java/finalize-publication@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/java/finalize-publication@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
with:
channel: snapshot
maven-assets: central-assets
Expand All @@ -692,7 +692,7 @@ jobs:
permissions:
contents: write
steps:
- uses: bernardladenthin/actions/java/publish-github@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
- uses: bernardladenthin/actions/java/publish-github@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
with:
channel: snapshot
assets-complete: ${{ needs.publish-snapshot.outputs.assets_complete }}
Expand Down Expand Up @@ -730,7 +730,7 @@ jobs:
gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }}
gpg-passphrase: MAVEN_GPG_PASSPHRASE
# The collect step runs actionlib of bernardladenthin/actions (on PYTHONPATH from here).
- uses: bernardladenthin/actions/common/setup@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
- uses: bernardladenthin/actions/common/setup@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
- name: Show effective POM (debug)
run: mvn --batch-mode --no-transfer-progress -P release -DskipUpload=true help:effective-pom
- name: Stage release
Expand All @@ -741,7 +741,7 @@ jobs:
run: python3 -m actionlib.java.releaseassets central-assets --maven-only
- name: Finalize and secure the signed publication
id: finalize
uses: bernardladenthin/actions/java/finalize-publication@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/java/finalize-publication@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
with:
channel: release
maven-assets: central-assets
Expand All @@ -755,7 +755,7 @@ jobs:
permissions:
contents: write
steps:
- uses: bernardladenthin/actions/java/publish-github@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
- uses: bernardladenthin/actions/java/publish-github@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
with:
channel: release
assets-complete: ${{ needs.publish-release.outputs.assets_complete }}
Expand All @@ -780,7 +780,7 @@ jobs:
with:
persist-credentials: false
- name: Transfer frozen artifacts (no rebuild, signing or validation polling)
uses: bernardladenthin/actions/java/publish-central@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/java/publish-central@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
with:
channel: snapshot
assets-complete: ${{ needs.publish-snapshot.outputs.assets_complete }}
Expand All @@ -801,7 +801,7 @@ jobs:
with:
persist-credentials: false
- name: Transfer frozen artifacts (no rebuild, signing or validation polling)
uses: bernardladenthin/actions/java/publish-central@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/java/publish-central@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
with:
channel: release
assets-complete: ${{ needs.publish-release.outputs.assets_complete }}
Expand All @@ -819,7 +819,7 @@ jobs:
id-token: write
attestations: write
steps:
- uses: bernardladenthin/actions/java/attest-publication@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
- uses: bernardladenthin/actions/java/attest-publication@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
with:
channel: snapshot
assets-complete: ${{ needs.publish-snapshot.outputs.assets_complete }}
Expand All @@ -835,7 +835,7 @@ jobs:
id-token: write
attestations: write
steps:
- uses: bernardladenthin/actions/java/attest-publication@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
- uses: bernardladenthin/actions/java/attest-publication@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
with:
channel: release
assets-complete: ${{ needs.publish-release.outputs.assets_complete }}
2 changes: 1 addition & 1 deletion .github/workflows/reuse.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ permissions:

jobs:
test:
uses: bernardladenthin/actions/.github/workflows/reuse.yml@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/.github/workflows/reuse.yml@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
2 changes: 1 addition & 1 deletion .github/workflows/sonarqube.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,6 @@ permissions:

jobs:
build:
uses: bernardladenthin/actions/.github/workflows/java-sonarqube.yml@44390bd464395f560f4170d2c4bfb7a6348541b3 # v1.1.0
uses: bernardladenthin/actions/.github/workflows/java-sonarqube.yml@a9386a26fe6706204cb4d975e6958d29bc783624 # v1.1.1
secrets:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
11 changes: 11 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -379,6 +379,17 @@ The entries below hold the details; what a 1.4.0 user changes:

### Changed

- **Dependencies, build plugins and Actions, in step with the sibling repositories:** Jackson 2.23.0,
maven-enforcer-plugin 3.7.0 in `examples/build-your-own-jar` (the reactor had it already),
`actions/setup-java` 6.2.0 in the `linearity-jdk8` job and `anthropics/claude-code-action` v1.0.269.
`bernardladenthin/actions` is pinned at v1.1.1: its actions and reusable workflows run
`actions/setup-java` 6.2.0, `github/codeql-action` 4.39.3, `gradle/actions/setup-gradle` 6.4.1 and
`softprops/action-gh-release` 3.0.4, and `verify-signing-key-gradle` signs with Gradle 9.9.0 by
default. Error Prone 2.52.0 (#273, already on `main`) reports the `StringBuffer` of the `${name}`
substitution in `SrcMorphConfigurationFileLoader` as `JdkObsolete`, which `-Werror` turned into a
failed compile; the substitution copies into a `StringBuilder` by hand now, because the
`StringBuilder` overload of `Matcher.appendReplacement` is Java 9+ and the core is release 8. The
output is unchanged.
- **The configuration loader refuses a fraction in a whole-number key** (breaking), naming the key:
Jackson cut `charsPerToken: 2.5` to `2` and `0.5` to `0`, which switches srcmorph to the static
`maxInputChars`; run.py's `--chars-per-token 0.5` reached srcmorph that way. A floating-point key
Expand Down
2 changes: 1 addition & 1 deletion examples/build-your-own-jar/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ SPDX-License-Identifier: MIT OR Apache-2.0
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<version>3.6.3</version>
<version>3.7.0</version>
<executions>
<execution>
<id>require-natives</id>
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ SPDX-License-Identifier: Apache-2.0
parent POM, so the version used by both jackson dependencyManagement entries must live
at this level. srcmorph-cli/pom.xml does not redeclare it.
-->
<jackson.version>2.22.4</jackson.version>
<jackson.version>2.23.0</jackson.version>
</properties>

<!--
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -231,16 +231,19 @@ private static JsonNode substituted(final JsonNode node, final Map<String, Strin
*/
static String substitute(final String text, final Map<String, String> properties) {
final Matcher matcher = ESCAPABLE_REFERENCE.matcher(text);
final StringBuffer result = new StringBuffer(text.length());
// Copied by hand rather than with appendReplacement: its StringBuilder overload is Java 9+,
// and this module is release 8.
final StringBuilder result = new StringBuilder(text.length());
int copied = 0;
while (matcher.find()) {
final boolean escaped = matcher.group().startsWith(ESCAPED_OPENER);
final String reference = escaped ? matcher.group().substring(1) : matcher.group();
final String name = matcher.group(1);
final String value = escaped || name == null ? null : properties.get(name);
matcher.appendReplacement(result, Matcher.quoteReplacement(value != null ? value : reference));
result.append(text, copied, matcher.start()).append(value != null ? value : reference);
copied = matcher.end();
}
matcher.appendTail(result);
return result.toString();
return result.append(text, copied, text.length()).toString();
}

/**
Expand Down
Loading