• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

sds / overcommit / 42942123881
100%

Build:
DEFAULT BRANCH: main
Ran 11 Nov 2026 02:15AM UTC
Jobs 1
Files 225
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

11 Nov 2026 01:53AM UTC coverage: 100.0%. Remained the same
42942123881

push

github

web-flow
Skip the ReplaceBranch prefix when the message already starts with it (#930)

#875 asks for a hook that copies a ticket ID from a branch such as
`task/PROJ-123/fix-login` into the commit message as `[PROJ-123] `.
`ReplaceBranch` can already do this with `branch_pattern` and
`replacement_text`. But with the default `skipped_commit_types`, it runs
only for editor commits. When you remove `message` or `commit` from that
list, the hook adds a second prefix to `git commit -m '[PROJ-123] Fix'`
and to `git commit --amend`. It also prefixes `git commit --fixup`, so
the subject no longer starts with `fixup! ` and `git rebase
--autosquash` does not find the commit.

Leave the message unchanged when it already starts with the replacement
text, or with `fixup! `, `squash! `, or `amend! `. The comparison
ignores surrounding whitespace, so `[PROJ-123]Fix` also counts. A
template that ends in a word character must end at a word boundary:
`PROJ-12 ` does not match `PROJ-123 Fix`. The comparison uses bytes,
because `lstrip` raises on a message that is not valid in the default
encoding, such as an amended Latin-1 commit, and that would stop the
commit. A whitespace-only replacement text is still prepended as before.

The default configuration does not change: it runs the hook only for
editor commits, whose message file starts with a blank line and Git
comments.

Document a ticket ID configuration in the hook's class comment. It keeps
`template` skipped, because a commit template can start with a `#` line,
and the prefix would turn that comment into the subject. It sets
`on_warn: pass`, so branches without a ticket ID do not show a warning.

Follow-up to #875, where a PR with a configurable hook was invited.

Validation: `bundle exec ruby script/parallel_rspec.rb` passes all 1884
examples, and RuboCop reports no offenses on the changed files. 8 of the
new `ReplaceBranch` examples fail against `main`. The others pin
behavior that must not change: a longer ticket ID, a wh... (continued)

13 of 13 new or added lines in 1 file covered. (100.0%)

3841 of 3841 relevant lines covered (100.0%)

3256.13 hits per line

Jobs
ID Job ID Ran Files Coverage
1 42942123881.1 11 Nov 2026 02:15AM UTC 4050
83.82
GitHub Action Run
Source Files on build 42942123881
  • Tree
  • List 225
  • Changed 178
  • Source Changed 1
  • Coverage Changed 178
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #42942123881
  • 09d8643d on github
  • Prev Build on main (#42894416307)
  • Next Build on main (#42945806039)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc