6

I nearly spent two or three hours and searched my ass of. But either i am to dumb to find a solution or there is none so far.

First thing: i am not a pro in the linux world, but here is what i got.

Bare debian 8.5.0 installation as a VirtualBox image:

I installed sudo, VBoxGuestAdditions, nodejs (v6.2.1), git, and the foundation-cli(v6).

So, now if i am trying to create a new foundation project with "foundation new" and select the "ZURB-template"-option, the installation fails with the errors below.

npm ERR! git rev-list -n1 4.0: fatal: ambiguous argument '4.0': unknown revision or path not in the working tree.
npm ERR! git rev-list -n1 4.0: Use '--' to separate paths from revisions, like this:
npm ERR! git rev-list -n1 4.0: 'git <command> [<revision>...] -- [<file>...]'
npm ERR! git rev-list -n1 4.0:
npm ERR! git rev-list -n1 4.0: fatal: ambiguous argument '4.0': unknown revision or path not in the working tree.
npm ERR! git rev-list -n1 4.0: Use '--' to separate paths from revisions, like this:
npm ERR! git rev-list -n1 4.0: 'git <command> [<revision>...] -- [<file>...]'
npm ERR! git rev-list -n1 4.0:
npm ERR! git clone --template=/home/dev/.npm/_git-remotes/_templates --mirror git@github.com:gulpjs/gulp-cli.git /home/dev/.npm/_git-remotes/git-github-com-gulpjs-gulp-cli-git-15c23bd3: Cloning into bare repository '/home/dev/.npm/_git-remotes/git-github-com-gulpjs-gulp-cli-git-15c23bd3'...
npm ERR! git clone --template=/home/dev/.npm/_git-remotes/_templates --mirror git@github.com:gulpjs/gulp-cli.git /home/dev/.npm/_git-remotes/git-github-com-gulpjs-gulp-cli-git-15c23bd3: Permission denied (publickey).
npm ERR! git clone --template=/home/dev/.npm/_git-remotes/_templates --mirror git@github.com:gulpjs/gulp-cli.git /home/dev/.npm/_git-remotes/git-github-com-gulpjs-gulp-cli-git-15c23bd3: fatal: Could not read from remote repository.
npm ERR! git clone --template=/home/dev/.npm/_git-remotes/_templates --mirror git@github.com:gulpjs/gulp-cli.git /home/dev/.npm/_git-remotes/git-github-com-gulpjs-gulp-cli-git-15c23bd3:
npm ERR! git clone --template=/home/dev/.npm/_git-remotes/_templates --mirror git@github.com:gulpjs/gulp-cli.git /home/dev/.npm/_git-remotes/git-github-com-gulpjs-gulp-cli-git-15c23bd3: Please make sure you have the correct access rights
npm ERR! git clone --template=/home/dev/.npm/_git-remotes/_templates --mirror git@github.com:gulpjs/gulp-cli.git /home/dev/.npm/_git-remotes/git-github-com-gulpjs-gulp-cli-git-15c23bd3: and the repository exists.

Maybe i am missing something essential here, so don't hessitate to give me even the simplest advices. If i faild to do a correct search on this or was to dumb to get the solution even when it was in front of me, just sry :D

/edit

Small Update: I found an installation of a bunsenlabs vm (former crunchbang) on my computer which is based on debian. Here the installation and creation of a foundation project works like charm.

so i thought, let's install a new vm with bunsenlabs and try this again. Because it worked on the old installation it sould work on the new one, right? WRONG... I can't get my head around this problem. I'm pretty sure i didn't do anything special on the old installation...

Bodo Dackel
  • 93
  • 10

3 Answers3

7

We ran into this issue as well and came up with the same solution as Jeff. Here are step by step if anyone with less experience is looking for more direction:

  1. Edit package.json file, under devDependencies change "gulp": "gulpjs/gulp#4.0”, to "gulp": "gulpjs/gulp”, and "gulp-cli": "gulpjs/gulp-cli#4.0” to "gulp-cli": "gulpjs/gulp-cli” (removing the #4.0 seems to help)
  2. Run npm install
  3. If needed run npm install graceful-fs (to be on the 4.x branch)
  4. Run npm install –g "gulpjs/gulp#4.0”
  5. Run npm install "gulpjs/gulp#4.0” (to ensure your local environment will use the 4.0 branch)
  6. Gulp –v (to ensure your local environment is using the 4.x branch)
  7. Run gem install sass
  8. Run bower install
  9. Run npm rebuild node-sass
  10. Run npm start
  11. Use sudo where necessary

Cheers

  • thank you for your very detailed way of showing how to do this. now everything works fine and finally i can start working on what i was planing. – Bodo Dackel Jun 17 '16 at 09:18
  • Thank you for the only solution I've been able to find. Is there a way to create a fix for this upstream or more permanently so that the next `foundation new` doesn't require the same effort? – visyoual Jun 23 '16 at 17:53
  • Thank you so much. You are a savior. Removing #4.0 did the job. – Rajender Joshi Aug 11 '16 at 08:40
0

I don't know why this worked for me, but try installing babel-register:

npm i babel-register
tomcwatts
  • 1
  • 1
  • thank you for your suggestion, sadly this doesn't solve the problem for me. I'm still getting the errors like nothing has changed. – Bodo Dackel Jun 16 '16 at 09:10
0

I had the same problem and was able to fix it with this:

Removing grunt-cli version from npm config fixes the issue. Packjage json should have grunt-cli line like this:

{
...
"devDependencies": {
...
"gulp-cli": "gulpjs/gulp-cli",
...
},
...
}
  • thank you, that did the trick. I had to do it with the more detailed answer from @AurariaLibrary but you were basicliy right. – Bodo Dackel Jun 17 '16 at 09:15