[PR #1496] [CLOSED] Add an option to exclude OpenCode branding from commits #9953

Closed
opened 2026-02-16 18:14:27 -05:00 by yindo · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/anomalyco/opencode/pull/1496
Author: @andreagrandi
Created: 8/1/2025
Status: Closed

Base: devHead: exclude-co-authored


📝 Commits (3)

  • 1765617 Add an option to exclude OpenCode branding from commits
  • eff4009 Simplify include_co_authored_by implementation
  • ee876f1 Implement bash-only logic for include_co_authored_by

📊 Changes

2 files changed (+19 additions, -1 deletions)

View changed files

📝 packages/opencode/src/config/config.ts (+4 -0)
📝 packages/opencode/src/tool/bash.ts (+15 -1)

📄 Description

1. Config Schema (/packages/opencode/src/config/config.ts)

• Added include_co_authored_by boolean field (optional, defaults to true when undefined)
• Users can set this in their opencode.json or opencode.jsonc files

2. Bash Tool Implementation (/packages/opencode/src/tool/bash.ts)

• Modified to dynamically load config and inject the setting into the tool description
• The tool now reads the user's include_co_authored_by setting and adjusts instructions accordingly

Usage

Users can now control commit branding by adding this to their config:

To disable all opencode branding:

{
  "include_co_authored_by": false
}

To keep opencode branding (default behavior):

{
  "include_co_authored_by": true
}

Or simply omit the field entirely

Behavior

When include_co_authored_by: true (default):

Fix user authentication bug

🤖 Generated with [opencode](https://opencode.ai)

Co-Authored-By: opencode <noreply@opencode.ai>

When include_co_authored_by: false:

Fix user authentication bug

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/anomalyco/opencode/pull/1496 **Author:** [@andreagrandi](https://github.com/andreagrandi) **Created:** 8/1/2025 **Status:** ❌ Closed **Base:** `dev` ← **Head:** `exclude-co-authored` --- ### 📝 Commits (3) - [`1765617`](https://github.com/anomalyco/opencode/commit/1765617661a4fae6f51d1612f1f0daa7c98f77a2) Add an option to exclude OpenCode branding from commits - [`eff4009`](https://github.com/anomalyco/opencode/commit/eff4009c5f868231e768bb8a8627419e0e10af17) Simplify include_co_authored_by implementation - [`ee876f1`](https://github.com/anomalyco/opencode/commit/ee876f135a7f499a85e391735bd1220578333e6c) Implement bash-only logic for include_co_authored_by ### 📊 Changes **2 files changed** (+19 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `packages/opencode/src/config/config.ts` (+4 -0) 📝 `packages/opencode/src/tool/bash.ts` (+15 -1) </details> ### 📄 Description ### 1. Config Schema (/packages/opencode/src/config/config.ts) • Added include_co_authored_by boolean field (optional, defaults to true when undefined) • Users can set this in their opencode.json or opencode.jsonc files ### 2. Bash Tool Implementation (/packages/opencode/src/tool/bash.ts) • Modified to dynamically load config and inject the setting into the tool description • The tool now reads the user's include_co_authored_by setting and adjusts instructions accordingly ## Usage Users can now control commit branding by adding this to their config: To disable all opencode branding: ```json { "include_co_authored_by": false } ``` To keep opencode branding (default behavior): ```json { "include_co_authored_by": true } ``` Or simply omit the field entirely ## Behavior When include_co_authored_by: true (default): ```text Fix user authentication bug 🤖 Generated with [opencode](https://opencode.ai) Co-Authored-By: opencode <noreply@opencode.ai> ``` When include_co_authored_by: false: ```text Fix user authentication bug ``` --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
yindo added the pull-request label 2026-02-16 18:14:27 -05:00
yindo closed this issue 2026-02-16 18:14:27 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#9953