Avoid Excessive Database Growth for Git-TFS Users

June 5, 2017

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...
no comments

Recovering Deleted Branches/Commits In Git-TFS

May 29, 2017

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 FROM .. ORDER BY InternalRepositoryId   2) Search the deleted branch in the reflog using the following query: SELECT DISTINCT...
no comments

Everything you wanted to know about Git

March 19, 2017

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, Leon Jalfon   PDF: EverythingYouWantedToKnowAboutGit.pdf  
no comments

JFrog Artifactory – Move Filestore from One Drive to Another

March 12, 2017

A few days ago I was asked to move all the artifacts stored on the Artifactory server from the “C:\” drive to the “E:\” drive. I went to the official documentation but I didn't find exactly what I was looking for. There explain how to specify where to save the artifacts when configuring the server but not how to do it on an existing server. Here are the steps to follow to achieve it:   1) Get the ARTIFACTORY_HOME path: .    • Open PowerShell and run the command: .          • Get-ChildItem Env:   2) Search for the file “binarystore.xml” .    • In...
no comments

Meeting the TFS Aggregator

February 23, 2017

The TFS Aggregator is undoubtedly one of the most known and most useful tools for TFS. This comes to fill all the needs that can’t be covered using the traditional work item rules. Basically allows you to execute your own rules after each save.   Installation and Deployment The TFS Aggregator is an open source project stored in https://github.com/tfsaggregator/tfsaggregator. You can download the code and deploy it by yourself or simply use the installer provided by the project. The installer will detect your TFS version and install for you the console app and the plugin.   How the Plugin Works? A TFS Plugin is a...
no comments

Publish a Plugin in Jenkins Site

January 25, 2017

Being an open source project might think that would be enough with a couple of clicks to upload your plugin to Jenkins but nothing is further from reality. To publish a plugin in Jenkins site we must go through a series of steps that are not entirely intuitive to people who are not related to development tools like Jira and GitHub.   Step 1: Create a GitHub Account (or use an existent account) 1) Go to https://github.com/ and click “Sign Up” 2) Fill the form and click “Create Account”   Step 2: Create a GitHub Repository (must be public) to store your plugin source code 1) Sign In...

Connect to Linux Machine Using Windows Remote Desktop

1) Access to the Linux machine and open the terminal (Ctrl+Alt+T)   2) Update the apt and install xrdp using the following command: - -> sudo apt-get update   3) Install xrdp using the following command: --> sudo apt-get install xrdp –y   4) Install xfce4 with the command below: --> sudo apt-get install xfce4 –y   5) Run the following command to make sure xRDP uses xfce4 (step 1 of 2): --> echo xfce4-session >~/.xsession   6) Run the following command to make sure xRDP uses xfce4 (step 2 of 2): --> sudo nano /etc/xrdp/startwm.sh   7) Add the following line before the last line of the file --> startxfce4   8) Then, click “Ctrl+X”, click “Y” and...
no comments

Deploying Git Client-Side Hooks

January 24, 2017

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...

Create Your Own Linux Command

Create your custom command in Linux is very simple. I will take a specific case and use it to explain the process. I have a Linux machine which is used as a Jenkins slave that is configured to work with windows slaves. I can’t change this configuration so my workaround is replace the command “C:\Program File\Git\cmd\git.exe” for the “git” command. To achieve this I’ll create a command called “C:\Program File\Git\cmd\git.exe” that will be used to run git commands.   1. Create a Bash Script which will run your command   2. Make the command executable   3. Copy your script to the path “/usr/bin”   4. Test your new Linux...

Jenkins “Poll SCM” the Nightmare for Performance

How many of us have ever used the "Poll SCM" option in our Jenkins jobs? It’s very easy to simply say to our job "hey can you please verify every X time my repository and trigger the job only in case there are any changes" At first glance it’s a simple, quick and harmless way. And the most important, it’s an easy method and works well. However, have we ever wondered what this represents for our server? What is the cost of this "comfort"? Probably not, what is sure is that every time that the server get slow we quickly complain and...
no comments