Skip to content

Fix Ktlint workflow to include .kts files#13

Merged
tejpratap46 merged 1 commit intomainfrom
chore/fix-ktlint-action
Dec 12, 2025
Merged

Fix Ktlint workflow to include .kts files#13
tejpratap46 merged 1 commit intomainfrom
chore/fix-ktlint-action

Conversation

@tejpratap46
Copy link
Owner

@tejpratap46 tejpratap46 commented Dec 12, 2025

Updated Ktlint workflow to include .kts files in subdirectories.

Summary by CodeRabbit

  • Chores
    • Enhanced code quality workflow path filters to properly detect Kotlin files in all subdirectories and source locations outside the standard src/ directory structure.
    • Enabled manual triggering of code quality checks directly from GitHub Actions UI, providing developers with greater control and flexibility over CI/CD workflow execution and scheduling.

✏️ Tip: You can customize this high-level summary in your review settings.

Updated Ktlint workflow to include .kts files in subdirectories.
@gemini-code-assist
Copy link

Note

Gemini is unable to generate a summary for this pull request due to the file types involved not being currently supported.

@coderabbitai
Copy link

coderabbitai bot commented Dec 12, 2025

Walkthrough

GitHub Actions workflow configuration updated to improve Kotlin file detection across the repository and enable manual workflow triggering via the Actions UI.

Changes

Cohort / File(s) Summary
Workflow Configuration
\.github/workflows/ktlint\.yml
Updated path filter patterns from **.kts to **/*.kts for recursive subdirectory matching; added **/*.kt to catch Kotlin files outside src/ directory; added workflow_dispatch trigger for manual workflow execution

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

  • Configuration syntax change with straightforward glob pattern updates
  • Verify path patterns correctly match intended Kotlin file locations
  • Confirm workflow_dispatch trigger syntax aligns with GitHub Actions specifications

Poem

🐰 The workflows now run swift and true,
With patterns that catch both old and new,
Manual triggers spring to life,
Linting files without the strife,
GitHub Actions, refined anew! ✨

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main change: fixing the Ktlint workflow to include .kts files in subdirectories, which is the primary objective of the pull request.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch chore/fix-ktlint-action

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (1)
.github/workflows/ktlint.yml (1)

7-7: Consolidate redundant path filters.

Line 9's **/*.kt pattern is a superset that already matches all files covered by line 7's src/**/*.kt. Consider removing line 7 to simplify the configuration while maintaining identical coverage.

 on:
   pull_request:
     paths:
       - .github/workflows/ktlint.yml
-      - 'src/**/*.kt'
       - '**/*.kts'
       - '**/*.kt'

Also applies to: 9-9

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 738991c and 2dfb15f.

📒 Files selected for processing (1)
  • .github/workflows/ktlint.yml (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: build
  • GitHub Check: Build lyrics-maker
  • GitHub Check: dependency-submission
  • GitHub Check: Build app
🔇 Additional comments (2)
.github/workflows/ktlint.yml (2)

8-9: Glob patterns corrected for Kotlin file detection.

The fixes are correct:

  • Line 8: **/*.kts is the proper glob pattern (replacing the invalid **.kts) to match .kts files at any depth.
  • Line 9: **/*.kt catches all .kt files regardless of directory structure.

10-10: workflow_dispatch addition improves usability.

Manual workflow triggers are helpful for local testing and re-running checks without pushing new commits.

@tejpratap46 tejpratap46 merged commit 134085f into main Dec 12, 2025
7 of 8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant