Giter Site home page Giter Site logo

Comments (7)

sindresorhus avatar sindresorhus commented on May 29, 2024

Do you have PHP installed and available in your $PATH?

Can you post the full output?

Also this line is wrong: urls: ['http://localhost:<%= connect.options.port %>/index.html']

Should be: urls: ['http://localhost:<%= php.dist.options.port %>/index.html']

from grunt-php.

teeli avatar teeli commented on May 29, 2024

I guess you can qualify this as PEBCAK.

I fixed the urls line and a couple of other things (php was already in path though), but now grunt php outputs php --help. I'll keep digging.

from grunt-php.

edouard-lopez avatar edouard-lopez commented on May 29, 2024

Got a similar problem.

grunt php                                                                                                                                  3 ↵
Running "php:dist" (php) task
chdir(): No such file or directory
Fatal error: spawn ENOENT

Not sure if my config is right as my grunt file is a lot more complex due to yeoman, please check my grunt file.
Already done:

  • add an entry to livereload task: '<%= yeoman.app %>/*.php' ;
  • add an entry to copy task: '{,*/}*.{php,phpc}' ;
  • update the urls in mocha task ;
  • register a new php task (doesn't it override the existing one?).

from grunt-php.

sindresorhus avatar sindresorhus commented on May 29, 2024

@edouard-lopez Does the folder subfolder exist?

from grunt-php.

AdamHolwerda avatar AdamHolwerda commented on May 29, 2024

I had the same issue - of course it was because subfolder didn't exist. I just removed that line so it would default to my root folder.

@sindresorhus Is it obvious enough that the user is supposed to rename subfolder to whatever directory they actually have? Maybe the default value for base could be dir_name or path_to_dir?

from grunt-php.

sindresorhus avatar sindresorhus commented on May 29, 2024

@AdamHolwerda if you've read the docs, then yes.

I've removed it from the example as it weren't essential.

from grunt-php.

timelf123 avatar timelf123 commented on May 29, 2024

Not the same issue, but I had set up middleware php-cgi according to this guide: https://coderwall.com/p/bal2_a

One of our developers updated his OSX and it changed up his PHP configuration, so he needed to use homebrew to reinstall php-cgi (see guide above) and everything worked again.

from grunt-php.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.