etoxin
etoxin

Reputation: 5264

Running a Phantomjs script as a gruntjs Task

I have a script that I run in phantomjs that performs some tasks in a web browser. I normally run it like so:

phantomjs build.js

How would I integrate this as a Task in a Gruntjs build?

i'm currently using the grunt-shell plugin however I cannot see the output from phamtomjs.

Upvotes: 0

Views: 122

Answers (1)

Ben
Ben

Reputation: 10146

You need to set the stdout option if you want to see the output logged.

shell: {
    phantom: {
        command: 'phantomjs build.js',
        options: {
            stdout: true
        }
    }
}

Upvotes: 1

Related Questions