diff --git a/extensions/cli/README.md b/extensions/cli/README.md index 9f12eada0..324d3d7be 100644 --- a/extensions/cli/README.md +++ b/extensions/cli/README.md @@ -44,6 +44,10 @@ cn ls --json - `--resume`: Resume the last session for this terminal - ``: Optional prompt to start with +## Environment Variables + +- `CONTINUE_CLI_DISABLE_COMMIT_SIGNATURE`: Disable adding the Continue commit signature to generated commit messages + ## Commands - `cn`: Start an interactive chat session diff --git a/extensions/cli/src/systemMessage.ts b/extensions/cli/src/systemMessage.ts index d5dee238f..1673914c4 100644 --- a/extensions/cli/src/systemMessage.ts +++ b/extensions/cli/src/systemMessage.ts @@ -173,12 +173,14 @@ export async function constructSystemMessage( systemMessage += '\nYou are operating in _Plan Mode_, which means that your goal is to help the user investigate their ideas and develop a plan before taking action. You only have access to read-only tools and should not attempt to circumvent them to write / delete / create files. For example, it is not acceptable to use the Bash tool to write to files.\n'; } else { - // TODO - make including this coauthor commit configurable - systemMessage += `\nWhen creating commits using any CLI or tool, include the following in the commit message: + // Check if commit signature is disabled via environment variable + if (!process.env.CONTINUE_CLI_DISABLE_COMMIT_SIGNATURE) { + systemMessage += `\nWhen creating commits using any CLI or tool, include the following in the commit message: Generated with [Continue](https://continue.dev) Co-Authored-By: Continue \n`; + } } // In headless mode, add instructions to be concise and only provide final answers