Skip to main content

Posts

Restrict MCP server access when using Github Copilot -

As GitHub Copilot expands its capabilities through the Model Context Protocol (MCP), it introduces an extra security challenge: how to give developers access to powerful AI tools while maintaining control over what external services those tools can access. This post walks you through setting up a curated MCP registry and enforcing access controls across your organization or enterprise when using Github Copilot. Why restrict access? MCP servers extend Copilot's capabilities by connecting it to external tools, databases, APIs, and services. While this opens up incredible possibilities for developer productivity, it also introduces potential security risks. Without proper controls, developers could: Connect Copilot to unauthorized external services Expose sensitive data to third-party MCP servers Use tools that don't meet your organization's security or compliance requirements Bypass established security policies through AI-assisted workflows A way is n...
Recent posts

Git worktrees–A first step towards a multi-agent development workflow

As AI coding assistants become more sophisticated, we're approaching a future where multiple agents might work on different parts of your codebase simultaneously. But there's a challenge: how do you let multiple processes work on the same repository without constantly stepping on each other's toes? One solution is to have agents work on dedicated machines like GitHub Copilot Agent does in a GitHub Codespace. But what if you want to have multiple agents working on your local machine? Enter git worktrees – a powerful Git feature that's been hiding in plain sight since 2015, and the perfect foundation for multi-agent development workflows. What are Git worktrees? Git worktrees allow you to check out multiple branches from the same repository simultaneously, each in its own directory. Think of it as having multiple working directories all sharing the same Git history, but each can be on a different branch. Here's the key insight: while the working directories...

Catching dependency injection configuration errors early

When building applications with .NET's dependency injection container, misconfigured services can lead to runtime exceptions that only surface when a particular code path is executed. Consider this scenario: you've registered a service with dependencies, but accidentally forgot to register one of those dependencies. Without validation, your application starts successfully, but crashes later when someone tries to use that service: This only fails when OrderService is first resolved, which might be deep in your application logic or in a rarely-used code path. Failing fast A better option is to fail fast and be aware of this problem immediately. This is exactly what the ValidateOnBuild property does. It tells the DI container to validate all registered services during the application startup phase: Now, instead of a runtime failure later, you get an immediate exception during startup with a clear error message about the missing dependency. Remark: Be aware, this i...

Give your Github Copilot a break

Github Copilot can be your best friend inside your IDE but also a pain in the *** when it keeps coming up with suggestions you are not waiting for. Of course you could disable the Github Copilot extension in your IDE, but that would be a shame. Hit snooze A small but useful feature I discovered recently is the Snooze option in VSCode. This allows you to disable Copilot for a short amount of time (5 minutes by default). To use this feature, click on the Github icon in the right bottom corner of VSCode: Now you see a Snooze button. Click on it to hide completions and suggestions for the next 5 minutes. A timer appears counting down and the Copilot icon is updated to indicate that the snooze mode is active (nice touch). You can cancel the snooze period at any moment by clicking on the Stop button.

Github Copilot–Auto model select

With the ever growing list of supported AI models in Github Copilot, there is one question that is getting harder to answer. Which model should I use?  You can try to safe some money and stay away from the premium request models, but even then you have a lot of options to choose from. You also could check out the model recommendations based on the task you try to achieve but isn’t there a better way? Enter Auto mode With the latest update of GitHub Copilot in Visual Studio Code now a new Auto option is available. When you select Auto from the model picker, Copilot will select an appropriate model for you.   It is not clear what criteria are used to select a model but you can find out the chosen model at the bottom of the response:   Be aware that it is be possible that Auto mode could choose a premium request model, although a discount of 10% is applied when auto mode selects a premium requests model (if you are using a paid plan). For example, Sonn...

Six words that define your leadership

I was listening to the Coaching for Leaders podcast recently, and Scott Keller shared something that stopped me mid-stride: the six-word story exercise. His example was the famous Ernest Hemingway line (though its true authorship is debated): "For sale: baby shoes. Never worn." Six words. An entire world of heartbreak, hope deferred, a nursery that stayed empty. I must have read that sentence three times, feeling the weight of everything left unsaid. And then Keller posed the challenge: What's your six-word leadership story? I sat with my notebook open. Pen ready. And... nothing. The power of constraint There's something almost unfair about this exercise. Six words feels impossibly small. I've written mission statements, vision documents, strategic plans that span pages. I've crafted carefully worded emails, given presentations with dozens of slides. Six words? But that's exactly the point. When you have six words, you can't hide behin...

Github Copilot on the command line (continued)

Yesterday I started exploring the Github Copilot CLI. Turned out that there was more to talk about than what would be good fit for one blog post. So here is a continuation of my previous post. In case you missed, go read that post first before continuing here. Ready? Let's dive in again! Let’s explore some features Switching between models The Github Copilot CLi was using Claude Code in my previous examples. I don’t know if that is the default or that there was a specific reason that this model was used by the CLI but you can easily switch between models through the /model command. Hit enter to get a list of available models: Select a mode and hit enter: Extensibility with MCP servers Copilot CLI ships with the GitHub MCP (Model Context Protocol) server built-in, enabling repository interactions and issue searches. But you can extend it further by adding any MCP server from the registry using /mcp . Want to integrate Playwright for browser testing? Need to connect ...