The Curated Daily
← Back to the archiveDispatch · 5 min read
Dispatch

VS Code inserting 'Co-Authored-by Copilot' into commits regardless of usage

By the editors·Saturday, May 2, 2026·5 min read
A laptop screen showing a code editor with visible programming code in a dimly lit environment.
Photograph by Daniil Komov · Pexels

As a finance professional increasingly reliant on code – whether for automating financial modeling, building trading algorithms, or analyzing large datasets – maintaining clean and accurate version control is critical. Git, and by extension platforms like GitHub, GitLab, and Bitbucket, are foundational to this process. Recently, many developers, including those in the financial sector, have noticed a peculiar and often unwanted addition to their Git commit messages: “Co-Authored-by Copilot”.

This isn't necessarily a bug, but a feature (or arguably, a somewhat overzealous feature) of Microsoft’s popular code editor, Visual Studio Code (VS Code), interacting with its AI pair programmer, Copilot. This article will delve into why this happens, the potential implications for finance professionals, and, most importantly, how to regain control of your commit authorship.

Why is VS Code Adding 'Co-Authored-by Copilot' to My Commits?

The root cause lies in how VS Code and Copilot are designed to work together. Copilot isn't just suggesting code snippets; it actively contributes to the code you write. When Copilot suggests a substantial chunk of code that you accept (often with a simple Tab key), VS Code, by default, attributes Copilot as a co-author in the Git commit.

This is intended to provide appropriate attribution for AI assistance. Microsoft wants to acknowledge Copilot's role in the coding process, and from a legal and ethical standpoint, that makes sense. However, for many developers, especially in regulated fields like finance where clear authorship is paramount, this automatic attribution can be problematic. It can muddy the waters regarding accountability and intellectual property.

Here’s a breakdown of the key contributing factors:

  • Copilot’s Contribution Threshold: The degree of code completion that triggers the “Co-Authored-by Copilot” attribution isn't precisely defined. It's not simply any suggestion; it needs to be a significant portion of the committed changes.
  • VS Code’s Default Behavior: VS Code, out-of-the-box, is configured to automatically add this attribution.
  • Git Configuration: Your Git configuration doesn't directly control this behavior. It's a VS Code/Copilot interaction happening before the commit message is finalized.

Why This Matters for Finance Professionals

The finance industry operates under strict regulatory scrutiny and demands impeccable audit trails. The "Co-Authored-by Copilot" attribution, while seemingly minor, can introduce complexities in these areas:

  • Compliance: Regulators require clear documentation of who wrote which parts of the code used in financial models, trading systems, and risk management tools. Attributing authorship to an AI can create ambiguity.
  • Intellectual Property: Financial models and algorithms often represent significant intellectual property. Accurately tracking authorship is crucial for protecting these assets. AI-generated code raises questions about ownership.
  • Auditability: Auditors need to be able to trace the origins of code changes to understand the reasoning behind them. An AI co-author doesn't provide that insight.
  • Accountability: If a financial model produces an incorrect result due to a coding error, it's essential to identify the responsible developer. Sharing authorship with Copilot complicates this process.
  • Reproducibility: In financial modeling, reproducibility is key. Knowing the exact code changes made by a human developer allows for accurate recreation of results.

How to Disable 'Co-Authored-by Copilot'

Fortunately, VS Code provides a setting to disable this automatic attribution. Here's how to do it:

  1. Open VS Code Settings: Go to File > Preferences > Settings (or Code > Preferences > Settings on macOS).
  2. Search for “Copilot”: In the settings search bar, type “copilot”.
  3. Locate "Git: Co-authored By Copilot": You'll find a setting labeled “Git: Co-authored By Copilot”.
  4. Uncheck the Box: Uncheck the box next to this setting. This will prevent VS Code from automatically adding the "Co-Authored-by Copilot" line to your Git commits.

Alternatively, you can edit the settings.json file directly. Add the following line to your settings:

```json

"git.coauthoredByCopilot": false

Important Note: This setting disables the attribution going forward. It won’t remove the “Co-Authored-by Copilot” line from previous commits. You’ll need to amend those commits manually if you want to remove it (see the section below on amending commits).

Amending Existing Commits

If you’ve already committed code with the unwanted attribution, you can amend those commits. This rewrites the commit history, so proceed with caution, especially if you’re working on a shared repository.

  1. Identify the Commit: Use git log to find the commit hash you want to amend.
  2. Amend the Commit: Use the following command:

```bash

git commit --amend -m "Your original commit message"

This will open your VS Code editor with the commit message. Remove the "Co-Authored-by Copilot" line from the message. Save and close the editor.

  1. Force Push (If Necessary): If you've already pushed the commit to a remote repository, you'll need to force push the amended commit. WARNING: Force pushing can overwrite history and cause problems for other developers working on the same branch. Use with extreme caution.

```bash

git push --force-with-lease origin <branch_name>

--force-with-lease is a safer alternative to --force because it prevents overwriting commits that others have added to the remote branch.

Best Practices for Finance Professionals Using VS Code and Copilot

To minimize the risk of issues related to code authorship and compliance, consider these best practices:

  • Disable Automatic Attribution: As described above, disable “Git: Co-authored By Copilot” in your VS Code settings.
  • Review Copilot's Suggestions Carefully: Don't blindly accept Copilot's code. Understand what it's doing and ensure it aligns with your requirements.
  • Write Clear and Concise Commit Messages: Focus on what the change accomplishes, not how it was implemented (especially if Copilot assisted).
  • Document Copilot Usage (If Necessary): If you're required to document the use of AI tools, keep a record of when and how you used Copilot for a particular change.
  • Consider Using a Code Review Process: Have another developer review your code to ensure its accuracy and compliance.
  • Stay Updated: Microsoft regularly updates VS Code and Copilot. Keep your tools up to date to benefit from bug fixes and new features.

https://example.com/ - Consider a subscription to a reliable development tool suite to aid in your workflow.

https://example.com/ - Enhance your coding environment with a comfortable and efficient keyboard and monitor.

Conclusion

VS Code and Copilot are powerful tools that can significantly enhance the productivity of finance professionals. However, it's crucial to understand their potential impact on code authorship and compliance. By disabling the automatic "Co-Authored-by Copilot" attribution and following best practices, you can leverage the benefits of AI assistance while maintaining the integrity and accountability of your code. A proactive approach to these considerations will ensure you remain compliant with regulations and protect your valuable intellectual property.

Disclaimer: This article contains affiliate links. If you purchase a product through one of these links, I may receive a commission. This does not affect the price you pay.

Pass it onX·LinkedIn·Reddit·Email
The Sunday note

If this was your kind of read.

Sign up for the morning email — short, hand-written, and sent only when there's something worth your time.

Free, sent from a person, not a system. Unsubscribe in one click whenever.

Keep reading

The archive →