Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EGit / JGit » bare repository
bare repository [message #888044] Sun, 17 June 2012 15:39
Missing name Missing name is currently offline Missing name Missing nameFriend
Messages: 1
Registered: June 2012
Junior Member
For testing purpose I am trying to create a local bare repository like this:

        FileRepositoryBuilder builder = new FileRepositoryBuilder();
        Repository repository = builder.setGitDir(new File(remotePath))
                .readEnvironment() // scan environment GIT_* variables

Of course when I try to clone I get an exception:

org.eclipse.jgit.api.errors.JGitInternalException: Invalid remote: origin

I have probably to create a local emtpy repo then add a remote then push and then pull:

git init
git remote add origin remotepath
git pull origin master

What is the correct way to do this in jgit??


Previous Topic:gitolite, on egit failes, on bash works, frustration lvl rising
Next Topic:core.autocrlf=true still buggy with 2.0.0-rc2
Goto Forum:

Current Time: Fri Apr 03 18:33:56 GMT 2020

Powered by FUDForum. Page generated in 0.03013 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top