These are chat archives for jescalan/roots

11th
Nov 2015
Piet Bos
@senlin
Nov 11 2015 01:54
Hi, I'm new here, just yday I discovered roots and I'm very keen to get it working with WordPress
The issue I'm struggling with at the moment is that I cannot access localhost:1111 because I have already set up an AMP stack with virtual host. Is there a way around this? I am also experiencing compiling errors, but I think they're related to the localhost issue.
Is there anyone who knows a solution for this? That is apart from destroying my AMP stack ;)
Matt
@hew
Nov 11 2015 02:34
@senlin Roots is for static sites. Are you sure you want to try and use it for Wordpress?
Seth Krasnianski
@sethkrasnianski
Nov 11 2015 02:36
There's actually a roots-Wordpress plugin meant for this @oompt
@senlin if you setup Apache to run on 80 or 8080, you shouldn't have any issue getting roots to run on 1111
Apache doesn't high jack all the ports ;)
Matt
@hew
Nov 11 2015 02:41
Oh sweet. Might have to try that out!
Seth Krasnianski
@sethkrasnianski
Nov 11 2015 02:51
it leverages the wp json api so you can manage your content easily (and to most people in a familiar way) then deploy the content as a fast and static site
you’re right though, heavily updated content would probably be better to stay in a dynamic method
https://github.com/carrot/roots-wordpress @senlin @oompt for reference
Matt
@hew
Nov 11 2015 03:02
Thanks for the link :)
Piet Bos
@senlin
Nov 11 2015 03:30
@sethkrasnianski I have set up Apache to run via a few different tutorials using Virtual Hosts, so I run all my local sites as *.dev. localhost/home works and I made it like the screenshot at the bottom of https://mallinson.ca/osx-web-development/
localhost:1111 does not work
The screencast for WordPress is also really helpful, I am halfway with that, but since I cannot get localhost:1111 to work, I cannot get compiling to work and therefore cannot get any further...
Piet Bos
@senlin
Nov 11 2015 04:12
hmmm 3rd time lucky as they say, finally got it working :) on to the rest of the screencast now :)
matt @howzus
@dreamineering
Nov 11 2015 10:54
I've just started with roots and would like to use the contentful plugin but started from a basic site then installed contentful package but now wondering if there is better way by starting with using a contentful template?
Martin Berggren
@marthings
Nov 11 2015 12:54
Okej so i got sass to work with autoprefixer. I just require node-sass and postcss after that in app.coffee. However i dont know why this works? There is no other setup and that makes me confused. Why is it so simple?
There is one thing i miss in my static site. I wonder how i can make a navigation with active states on the current menu/page im on? Anyone that can point me in the right direction to achieve this :)?
Seth Krasnianski
@sethkrasnianski
Nov 11 2015 17:16
how are you setting up your navigation @marthings?
should be as simple as adding a .active class to the nav item
@dreamineering I don’t believe there’s a contentful template out there
just follow the readme
Jeff Escalante
@jescalan
Nov 11 2015 18:26
@imdpk we would be happy to accept a contribution to ship for azure
@marthings you can use multiple compiles to run sass followed by postcss with autoprefixer. install postcss with npm, make the files .css.scss, then configure postcss with autoprefixer in app.coffee
Also much <3 to everyone. And we have some really exciting stuff for roots coming down the pipeline
And it will be amazing and you guys will love it. More info soon
Noel Quiles
@EnMod
Nov 11 2015 19:09
@jenius I am jumping on that hype train, :heart: to you and everyone contributing as I am still using Roots :D I also noticed roots-contentful got a few upgrades, one related to what I think was the path issue I encountered before. Exciting!
John Peele
@johnpeele
Nov 11 2015 20:35
anyone else here having node-gyp issues when creating a new project?
i am getting the following errors:
> fsevents@0.3.8 install /Users/johnpeele/Sites/goodcitizen/redesign/node_modules/roots/node_modules/chokidar/node_modules/fsevents
> node-gyp rebuild

gyp: /Users/johnpeele/.node-gyp/4.2.1/common.gypi not found (cwd: /Users/johnpeele/Sites/goodcitizen/redesign/node_modules/roots/node_modules/chokidar/node_modules/fsevents) while reading includes of binding.gyp while trying to load binding.gyp
gyp ERR! configure error 
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack     at ChildProcess.onCpExit (/usr/local/lib/node_modules/roots/node_modules/npm/node_modules/node-gyp/lib/configure.js:355:16)
gyp ERR! stack     at emitTwo (events.js:87:13)
gyp ERR! stack     at ChildProcess.emit (events.js:172:7)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:200:12)
gyp ERR! System Darwin 14.5.0
gyp ERR! command "/usr/local/Cellar/node/4.2.1/bin/node" "/usr/local/lib/node_modules/roots/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /Users/johnpeele/Sites/goodcitizen/redesign/node_modules/roots/node_modules/chokidar/node_modules/fsevents
gyp ERR! node -v v4.2.1
gyp ERR! node-gyp -v v2.0.1
gyp ERR! not ok 
npm WARN optional dep failed, continuing fsevents@0.3.8
John Peele
@johnpeele
Nov 11 2015 21:10
@jenius any of these errors make sense to you?
> git-scripts@0.2.1 postinstall /Users/johnpeele/Sites/goodcitizen/redesign/node_modules/git-scripts
> ./bin/install

Not a git repository.
npm WARN addRemoteGit Error: not found: [object Object]
npm WARN addRemoteGit   at F (/usr/local/lib/node_modules/roots/node_modules/npm/node_modules/which/which.js:78:19)
npm WARN addRemoteGit   at E (/usr/local/lib/node_modules/roots/node_modules/npm/node_modules/which/which.js:82:29)
npm WARN addRemoteGit   at /usr/local/lib/node_modules/roots/node_modules/npm/node_modules/which/which.js:93:16
npm WARN addRemoteGit   at FSReqWrap.oncomplete (fs.js:82:15)
npm WARN addRemoteGit 
npm WARN addRemoteGit  git://github.com/jenius/node-github.git#create-blob-content resetting remote /Users/johnpeele/.npm/_git-remotes/git-github-com-jenius-node-github-git-cefba6ce because of error: { [Error: not found: [object Object]] code: 'ENOGIT' }
npm ERR! git clone --template=/Users/johnpeele/.npm/_git-remotes/_templates --mirror git://github.com/jenius/node-github.git /Users/johnpeele/.npm/_git-remotes/git-github-com-jenius-node-github-git-cefba6ce: undefined
npm ERR! git clone --template=/Users/johnpeele/.npm/_git-remotes/_templates --mirror git://github.com/jenius/node-github.git /Users/johnpeele/.npm/_git-remotes/git-github-com-jenius-node-github-git-cefba6ce: undefined
npm WARN addRemoteGit Error: not found: [object Object]
npm WARN addRemoteGit   at F (/usr/local/lib/node_modules/roots/node_modules/npm/node_modules/which/which.js:78:19)
npm WARN addRemoteGit   at E (/usr/local/lib/node_modules/roots/node_modules/npm/node_modules/which/which.js:82:29)
npm WARN addRemoteGit   at /usr/local/lib/node_modules/roots/node_modules/npm/node_modules/which/which.js:93:16
npm WARN addRemoteGit   at FSReqWrap.oncomplete (fs.js:82:15)
npm WARN addRemoteGit 
npm WARN addRemoteGit  git://github.com/jenius/st.git resetting remote /Users/johnpeele/.npm/_git-remotes/git-github-com-jenius-st-git-eb581e81 because of error: { [Error: not found: [object Object]] code: 'ENOGIT' }
npm ERR! git clone --template=/Users/johnpeele/.npm/_git-remotes/_templates --mirror git://github.com/jenius/st.git /Users/johnpeele/.npm/_git-remotes/git-github-com-jenius-st-git-eb581e81: undefined
npm ERR! git clone --template=/Users/johnpeele/.npm/_git-remotes/_templates --mirror git://github.com/jenius/st.git /Users/johnpeele/.npm/_git-remotes/git-github-com-jenius-st-git-eb581e81: undefined
Seth Krasnianski
@sethkrasnianski
Nov 11 2015 21:45
Did you try with 0.12?
I haven't tried a new roots project yet. So I've yet to use roots with > 4.x
Node that is
Martin Berggren
@marthings
Nov 11 2015 22:40
@sethkrasnianski i was thinking about something like mixture.io
{% if mixture.url == "about" %}class="selected"{% endif %}
Martin Berggren
@marthings
Nov 11 2015 22:47

@jenius i just added:

sass            = require 'node-sass'
postcss         = require 'postcss'

And switched extension from .styl to .scss in css_pipeline and it does autoprefix my .scss files. Works great! I just don´t know why require on those two plugins makes it work:P