Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE] add npm_script Task #211

Merged
merged 5 commits into from
Oct 26, 2016
Merged

[FEATURE] add npm_script Task #211

merged 5 commits into from
Oct 26, 2016

Conversation

Kanti
Copy link
Contributor

@Kanti Kanti commented Oct 21, 2016

Q A
Branch master
Bug fix? no
New feature? yes
BC breaks? no
Deprecations? no
Tests pass? yes
Documented? yes
Fixed tickets #208

New Task Checklist:

  • Is the README.md file updated?
  • Are the dependencies added to the composer.json suggestions?
  • Is the doc/tasks.md file updated?
  • Are the task parameters documented?
  • Is the task registered in the tasks.yml file?
  • Does the task contains phpspec tests?
  • Is the configuration having logical allowed types?
  • Does the task run in the correct context?
  • Is the run() method readable?
  • Is the run() method using the configuration correctly?
  • Are all CI services returning green?

@Kanti Kanti changed the title [WIP][FEATURE] add npm_script Task [FEATURE] add npm_script Task Oct 21, 2016
@Kanti
Copy link
Contributor Author

Kanti commented Oct 21, 2016

Please Review! 😅

@veewee veewee added this to the Version 0.9.7 milestone Oct 21, 2016
@veewee
Copy link
Contributor

veewee commented Oct 21, 2016

Thanks @Kanti! The code looks good.

2 small questions:

  • Maybe it's better to set the defaults for the triggered_by option since it mostly is triggered by js / css changes? These are the defaults for Grunt: [js, jsx, coffee, ts, less, sass, scss]
  • Is it possible to specify the location of the package.json file for people with an exotic file structure? Can't find how to do it in the documentation, but it could also be done by specifying a working directory on the process.

@Kanti
Copy link
Contributor Author

Kanti commented Oct 21, 2016

added changes Please Review 😅

$arguments->addRequiredArgument('%s', $config['script']);

$process = $this->processBuilder->buildProcess($arguments);
$process->setWorkingDirectory($config['working_directory']);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will this use the correct directory if you add relative directories? Maybe we should make it relative to the getcwd() ?

@veewee veewee merged commit 02bbbab into phpro:master Oct 26, 2016
@veewee
Copy link
Contributor

veewee commented Oct 26, 2016

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants