Unable to create a new branch (SOLVED)

Hi,

I’m new to Defold and I just installed it on my macOS (version El Capitan, 10.11.6)

While trying to open any new project I’m unable to create new branch.
Here’s console’s event error details:

com.dynamo.cr.client.RepositoryException: Unable to create branch
at com.dynamo.cr.client.LocalProjectClient.createBranch(LocalProjectClient.java:101)
at com.dynamo.cr.editor.wizards.ConnectionWizardBranchPagePresenter$CreateBranchRunnable.run(ConnectionWizardBranchPagePresenter.java:70)
at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121)
Caused by: java.io.FileNotFoundException: /Users/nnexus/.defold/.netrc (No such file or directory)
at java.io.FileOutputStream.open(Native Method)
at java.io.FileOutputStream.(FileOutputStream.java:206)
at java.io.FileOutputStream.(FileOutputStream.java:156)
at java.io.FileWriter.(FileWriter.java:90)
at com.dynamo.server.dgit.CGit.updateNetRC(CGit.java:66)
at com.dynamo.server.dgit.CGit.execGitCommand(CGit.java:82)
at com.dynamo.server.dgit.CGit.cloneRepo(CGit.java:148)
at com.dynamo.cr.branchrepo.BranchRepository.createBranch(BranchRepository.java:120)
at com.dynamo.cr.client.LocalProjectClient.createBranch(LocalProjectClient.java:99)
… 2 more

I’m figuring out that the missing directory path “/Users/nnexus/.defold/.netrc” could be the problem?

I have tried installing the whole folder to Applications and home directory. Plus naming the folder plain “Defold”.

Any ideas how to go forward?

Thanks!

Can you check wether you have any whitespace in your path. Defold have had problems with these in the paths.

1 Like

Checked, but did not find any whitespaces.

Hmm, do you have a .defold/.netrc file in your user home directory? Mine looks like this:

machine cr.defold.se login bjorn.ritzl@king.com password <access-key-from-dashboard>

No, I don’t have that, I thought that would be the root problem.
Should I have some sort of access key in my home directory?

No, at least not nothing you need to create yourself. You should get a Google signin window when you chose to Open Project from the menu. Did you get that?

I wonder if this might be a problem with permissions in your home directory - if Defold might be unable to create that file.

Yes, I got the Google’s login screen and I am able see and select a project in dashboard what is shared to me.

That’s it! The problem was in my home directory permissions. After I added more writing priviledges on it I was able to create a new branch.

Thank you!

2 Likes