Menu icon Foundation
Issue Creating New Foundation 5 Site

Hi Everyone,

I've looked through the forum already and haven't seen an answer to my issue. I'm trying to create a new Compass based Foundation 5 site after following the instructions for installing bower and the Foundation gem.

Here are the commands I had to run to get everything installed on my system:

$ sudo npm install -g bower
* * * ("installs "stuff") * * *

$ gem install foundation
ERROR: While executing gem ... (Gem::FilePermissionError)
You don't have write permissions into the /Library/Ruby/Gems/1.8 directory.

* * * (grrr!) * * *

$ sudo gem install foundation
Successfully installed foundation-1.0.1
1 gem installed
Installing ri documentation for foundation-1.0.1...
Installing RDoc documentation for foundation-1.0.1...

* * * (Yay!) * * *

Now, when I try to create a new site, I get the following...

$ foundation new foundation5default
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require': /Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:27: syntax error, unexpected ':', expecting kEND (SyntaxError)
option :libsass, type: :boolean, default: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:28: syntax error, unexpected ':', expecting kEND
option :version, type: :string
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:32: syntax error, unexpected ':', expecting ')'
run("gem install compass", capture: true, verbose: false)
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:32: Can't assign to true
run("gem install compass", capture: true, verbose: false)
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:32: syntax error, unexpected ':', expecting '='
run("gem install compass", capture: true, verbose: false)
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:33: syntax error, unexpected ':', expecting ')'
... run("rbenv rehash", capture: true, verbose: false) if whic...
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:33: Can't assign to true
..."rbenv rehash", capture: true, verbose: false) if which("rbe...
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:33: syntax error, unexpected ':', expecting '='
...hash", capture: true, verbose: false) if which("rbenv")
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:56: syntax error, unexpected ':', expecting ')'
run("gem install compass", capture: true, verbose: false)
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:56: Can't assign to true
run("gem install compass", capture: true, verbose: false)
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:56: syntax error, unexpected ':', expecting '='
run("gem install compass", capture: true, verbose: false)
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:57: syntax error, unexpected ':', expecting ')'
... run("rbenv rehash", capture: true, verbose: false) if whic...
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:57: Can't assign to true
..."rbenv rehash", capture: true, verbose: false) if which("rbe...
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:57: syntax error, unexpected ':', expecting '='
...hash", capture: true, verbose: false) if which("rbenv")
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:64: syntax error, unexpected ':', expecting kEND
run "git clone #{repo} #{name}", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:64: Can't assign to true
run "git clone #{repo} #{name}", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:64: syntax error, unexpected ':', expecting '='
run "git clone #{repo} #{name}", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:67: syntax error, unexpected ':', expecting kEND
run "bower install", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:67: Can't assign to true
run "bower install", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:67: syntax error, unexpected ':', expecting '='
run "bower install", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:68: syntax error, unexpected ':', expecting kEND
run "git remote rm origin", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:68: Can't assign to true
run "git remote rm origin", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:68: syntax error, unexpected ':', expecting '='
run "git remote rm origin", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:79: syntax error, unexpected ':', expecting kEND
option :version, type: :string
^
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `require'
from /Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli.rb:2
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `require'
from /Library/Ruby/Gems/1.8/gems/foundation-1.0.1/bin/foundation:3
from /usr/bin/foundation:19:in `load'
from /usr/bin/foundation:19

A 10 minute search found nothing that helped, so I'm asking here. What am I missing or doing wrong?

I'm using OS X 10.8.5 with Ruby 1.8.7 (2012-02-08 patchlevel 358) [universal-darwin12.0], Node v0.10.15, Homebrew 0.9.4 and I'm sure some other stuff that would be helpful to know that I can't remember right now.

Thanks in advance for any help that you can provide.

installrubybowerFoundation 5nodejs

Hi Everyone,

I've looked through the forum already and haven't seen an answer to my issue. I'm trying to create a new Compass based Foundation 5 site after following the instructions for installing bower and the Foundation gem.

Here are the commands I had to run to get everything installed on my system:

$ sudo npm install -g bower
* * * ("installs "stuff") * * *

$ gem install foundation
ERROR: While executing gem ... (Gem::FilePermissionError)
You don't have write permissions into the /Library/Ruby/Gems/1.8 directory.

* * * (grrr!) * * *

$ sudo gem install foundation
Successfully installed foundation-1.0.1
1 gem installed
Installing ri documentation for foundation-1.0.1...
Installing RDoc documentation for foundation-1.0.1...

* * * (Yay!) * * *

Now, when I try to create a new site, I get the following...

$ foundation new foundation5default
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require': /Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:27: syntax error, unexpected ':', expecting kEND (SyntaxError)
option :libsass, type: :boolean, default: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:28: syntax error, unexpected ':', expecting kEND
option :version, type: :string
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:32: syntax error, unexpected ':', expecting ')'
run("gem install compass", capture: true, verbose: false)
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:32: Can't assign to true
run("gem install compass", capture: true, verbose: false)
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:32: syntax error, unexpected ':', expecting '='
run("gem install compass", capture: true, verbose: false)
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:33: syntax error, unexpected ':', expecting ')'
... run("rbenv rehash", capture: true, verbose: false) if whic...
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:33: Can't assign to true
..."rbenv rehash", capture: true, verbose: false) if which("rbe...
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:33: syntax error, unexpected ':', expecting '='
...hash", capture: true, verbose: false) if which("rbenv")
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:56: syntax error, unexpected ':', expecting ')'
run("gem install compass", capture: true, verbose: false)
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:56: Can't assign to true
run("gem install compass", capture: true, verbose: false)
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:56: syntax error, unexpected ':', expecting '='
run("gem install compass", capture: true, verbose: false)
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:57: syntax error, unexpected ':', expecting ')'
... run("rbenv rehash", capture: true, verbose: false) if whic...
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:57: Can't assign to true
..."rbenv rehash", capture: true, verbose: false) if which("rbe...
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:57: syntax error, unexpected ':', expecting '='
...hash", capture: true, verbose: false) if which("rbenv")
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:64: syntax error, unexpected ':', expecting kEND
run "git clone #{repo} #{name}", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:64: Can't assign to true
run "git clone #{repo} #{name}", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:64: syntax error, unexpected ':', expecting '='
run "git clone #{repo} #{name}", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:67: syntax error, unexpected ':', expecting kEND
run "bower install", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:67: Can't assign to true
run "bower install", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:67: syntax error, unexpected ':', expecting '='
run "bower install", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:68: syntax error, unexpected ':', expecting kEND
run "git remote rm origin", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:68: Can't assign to true
run "git remote rm origin", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:68: syntax error, unexpected ':', expecting '='
run "git remote rm origin", capture: true, verbose: false
^
/Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli/generator.rb:79: syntax error, unexpected ':', expecting kEND
option :version, type: :string
^
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `require'
from /Library/Ruby/Gems/1.8/gems/foundation-1.0.1/lib/foundation/cli.rb:2
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require'
from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/rubygems/custom_require.rb:31:in `require'
from /Library/Ruby/Gems/1.8/gems/foundation-1.0.1/bin/foundation:3
from /usr/bin/foundation:19:in `load'
from /usr/bin/foundation:19

A 10 minute search found nothing that helped, so I'm asking here. What am I missing or doing wrong?

I'm using OS X 10.8.5 with Ruby 1.8.7 (2012-02-08 patchlevel 358) [universal-darwin12.0], Node v0.10.15, Homebrew 0.9.4 and I'm sure some other stuff that would be helpful to know that I can't remember right now.

Thanks in advance for any help that you can provide.


Mihai Stroe gave the most helpful answer for this post
Mihai Stroe almost 6 years ago

If you have the most recent versions of the aforementioned software installed, then run the appropriate commands listed on the Foundation 5 with Sass doc page (http://foundation.zurb.com/docs/sass.html), you will install Foundation 5.

After you've installed all the software- gems included -if you run

 foundation version

then you will get

 v1.0.4

That means that the Foundation CLI (command line interface) version is 1.0.4 and not the framework version itself. The framework is Foundation 5 while the CLI (the foundation software you interact with via cmd) is 1.0.4.

This post has been closed. No new replies can be added.

Gary "Lee" Clark, II almost 6 years ago

Well, the editor seems to have doubled up my content areas and I can't see how to delete the post. Long story short, I'm getting an error that I can't figure out. The error is listed above... four(4) times, but I only get it once.

Any help is appreciated.

Thanks.

Neil Haskins almost 6 years ago

The "System Requirements" at http://foundation.zurb.com/docs/sass.html say you need ruby version 1.9+, that may be your issue (but I haven't been able to install either so...)

Gary "Lee" Clark, II almost 6 years ago

Thanks Neil! I'll try to update my Ruby install and see what happens. Hopefully thats all it is.

johnny_n almost 6 years ago

I'm getting the very same messages more or less. Same OS, etc. I think our issue is this:

/System/Library/Frameworks/Ruby.framework/Versions/1.8/

Foundation 5 requires Ruby 1.9+, but somehow even after installing Ruby 2.0.0-p353, and changing my path so /usr/local/bin is before /usr/bin, the latest install still isn't getting "seen".

ruby --version

Gives the correct version, but I even tried following the directions here to configure the ruby version globally with rbenv but that doesn't work either… same errors.

http://createdbypete.com/articles/ruby-on-rails-development-with-mac-os-x-mountain-lion/

Manoj Subramaniam almost 6 years ago

I was wondering what version should i see when i type the command [foundation version]. Right now it displays v1.0.2. Is this correct, or should this be 5.0.something?

When I try to create a project using [foundation new PROJECTNAME], I get the following error.

fatal: unable to access 'https://github.com/zurb/foundation-compass-template.git
/': Failed connect to github.com:443; No error

My ruby version is 1.9.3.

Any ideas? Thanks!

johnny_n almost 6 years ago

Hi @Manoj - I wondered the same thing, but @Gary above had 1.0.1 in his… maybe this is the issue. I didn't get the github problems you did but I think I saw that somewhere else on this forum. Something definitely isn't working correctly...

Manoj Subramaniam almost 6 years ago

Thanks @Johnny. Something is amiss. I've reverted to version 4 for now. Hopefully it will kick back in a couple of days time.

James Dullaghan almost 6 years ago

The Foundation gem requires ruby version 1.9 +. The foundation-rails gem version is correct (1.02). This gem was repackaged with the foundation 5 assets.

This is a longshot, but for anyone having issues with github, try following this article which will use ssh rather than https.

Also, make sure the gem has been installed through rbenv(1.9.x - 2.x), rather than the system ruby(1.8.7).

Hope this helps!

Peter Allen almost 6 years ago

Has anyone solved this? I'm on ruby 2.0.0-p353 via rbenv on Mountain Lion and can't even run the foundation tool without getting these errors.

Peter Allen almost 6 years ago

I'm showing these versions:

 Peters-MacBook-Pro:sass pallen$ gem list | grep foundation
foundation (1.0.4)
foundation-rails (5.0.2.0)

Peter Allen almost 6 years ago

Fixed for me, can't really explain why, but I did

sudo gem uninstall foundation
sudo gem install foundation
rbenv rehash

and now the foundation command runs:

 Peters-MacBook-Pro:sass pallen$ foundation help
Commands:
  foundation help [COMMAND]  # Describe available commands or one specific command
  foundation new             # create new project
  foundation update          # update an existing project
  foundation upgrade         # Upgrade your Foundation 4 compass project
  foundation version         # Display CLI version

Mihai Stroe almost 6 years ago

I ran into the same issue with my system Ruby being stuck on 1.8. Though instead of changing my system Ruby I used RVM (Ruby Version Manager) to do a single-user install of the latest production version (2.0.0-p353). After updating my Ruby, and of course having Node.js and Bower installed, I had no issues installing Foundation 5 with SASS.

Detailed instructions for installing RVM: https://rvm.io/rvm/install

A short walkthrough of how I did it [using OS X Terminal]:

1.) Install latest stable RVM

 \curl -L https://get.rvm.io | bash -s stable

** You might need to close and reopen your Terminal

2.) Check RVM has been installed and see version number

 rvm -v

3.) See list of available Ruby versions

 rvm list known

4.) Install preferred Ruby version, in my case 2.0.0-p353

 rvm install 2.0.0-p353

5.) Make the newly installed Ruby version the default

 rvm use 2.0.0-p353 --default

6.) Check to see that the freshly installed Ruby version is now the default

 ruby -v

7.) Now installing gems is straight forward (where should be replaced with the name of the gem you wish to install

 gem install <RUBYGEM>

Now you should have an up to date Ruby install.

RVM heavily encourages not using sudo with it and since this is a single user install there's no need to sudo anything.

If you choose to go this route then reading the official docs on the website above is suggested. As well I'm not sure how different install instructions would be for other operating systems which is another reason to go through the docs.

Clara almost 6 years ago

Hi I'm really new to Ruby, scss, Foundation etc (as in as of a few hours ago) and I managed to get a working Foundation webpage with scss but realised it was Foundation 4 and thought I may as well use the newest version. When I try and install Foundation 5, the complex way (no easy way like Foundation4 ) I get same as you Peter Allen, it says it has successfully installed foundation (1.0.4), which i'm assuming is wrong and why my webpage is not working (there is text but it doesn't look like an actual webpage as the Foundation4 one did). I am using Ruby 1.9.3 and only downloaded it today so my issue is not of Ruby being stuck on an old version. Should I use the 'sudo' thing? I've heard it's not needed and don't really understand. Thank you for any help.

Clara almost 6 years ago

Neither the sudo nor the rehash thing were recognised when I ran them in the ruby command. :( I managed to uninstall the non-sudo way but it still installed foundation 1.0.4 when I reinstalled it. I hope it's ok me posting on your thread btw.

Clara almost 6 years ago

Ps. I'm running Windows 7, 64-bit.

Clara almost 6 years ago

Also I haven't had a chance to test scss yet as this isn't working but from what I understand you write it and then convert it to css with a program? So could I just download the easy to install css version of Foundation 5 and make my own scss folder, tell a sass program to watch it and output it to the website's css folder?

I guess I wouldn't be able to change the css of the Foundation css itself using scss but I could change my own seperate scss/css files?

Does that make sense/would that be much worse?

Mihai Stroe almost 6 years ago

sudo (super user do) is not a Windows command, strictly *nix. I can't fully help you on windows but if you have the minimum requirements that the Foundation with Sass page mentions (Git, Ruby 1.9+, Node.js) then there shouldn't be any problems when getting everything going.

Make sure you have those 3 installed. Then disregard sudo and,as per the docs, just run

 npm install -g bower grunt-cli

npm is a Node.js command so it should run fine if installed.

To install the Foundation gem you would then simply run, as per the docs

gem install foundation

Of course to use with Sass you would also need to install the Sass gem

gem install sass

Mihai Stroe almost 6 years ago

Perhaps to add on to the above I also have Compass gem installed

 gem install compass

Then I simply navigate to my main site directory and run

 compass watch

and any changes I make to any scss file will be automatically compiled and taken care of.

Clara almost 6 years ago

Hi. Thank you for your replies, but how do I control which version of Foundation gets installed? I think it just keeps installing version 1.0.4. :( I surely have all of those things listed installed because I managed to install foundation, just the wrong version. I have installed them all and made sure I set git up correctly as it says to do for windows.

I will try and do the compass watch thing later but right now I don't have a foundation5 project to watch. Unless I just use the normal foundation 5 installer and forget about the scss version aside from my own scss. :(

Mihai Stroe almost 6 years ago

If you have the most recent versions of the aforementioned software installed, then run the appropriate commands listed on the Foundation 5 with Sass doc page (http://foundation.zurb.com/docs/sass.html), you will install Foundation 5.

After you've installed all the software- gems included -if you run

 foundation version

then you will get

 v1.0.4

That means that the Foundation CLI (command line interface) version is 1.0.4 and not the framework version itself. The framework is Foundation 5 while the CLI (the foundation software you interact with via cmd) is 1.0.4.