Tag: java

.pack file from git repo can't be deleted using File delete() method

For this method I am writing, I am cloning a git repo using the jgit library, then doing some stuff with those files, then finally I want to delete the repo. The problem I’m having is that when I call the delete() method on a .pack file (located in .git\objects\pack), it can’t be deleted. All […]

How to Check if A Git Clone Has Been Done Already with JGit

I learning git and using JGit to access Git repos from java code. Git by default does not allow to clone to a non-empty directory. How do we figure out that a git clone has already been done for a particular git repo in the local machine so that we can only do a Git […]

How to add eclipse project to existing git repo?

I already have an existing project in Eclipse that I want to add to my team’s github repo. The github repo is empty right now. What’s the best way to add this project to our github repo? I was thinking of git cloneing our repo into the workspace folder (parent to the project in question) […]

Configuring Jenkins with Bitbucket

I seem to have got stuck trying to link Jenkins (an EC2 AWS instance of Ubuntu) with Bitbucket. Whenever I try to build my project (I’ve installed the git plugin on Jenkins) I get… Building in workspace /var/lib/jenkins/jobs/Google adwords/workspace Checkout:workspace / /var/lib/jenkins/jobs/Google adwords/workspace – hudson.remoting.LocalChannel@2c473996 Using strategy: Default Cloning the remote Git repository Cloning repository […]

using git with apache sshd

I’m trying to use msysgit over an SSH server I wrote in Java using sshd and I have made great progress in that i got past some git errors, I am able to connect using putty and get a shell, I have git in my windows path, but I still can’t actually use git to […]

File diff against the last commit with JGit

I am trying to use JGit to get the differences of a file from the last commit to the most recent uncommitted changes. How can I do this with JGit? (using the command line would be the output of git diff HEAD) Following several discussions (link1, link2) I come with a piece of code that […]

Sonarqube: Missing blame information for the following files

I am getting the warning Missing blame information for the following files during analysis by SonarQube. [INFO] [22:19:57.714] Sensor SCM Sensor [INFO] [22:19:57.715] SCM provider for this project is: git [INFO] [22:19:57.715] 48 files to be analyzed [INFO] [22:19:58.448] 0/48 files analyzed [WARN] [22:19:58.448] Missing blame information for the following files: (snip 48 lines) [WARN] […]

Eclipse with EGit, git-blame info is hard to see

using Eclipse Indigo Service Release 2, with EGit plugin and JDK 1.7. I’ve seen that it should support blame annotations, but I can’t get it to show like I see here on Eclipse Wiki. Here’s how it looks for me, you can’t see the pointer but I’m hovering over the vertical brown line: Anyone know […]

How to accommodate multiple coding styles? (git vs. IDE)

I am collaborating on a git-sourced, maven-managed Java project with differing code styling preferences with users using multiple IDE’s (note 1). Is there a tool or IDE configuration that will allow code to be viewed and edited using style-1, but committed to SCM using style-2? My research points me to ‘no’, but a solution combining […]

This compilation unit is not on the build path of a Java project

When I try to use ctrl+space this error is shown: This compilation unit is not on the build path of a Java project. I see that there are similar topics but my work environment is Eclipse and i pull my project from Git (I import project as general project) and i use Apache Ant. Can […]

Git Baby is a git and github fan, let's start git clone.