Tag: java

build spring framework source code encounter an error

I fetched the spring framework source code from github by using git clone command. When I build the source code by using gradle build in the source code directory,it takes a long time to download dependencies and compile the java code,but failed with an exception.The output is below. :spring-webmvc-portlet:sourcesJar UP-TO-DATE :spring-webmvc-tiles2:javadoc SKIPPED :spring-webmvc-tiles2:javadocJar SKIPPED :spring-webmvc-tiles2:sourcesJar […]

Putting version file into EAR or WAR using Maven

My firm is trying to find a way to put some type of version file or versioning on a EAR and or WAR using Maven. What we need is as we do the Maven Build is to take a version number out of a file and somehow put it into a EAR or WAR or […]

Switching branches with IntelliJ & Git

this should be an easy one… I’m trying IntelliJ (came from Eclipse) and I have this issue that I don’t know how to handle, I have configured my project using the branchA no problems, but, as soon a try to checkout another branch branchB the IDE tells me that fails due some untracked file that […]

Subversion or Mercurial SPI – What API shall a server implement?

I’m trying to evaluate a product idea that (besides the main, non-disclosed functionality) would provide a “revision control”-style secondary view of the content/changes. I expect many users, and I wouldn’t create real repositories, I would like to store my internal data as I see fit – I would like to just emulate the Subversion or […]

Can a Git Repository Branch be a sub folder in some other Git Repository?

Can a Git Repository Branch be a sub folder in some other Git Repository? What I mean by this is if I am working in a git repository called “webdesign” and it has a branch called “JSP” can I somehow map a folder in my “project-a” repository to add the branchs. I would like to […]

Including .jar files in Github for consistency

I am new to using github and have been trying to figure out this question by looking at other people’s repositories, but I cannot figure it out. When people fork/clone repositories in github to their local computers to develop on the project, is it expected that the cloned project is complete (ie. it has all […]

Trying to download an exe file from a website and run it

I am having trouble downloading an exe file from a server and running it. specifically downloading git and installing it automatically. I found some code on another question that isn’t quite working, and I don’t know why. The parameters I pass it are: URL url = new URL(“http://git-scm.com/download/win”); String fileName = “C:/SETUP/gitinstall.exe”; Am thinking maybe […]

How to hard reset from one git branch to other in JGit?

I have two branches one is master and another one level1. Now level1 is the latest I need to hard reset master to level1 normally in git bash I can do that by following command. $ git checkout master $ git tag old-master-branch $ git reset –hard level1 $ git merge -s ours origin/master $ […]

JGit create new local branch and push to remote (branch does not exist on remote)

I’m working on an ANT task that calls some java that uses JGit to create a new branch on a git repository and push it to remote. I’m using JGit 2.1.0. Here’s the code: CreateBranchCommand bcc; CheckoutCommand checkout; Git git; try { Repository repo = new FileRepositoryBuilder().readEnvironment().findGitDir(src).build(); git = new Git(repo); bcc = git.branchCreate(); checkout […]

git clone does not work in java

I am using jgit to clone a repository of using java code. I am able to clone to a local (windows) machine when testing, but unable to clone to a aws server. Folder is not created in local path. I am creating the clone under /tmp/loc/$proName. I gave 777 to the loc folder, but not […]

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