In this lecture, we will configure a GitLab MCP server, which will later allow us to do actions that
the cursor agent can normally do.
But before we can get there, there is a bit of configuration to be done.
So hang on tight.
I'm here at the website called Cursor Directory and I already selected here from the menu MCP.
And I'm seeing here in the list GitHub.
And I'm going to click on it in a second.
But just in case you cannot find GitHub, simply search here for GitHub and you should go to this page.
And then we're going to click here on the installation instructions.
Whatever is here below is not interesting for us.
This is going to take us to a GitHub page.
And currently this repository is deprecated.
So we're going to go to this link.
And then finally we're going to find here the GitHub MCP server.
And this explains some of the use cases.
So when it makes sense to use this MCP.
But first of all there are a few steps that we need to do.
So first of all we're going to start with everything that is here inside the list.
And the first item that we have on the list is having.
Docker installed.
If you don't have Docker installed, go to docker.com and download Docker Desktop.
It's free for a personal plan and it's relatively easy to do.
After the installation, I highly recommend doing a restart of your computer, but when Docker Desktop
is running, it should look similar to this.
And right here at the bottom it should say engine running.
So this is how you know that Docker is now installed on your computer.
This is a very nice tool for development purposes because it allows you to run everything in an isolated
environment.
So once we are done with that and have ensured that Docker is running, we still need to do point number
three, which is to create a GitHub personal access token.
So we can click on this particular link here and open up a new page.
It's gonna ask us to create a personal access token, which is like a temporary password that we're
going to need inside cursor to be able to do some actions and go ahead and call this GitHub MCP so that
we know why we have created this.
I'm going to select a relatively short expiration date, but feel free to leave the default of 30 days.
And apart from this we're going to select here the repository access.
And this is going to be very very narrow.
We're going to select only a specific repository.
And this is the repository with a flashcard.
Now apart from this in terms of repository permissions there are a few things that we want to enable.
So we're going to expand this part.
And there are a few things that we want to have access to.
One of them is contents.
I'm going to set it to read and write.
But just as well we can set it to issues.
And later on, in case you need anything else that doesn't work, feel free to go back to this configuration
and set up the right tokens that you need.
I'm going to go ahead and generate this token, and this is going to be displayed here in case you need
to create another token.
This particular token is never going to be shown again, so you need to delete this token and go through
the process once again.
But in terms of that now we also have this token.
Keep this page open.
And we're going to go to the next part which is the installation itself.
And this is relatively simple.
We're not going to use the example here with VSCode.
Instead we're going to scroll a bit further down.
And we're going to take a look at this particular setup here with MCP servers.
We're going to copy this contents and then go inside cursor and make sure we click on cursor and not
inside the rules.
Create a new file which is called m dot JSON.
And we're going to paste here this contents.
And then we're going to save it.
Afterwards we want to make sure that this setup is correct.
So we're going to click here on the gear icon go to MCP and we're going to see here GitHub.
And this appears to be enabled.
So I'm going to refresh here and we're going to see here this particular setup.
Now there's one more thing we need to do.
And this is to specify our GitHub personal access token.
Otherwise this will not work properly.
And this is also the reason why we have created this fine grained personal access token.
So I'm going to click on copy here.
Go inside our configuration paste it here.
So now we have it apart from this want to make sure that this particular file is added to the.
Gitignore.
So I'm gonna copy it here inside the chat and say add to.
Gitignore.
Once we're done with that it's pretty much everything that we need to do at this stage in terms of adding
this MCP server.
You're taking a look at Docker Desktop.
We're going to see here that there is a container running.
So this is pretty much the MCP server running on your own machine.
And this is needed to make this bridge between AI agent and GitHub.