From bbaadc1822017e6c49a9c2529578bdd8e5917844 Mon Sep 17 00:00:00 2001 From: Ludy Date: Thu, 19 Jun 2025 19:44:01 +0200 Subject: [PATCH] chore: improve label matching rules in labeler config (#3779) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit # Description of Changes - Improved file pattern matching by replacing glob (`**/*`) with regex-style (`.*`) to ensure better compatibility and matching in GitHub's `labeler` action. - Added a missing `Documentation` label rule based on PR titles (`^docs:.*`). - Aligned `Documentation` file-matching rule to use regex pattern (`.*.md`). - Fixed capitalization inconsistency in the auto-labeler workflow: `licenses` → `Licenses`. --- ## Checklist ### General - [x] I have read the [Contribution Guidelines](https://github.com/Stirling-Tools/Stirling-PDF/blob/main/CONTRIBUTING.md) - [x] I have read the [Stirling-PDF Developer Guide](https://github.com/Stirling-Tools/Stirling-PDF/blob/main/DeveloperGuide.md) (if applicable) - [ ] I have read the [How to add new languages to Stirling-PDF](https://github.com/Stirling-Tools/Stirling-PDF/blob/main/HowToAddNewLanguage.md) (if applicable) - [x] I have performed a self-review of my own code - [x] My changes generate no new warnings ### Documentation - [ ] I have updated relevant docs on [Stirling-PDF's doc repo](https://github.com/Stirling-Tools/Stirling-Tools.github.io/blob/main/docs/) (if functionality has heavily changed) - [ ] I have read the section [Add New Translation Tags](https://github.com/Stirling-Tools/Stirling-PDF/blob/main/HowToAddNewLanguage.md#add-new-translation-tags) (for new translation tags only) ### UI Changes (if applicable) - [ ] Screenshots or videos demonstrating the UI changes are attached (e.g., as comments or direct attachments in the PR) ### Testing (if applicable) - [ ] I have tested my changes locally. Refer to the [Testing Guide](https://github.com/Stirling-Tools/Stirling-PDF/blob/main/DeveloperGuide.md#6-testing) for more details. --- .github/labeler-config-srvaroa.yml | 51 ++++++++++++++------------- .github/workflows/licenses-update.yml | 2 +- 2 files changed, 28 insertions(+), 25 deletions(-) diff --git a/.github/labeler-config-srvaroa.yml b/.github/labeler-config-srvaroa.yml index 9bb02d7d7..2fb9365e4 100644 --- a/.github/labeler-config-srvaroa.yml +++ b/.github/labeler-config-srvaroa.yml @@ -28,6 +28,9 @@ labels: - label: "style" title: '^style:.*' + - label: "Documentation" + title: '^docs:.*' + - label: 'API' title: '.*openapi.*' @@ -40,32 +43,33 @@ labels: - label: 'Front End' files: - - 'stirling-pdf/src/main/resources/templates/**/*' - - 'proprietary/src/main/resources/templates/**/*' - - 'stirling-pdf/src/main/resources/static/**/*' - - 'proprietary/src/main/resources/static/**/*' - - 'stirling-pdf/src/main/java/stirling/software/SPDF/controller/web/**/*' - - 'stirling-pdf/src/main/java/stirling/software/SPDF/UI/**/*' + - 'stirling-pdf/src/main/resources/templates/.*' + - 'proprietary/src/main/resources/templates/.*' + - 'stirling-pdf/src/main/resources/static/.*' + - 'proprietary/src/main/resources/static/.*' + - 'stirling-pdf/src/main/java/stirling/software/SPDF/controller/web/.*' + - 'stirling-pdf/src/main/java/stirling/software/SPDF/UI/.*' - label: 'Java' files: - - 'common/src/main/java/**/*.java' - - 'proprietary/src/main/java/**/*.java' - - 'stirling-pdf/src/main/java/**/*.java' + - 'common/src/main/java/.*.java' + - 'proprietary/src/main/java/.*.java' + - 'stirling-pdf/src/main/java/.*.java' - label: 'Back End' files: - - 'stirling-pdf/src/main/java/stirling/software/SPDF/config/**/*' - - 'stirling-pdf/src/main/java/stirling/software/SPDF/controller/**/*' + - 'stirling-pdf/src/main/java/stirling/software/SPDF/config/.*' + - 'stirling-pdf/src/main/java/stirling/software/SPDF/controller/.*' - 'stirling-pdf/src/main/resources/settings.yml.template' - 'stirling-pdf/src/main/resources/application.properties' - 'stirling-pdf/src/main/resources/banner.txt' - 'scripts/png_to_webp.py' - 'split_photos.py' + - 'application.properties' - label: 'Security' files: - - 'proprietary/src/main/java/stirling/software/proprietary/security/**/*' + - 'proprietary/src/main/java/stirling/software/proprietary/security/.*' - 'scripts/download-security-jar.sh' - '.github/workflows/dependency-review.yml' - '.github/workflows/scorecards.yml' @@ -74,18 +78,17 @@ labels: files: - 'stirling-pdf/src/main/java/stirling/software/SPDF/config/OpenApiConfig.java' - 'stirling-pdf/src/main/java/stirling/software/SPDF/controller/web/MetricsController.java' - - 'stirling-pdf/src/main/java/stirling/software/SPDF/controller/api/**/*' - - 'stirling-pdf/src/main/java/stirling/software/SPDF/model/api/**/*' + - 'stirling-pdf/src/main/java/stirling/software/SPDF/controller/api/.*' + - 'stirling-pdf/src/main/java/stirling/software/SPDF/model/api/.*' - 'scripts/png_to_webp.py' - 'split_photos.py' - '.github/workflows/swagger.yml' - label: 'Documentation' files: - - '**/*.md' + - '.*.md' - 'scripts/counter_translation.py' - 'scripts/ignore_translation.toml' - title: '^docs:.*' - label: 'Docker' files: @@ -104,9 +107,9 @@ labels: - label: 'Devtools' files: - - '.devcontainer/**/*' + - '.devcontainer/.*' - 'Dockerfile.dev' - - '.vscode/**/*' + - '.vscode/.*' - '.editorconfig' - '.pre-commit-config' - '.github/workflows/pre_commit.yml' @@ -114,19 +117,19 @@ labels: - label: 'Test' files: - - 'common/src/test/**/*' - - 'proprietary/src/test/**/*' - - 'stirling-pdf/src/test/**/*' - - 'testing/**/*' + - 'common/src/test/.*' + - 'proprietary/src/test/.*' + - 'stirling-pdf/src/test/.*' + - 'testing/.*' - '.github/workflows/scorecards.yml' - label: 'Github' files: - - '.github/**/*' + - '.github/.*' - label: 'Gradle' files: - - 'gradle/**/*' + - 'gradle/.*' - 'gradlew' - 'gradlew.bat' - 'settings.gradle' diff --git a/.github/workflows/licenses-update.yml b/.github/workflows/licenses-update.yml index b62e581ca..227948288 100644 --- a/.github/workflows/licenses-update.yml +++ b/.github/workflows/licenses-update.yml @@ -78,7 +78,7 @@ jobs: title: "Update 3rd Party Licenses" body: | Auto-generated by ${{ steps.setup-bot.outputs.app-slug }}[bot] - labels: licenses,github-actions + labels: Licenses,github-actions draft: false delete-branch: true sign-commits: true