Skip to content

feat(settings): improve commit messages#19851

Merged
nijel merged 1 commit into
WeblateOrg:mainfrom
nijel:commit-messages
Jun 1, 2026
Merged

feat(settings): improve commit messages#19851
nijel merged 1 commit into
WeblateOrg:mainfrom
nijel:commit-messages

Conversation

@nijel
Copy link
Copy Markdown
Member

@nijel nijel commented Jun 1, 2026

  • Follow Conventional Commits specification and make the content of the commit messages consistent.
  • Add button to revert to the site defaults in case users wants to go back to the shipped/configured settings.

Fixes #19806

@nijel nijel added this to the 2026.7 milestone Jun 1, 2026
@nijel nijel requested a review from Copilot June 1, 2026 09:30
@nijel nijel self-assigned this Jun 1, 2026
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: e890e07434

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread weblate/trans/defaults.py Outdated
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR updates Weblate’s default VCS commit / merge request message templates to be more consistent and aligned with the Conventional Commits format, and adds a per-field “Restore site default” control in settings forms to revert message templates back to the current installation defaults.

Changes:

  • Revise default commit/add/delete/merge/add-on/pull message templates in weblate/trans/defaults.py and update affected test expectations.
  • Add “Restore site default” UI support for message template fields (form metadata, template button, JS behavior, and CSS).
  • Add/extend tests to cover rendering of updated default templates and the new site-default restore control in settings UIs.

Reviewed changes

Copilot reviewed 13 out of 13 changed files in this pull request and generated 7 comments.

Show a summary per file
File Description
weblate/workspaces/tests.py Adds coverage to ensure workspace settings include site-default metadata and restore control.
weblate/workspaces/forms.py Marks message template fields as supporting “site default” restore and injects site default values into widget attrs.
weblate/trans/tests/test_settings.py Adds tests validating that new default templates render and that site-default widget attrs/rendering exist across settings forms.
weblate/trans/tests/test_file_format_params.py Updates assertions to match new Conventional Commits-style commit subjects.
weblate/trans/forms.py Introduces setup_message_setting_site_defaults() and wires it into inherited settings handling.
weblate/trans/defaults.py Rewrites built-in default templates to a Conventional Commits-style subject + structured body format.
weblate/templates/bootstrap5/field.html Adds a restore button next to labels for fields marked as site_default.
weblate/static/styles/main.css Adds layout styling for label + restore-button alignment.
weblate/static/loader-bootstrap.js Implements restore-button behavior and refactors inherited-setting helpers for reuse.
docs/changes.rst Documents the behavior change in release notes.
docs/admin/workspaces.rst Documents Conventional Commits-style defaults and the restore control in workspace admin docs.
docs/admin/projects.rst Documents the restore control and inheritance interaction for message templates.
docs/admin/config.rst Documents restore behavior and updates notes for message-related settings.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread weblate/templates/bootstrap5/field.html Outdated
Comment thread docs/changes.rst Outdated
Comment thread docs/admin/workspaces.rst Outdated
Comment thread docs/admin/projects.rst Outdated
Comment thread docs/admin/projects.rst Outdated
Comment thread docs/admin/config.rst Outdated
Comment thread docs/admin/config.rst Outdated
@nijel nijel force-pushed the commit-messages branch from e890e07 to 4ab2da8 Compare June 1, 2026 09:57
@argos-ci
Copy link
Copy Markdown

argos-ci Bot commented Jun 1, 2026

The latest updates on your projects. Learn more about Argos notifications ↗︎

Build Status Details Updated (UTC)
default (Inspect) ⚠️ Changes detected (Review) 12 changed Jun 1, 2026, 12:12 PM

- Follow Conventional Commits specification and make the content of the
  commit messages consistent.
- Add button to revert to the site defaults in case users wants to go
  back to the shipped/configured settings.

Fixes WeblateOrg#19806
@nijel nijel force-pushed the commit-messages branch from 4ab2da8 to d2fc43d Compare June 1, 2026 11:18
@nijel nijel merged commit 19f3a59 into WeblateOrg:main Jun 1, 2026
17 of 20 checks passed
@nijel nijel deleted the commit-messages branch June 1, 2026 11:18
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.

Improve default commit messages

2 participants