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

feat(cli): Add hooks to call into npm scripts when capacitor commands run #4739

Merged
merged 3 commits into from
Jun 24, 2021
Merged

feat(cli): Add hooks to call into npm scripts when capacitor commands run #4739

merged 3 commits into from
Jun 24, 2021

Conversation

EinfachHans
Copy link
Contributor

As my other PR #4536 is still pending, this would be another way for me to make my android Build work in Appflow.

Changes in this PR:

  • The existing method runPlatformHook was extended with a new Environment Variable: CAPACITOR_PLATFORM_NAME
  • The same Method is used to trigger the following hooks from package.json:
    • capacitor:sync:before
    • capacitor:sync:after
    • capacitor:copy:before
    • capacitor:copy:after
    • capacitor:update:before
    • capacitor:update:after

closes #3593

@jcesarmobile jcesarmobile self-requested a review June 24, 2021 11:31
Copy link
Member

@jcesarmobile jcesarmobile left a comment

Choose a reason for hiding this comment

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

looks good, thanks!

@elylucas elylucas changed the title feat(cli): Add ability to hook into cap commands feat(cli): Add hooks to call into npm scripts when capacitor commands run Jun 24, 2021
@jcesarmobile jcesarmobile merged commit 515230c into ionic-team:main Jun 24, 2021
@EinfachHans EinfachHans deleted the issue-3593 branch June 24, 2021 15:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feat: ability to hook into cap commands
2 participants