The .gitignore file is used to prevent Git to tracking certain files (namely ensure that certain files not tracked by Git remain untracked), for example test outputs, logs and build files.
The best practice is to create this file when the repository is created, however in most cases, this file is created after detecting that unwanted files are being stored.
The files/folder that already are in the repository will not just delete themselves just because you added them to the gitignore file. Remember, the .gitignore file ignores only files that are not tracked.
To resolve the problem remove from...
Let’s see some tips to avoid the excessive growth of the database if you are using Git in TFS...
Keep in mind that in Git-TFS there is not “git gc” implemented in the server side
This means that once you push a change to the database it will remain in the database forever (yes, forever). The only way to remove it is to delete the whole repository
Nevertheless this fact allows us to recover at any moment any thing that we have deleted (see how here)
Avoid to push the same...
In Git TFS there is not “git gc” implemented in the server side. At first sight this can be a big problem because once you push a change to the database it will remain in the database forever (yes, forever). The only way to remove it is to delete the whole repository. Nevertheless this fact allows us to recover at any moment any thing that we have deleted. Let’s see how achieve this…
1) Get the Internal Repository ID:
SELECT Name, InternalRepositoryId
ORDER BY InternalRepositoryId
2) Search the deleted branch in the reflog using the following query:
Last Wednesday 15/03/17 I gave a talk about Git in Microsoft Raanana as part of the ALM User Group. People generally learn how to use Git but don’t really understand it so this time the idea was to answer the most frequently asked questions, give a couple of tips and explain Git from another point of view.
Many thanks to all for coming and I hope you enjoyed it as much as I did. If you have any questions, you know how to contact me.
See you next time,
First of all let’s define what Git hook is. Like a Git documentation explain Git hooks is a “way to fire off custom scripts when certain important actions occur”. There are two kinds of hooks: “client-side” and “server-side”. In this post we will talk about how we can deploy our client-side hooks in the simplest way possible.
When you think about client-side hooks there are two main issues to think about:
1) If a developer delete the repository and clone it again, how can he add the hooks again?
2) If a developer creates a new repository how can he add the...
Many times we have the need to store our project in GitHub because we want (or need) to be open source but still want to keep the capabilities offered by TFS/VSTS. Other times we need to give access to our repository to a person who can’t have (or that we don’t want to give) access to our TFS/VSTS server.
In these cases we can resolve the problem synchronizing our TFS/VSTS repository with our GitHub (public or private) repository. At first glance it may sound like a complicated process but it’s easier than you expect.
You can perform the synchronization manually (using pull/push)...