tag:support.appharbor.com,2010-11-23:/discussions/problems/60449-git-binary-in-command-lineAppHarbor: Discussion 2016-08-11T00:43:50Ztag:support.appharbor.com,2010-11-23:Comment/337574212014-07-13T21:16:17Z2014-07-13T21:16:17ZGit binary in command line<div><p>Hi,</p>
<p>We're working on a new feature that'll allow better control of
the build process. This will also allow you to include for instance
git for package restore when you run your builds.</p>
<p>For now though, it might be a reasonable stop-gap to just
include the git executable in your repository so you can use it
during the build. Have you tried doing that?</p>
<p>Best,<br>
Rune</p></div>runetag:support.appharbor.com,2010-11-23:Comment/337574212014-07-14T06:37:34Z2014-07-14T06:37:50ZGit binary in command line<div><p>Yes I did, as you can see from the repository (from with
appharbor build are run)<br>
<a href=
"https://github.com/XVincentX/NodeVStudio">https://github.com/XVincentX/NodeVStudio</a></p>
<p>Look at packages.json (git bin redirect) and tools folder. But
looks like not working anyway</p></div>XVincentXtag:support.appharbor.com,2010-11-23:Comment/337574212014-07-14T08:10:18Z2014-07-14T08:10:18ZGit binary in command line<div><p>Alright, actually git has been installed on the build servers in
the meantime, so perhaps you want to give it another shot. Let me
know how it works out.</p>
<p>Best,<br>
Rune</p></div>runetag:support.appharbor.com,2010-11-23:Comment/337574212014-07-14T08:20:09Z2014-07-14T08:20:09ZGit binary in command line<div><p>Hello,<br>
the git command looks like available now.<br>
However bower package restore is failing due to this error.</p>
<p>bower angular#~1.2.17 ECMDERR Failed to execute "git ls-remote
--tags --heads
<a>git://github.com/angular/bower-angular.git&quot</a>;, exit
code of #128</p>
<p>(works on my machine and mu build server)</p></div>XVincentXtag:support.appharbor.com,2010-11-23:Comment/337574212014-07-14T21:28:06Z2014-07-14T21:29:19ZGit binary in command line<div><p>Hmm ok - I guess there could be few reasons this'd happen.
Perhaps you can try and set <code>GIT_TRACE=1</code> in the command
line where bower/git is run. That should generate some more usable
output. Also <a href=
"http://stackoverflow.com/questions/9610131/how-to-check-the-validity-of-a-remote-git-repository-url">
see this discussion</a>.</p>
<p>There are also a few issues related to the length of the node
modules path (at least on my machine). I'm not sure if that's also
going to be an issue on AppHarbor though. The <a href=
"https://github.com/joyent/node/issues/6960#issuecomment-46704998">issues
around this have been discussed here</a>, but we're also working on
a workaround for node builds on AppHarbor.</p>
<p>By the way <a href=
"https://github.com/XVincentX/NodeVStudio/blob/master/NodeVStudio/NodeVStudio/bower.json#L10">
the URL to your app here is a bit off</a> - should be
<code>apphb</code> instead of <code>appharbor</code>.</p></div>runetag:support.appharbor.com,2010-11-23:Comment/337574212014-07-14T21:56:46Z2014-07-14T21:56:46ZGit binary in command line<div><p>Hello,<br>
even using your command, the error is the same</p>
<p>ECMDERR Failed to execute "git ls-remote --tags --heads
<a>git://github.com/angular/bower-angular.git&quot</a>;, exit
code of #128</p>
<p>Googling on the internet, it Looks like an error due to port
forwarding for git protocol port.<br>
About length of node_modules path, it happens only when removing
that folder and I managed it using a robocopy script (have a look
here: <a href=
"http://www.dotnet-programming.com/post/2014/07/11/Integrate-NodeJS-tools-in-Visual-StudioTFS.aspx">
http://www.dotnet-programming.com/post/2014/07/11/Integrate-NodeJS-...</a>)</p></div>XVincentXtag:support.appharbor.com,2010-11-23:Comment/337574212014-07-16T00:19:54Z2014-07-16T00:19:54ZGit binary in command line<div><p>Hmm ok so git is just installed with the default configuration.
Did you have to set anything up locally to configure port
forwarding?</p>
<p>Also where did you find out that it was related to port
forwarding?</p>
<p>Best,<br>
Rune</p></div>runetag:support.appharbor.com,2010-11-23:Comment/337574212014-07-16T11:25:59Z2014-07-16T11:25:59ZGit binary in command line<div><p>Hello again,<br>
I have default git installation too.</p>
<p>I made other searches and looks like error 128 can happens for a
lot of motivations:<br>
<a href=
"http://stackoverflow.com/questions/22723345/strange-bower-git-error-error-code-128-could-not-chdir-to-y">
http://stackoverflow.com/questions/22723345/strange-bower-git-error...</a></p>
<p>Looks like it can work forcing git to get always from https
protocol instead of git</p></div>XVincentXtag:support.appharbor.com,2010-11-23:Comment/337574212014-07-17T09:06:24Z2014-07-17T09:06:24ZGit binary in command line<div><p>Ok got it. Did you try doing that (using HTTPS over the git
protocol)?</p>
<p>I think we'll have to look further into this when we have the
new feature ready that'll allow greater control over the build
process (the feature I referred to in the beginning).</p>
<p>It'll likely be another few weeks and when it's ready you can
essentially run a regular command line/batch script as part of the
build process. That'll (along with some other tools) will make it
easier to create build scripts for node applications.</p>
<p>I suspect that building the node app and running Bower as part
of a Visual Studio solution file might add some extra complexity,
and in particular it seems to make it more difficult to get the
output we'd need to accurately determinate why "error 128" crops
up.</p>
<p>Best,<br>
Rune</p></div>runetag:support.appharbor.com,2010-11-23:Comment/337574212014-07-17T09:18:11Z2014-07-17T09:18:11ZGit binary in command line<div><p>I tried to force on https with git config but issue remains.<br>
I tried to force it on each build with git config command, but
looks like I have no permissions</p>
<pre>
<code> git config url."https://".insteadOf git://
fatal: Cannot change to 'D:/temp/zc4fiyyp.14d/..': Permission denied</code>
</pre>
<p>For info, I have no problem with TFS and local MsBuild.<br>
I hope to get news from you with a resolution!<br>
V.Chianese</p></div>XVincentXtag:support.appharbor.com,2010-11-23:Comment/337574212014-07-18T02:13:30Z2014-07-18T02:13:51ZGit binary in command line<div><p>Hmm ok. I'll let you know when the new customizable build
process is in place, and we can give this another shot. If you
figure out a solution in the meantime I'd love to hear what the
issue is/was.</p>
<p>Best,<br>
Rune</p></div>rune