Apache Lucene open-source search software
ci: address all zizmor lints (#15258)
Robert Muirc5d82423934d
diff --git a/.github/workflows/label-pull-request.yml b/.github/workflows/label-pull-request.ymlindex 9ec35cd3353..202b15245ac 100644--- a/.github/workflows/label-pull-request.yml+++ b/.github/workflows/label-pull-request.yml@@ -13,18 +13,22 @@ on:# zizmor: ignore[dangerous-triggers]- pull_request_target+permissions: {}+jobs:labeler:+ name: Label PRs# only run on the main Lucene repository.if: (github.repository == 'apache/lucene')permissions:- contents: read- pull-requests: write+ contents: read # likely not needed for public repository+ pull-requests: write # manipulate existing labelsruns-on: ubuntu-lateststeps:- - uses: actions/labeler@8558fd74291d67161a8a78ce36a881fa63b766a9 # v5.0.0+ - name: Run Labeler action+ uses: actions/labeler@8558fd74291d67161a8a78ce36a881fa63b766a9 # v5.0.0with:sync-labels: truediff --git a/.github/workflows/mark-stale-PRs.yml b/.github/workflows/mark-stale-PRs.ymlindex 31accd4cfb8..20fb1757c24 100644--- a/.github/workflows/mark-stale-PRs.yml+++ b/.github/workflows/mark-stale-PRs.yml@@ -10,15 +10,19 @@ on:# Or run on demandworkflow_dispatch:+permissions: {}+jobs:stale:+ name: Mark stale PRsruns-on: ubuntu-latestpermissions:- pull-requests: write+ pull-requests: write # must comment/label PRssteps:- - uses: actions/stale@5bef64f19d7facfb25b37b414482c7164d639639 # v9.1.0+ - name: Run stale PR action+ uses: actions/stale@5bef64f19d7facfb25b37b414482c7164d639639 # v9.1.0with:repo-token: ${{ secrets.GITHUB_TOKEN }}diff --git a/.github/workflows/run-checks-all.yml b/.github/workflows/run-checks-all.ymlindex b86ac7b302f..9efba226742 100644--- a/.github/workflows/run-checks-all.yml+++ b/.github/workflows/run-checks-all.yml@@ -12,6 +12,8 @@ on:- 'main'- 'branch_10x'+permissions: {}+env:DEVELOCITY_ACCESS_KEY: ${{ secrets.DEVELOCITY_ACCESS_KEY }}@@ -37,8 +39,13 @@ jobs:- name: Correct git autocrlfrun: git config --global core.autocrlf false- - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0- - uses: ./.github/actions/prepare-for-build+ - name: Checkout repository+ uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0+ with:+ persist-credentials: false++ - name: Configure tools+ uses: ./.github/actions/prepare-for-build- name: Install eclintif: ${{ ! startsWith(matrix.os, 'windows') }}@@ -72,8 +79,13 @@ jobs:if: startsWith(matrix.os, 'windows')run: git config --global core.autocrlf false- - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0- - uses: ./.github/actions/prepare-for-build+ - name: Checkout repository+ uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0+ with:+ persist-credentials: false++ - name: Configure tools+ uses: ./.github/actions/prepare-for-build- name: Run gradle testsrun: ./gradlew test "-Ptask.times=true" --max-workers 2diff --git a/.github/workflows/run-checks-mod-analysis-common-hunspell.yml b/.github/workflows/run-checks-mod-analysis-common-hunspell.ymlindex 0d69117c2f6..22c150332df 100644--- a/.github/workflows/run-checks-mod-analysis-common-hunspell.yml+++ b/.github/workflows/run-checks-mod-analysis-common-hunspell.yml@@ -19,6 +19,8 @@ on:- '.github/workflows/run-checks-mod-analysis-common.yml'- 'lucene/analysis/common/**'+permissions: {}+env:DEVELOCITY_ACCESS_KEY: ${{ secrets.DEVELOCITY_ACCESS_KEY }}@@ -30,8 +32,13 @@ jobs:runs-on: ubuntu-lateststeps:- - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0- - uses: ./.github/actions/prepare-for-build+ - name: Checkout repository+ uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0+ with:+ persist-credentials: false++ - name: Configure tools+ uses: ./.github/actions/prepare-for-build- name: Run Hunspell regression testsrun: ./gradlew -p lucene/analysis/common -Ptests.hunspell.regressions=true -Ptests.verbose=true test --tests "TestAllDictionaries"diff --git a/.github/workflows/run-checks-mod-distribution.tests.yml b/.github/workflows/run-checks-mod-distribution.tests.ymlindex 97ab7a27174..52389867f1c 100644--- a/.github/workflows/run-checks-mod-distribution.tests.yml+++ b/.github/workflows/run-checks-mod-distribution.tests.yml@@ -13,11 +13,14 @@ on:- 'main'- 'branch_10x'+permissions: {}+env:DEVELOCITY_ACCESS_KEY: ${{ secrets.DEVELOCITY_ACCESS_KEY }}jobs:test:+ name: Run distribution.teststimeout-minutes: 15strategy:@@ -29,8 +32,13 @@ jobs:runs-on: ${{ matrix.os }}steps:- - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0- - uses: ./.github/actions/prepare-for-build+ - name: Checkout repository+ uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0+ with:+ persist-credentials: false++ - name: Configure tools+ uses: ./.github/actions/prepare-for-build- name: Run 'gradlew lucene/distribution.tests test' (on ${{ matrix.os }})run: ./gradlew -p lucene/distribution.tests testdiff --git a/.github/workflows/run-checks-python.yml b/.github/workflows/run-checks-python.ymlindex 97599699e48..0ba69720ada 100644--- a/.github/workflows/run-checks-python.yml+++ b/.github/workflows/run-checks-python.yml@@ -19,13 +19,19 @@ on:- '.github/workflows/run-checks-python.yml'- 'dev-tools/scripts/**'+permissions: {}+jobs:lint:+ name: Lint python scriptstimeout-minutes: 15runs-on: ubuntu-lateststeps:- - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0+ - name: Checkout repository+ uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0+ with:+ persist-credentials: false- name: Setup Pythonuses: actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0diff --git a/.github/workflows/run-scheduled-hunspell.yml b/.github/workflows/run-scheduled-hunspell.ymlindex 407ed76a6a1..d9cf387472b 100644--- a/.github/workflows/run-scheduled-hunspell.yml+++ b/.github/workflows/run-scheduled-hunspell.yml@@ -7,6 +7,8 @@ on:# 4:13 on Mondays- cron: '13 4 * * 1'+permissions: {}+env:DEVELOCITY_ACCESS_KEY: ${{ secrets.DEVELOCITY_ACCESS_KEY }}@@ -18,8 +20,13 @@ jobs:runs-on: ubuntu-lateststeps:- - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0- - uses: ./.github/actions/prepare-for-build+ - name: Checkout repository+ uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0+ with:+ persist-credentials: false++ - name: Configure tools+ uses: ./.github/actions/prepare-for-build- name: Run Hunspell regression tests against latest commits in dictionary repositoriesrun: >diff --git a/.github/workflows/run-scheduled-spotless-groovy.yml b/.github/workflows/run-scheduled-spotless-groovy.ymlindex 723fc02fb70..8d22bfa52f7 100644--- a/.github/workflows/run-scheduled-spotless-groovy.yml+++ b/.github/workflows/run-scheduled-spotless-groovy.yml@@ -7,6 +7,8 @@ on:# 3:13 on Mondays- cron: '13 4 * * 1'+permissions: {}+env:DEVELOCITY_ACCESS_KEY: ${{ secrets.DEVELOCITY_ACCESS_KEY }}@@ -14,14 +16,19 @@ jobs:test:name: Check groovy/gradle script formatting compliancetimeout-minutes: 15-runs-on: ubuntu-lateststeps:- - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0- - uses: ./.github/actions/prepare-for-build+ - name: Checkout repository+ uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0+ with:+ persist-credentials: false++ - name: Configure tools+ uses: ./.github/actions/prepare-for-build- - run: >+ - name: Run formatter check+ run: >./gradlew-Plucene.spotlessGradleScripts=truespotlessGradleScriptsCheckdiff --git a/.github/workflows/run-special-checks-sandbox.yml b/.github/workflows/run-special-checks-sandbox.ymlindex f9a732ffac8..e3d0a258c04 100644--- a/.github/workflows/run-special-checks-sandbox.yml+++ b/.github/workflows/run-special-checks-sandbox.yml@@ -12,6 +12,8 @@ on:- 'main'- 'branch_10x'+permissions: {}+jobs:faiss-tests:name: tests for the Faiss codec (v${{ matrix.faiss-version }} with JDK ${{ matrix.java }} on ${{ matrix.os }})@@ -37,10 +39,14 @@ jobs:conda-remove-defaults: 'true'- name: Install Faiss- run: mamba install faiss-cpu=${{ matrix.faiss-version }}+ run: mamba install faiss-cpu="${FAISS_VERSION}"+ env:+ FAISS_VERSION: ${{ matrix.faiss-version }}- name: Checkout Luceneuses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0+ with:+ persist-credentials: false- name: Prepare Lucene workspaceuses: ./.github/actions/prepare-for-build