Skip to content

[4.0] Switch to NodeJS Environment (BC)#45

Merged
stefanzweifel merged 10 commits intomasterfrom
refactor/switch-to-js
Feb 24, 2020
Merged

[4.0] Switch to NodeJS Environment (BC)#45
stefanzweifel merged 10 commits intomasterfrom
refactor/switch-to-js

Conversation

@stefanzweifel
Copy link
Copy Markdown
Owner

This PR rewrites the action to use the node12-environment instead of Docker. The Action therefore uses the default Actions environment and has access to all the installed software.

For example, it's now possible to run pre-commit hooks with husky (Closes #18).

I've decided against using packages like @actions/exec and @actions/toolkit, as I don't like the overhead of installing node packages just to execute a shell script. The code to execute a shell script via node has been inspired by https://github.com/ad-m/github-push-action/.

The next logical step would be to rewrite the shell script in JS or TS. See #44.

Testing

To the the changes, please update your workflow file to use the refactor/switch-to-js-branch of the repo.

    - uses: stefanzweifel/git-auto-commit-action@refactor/switch-to-js
      with:
        commit_message: Your Message goes here
        branch: ${{ github.head_ref }}

Test Run:

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.

Can't find node in PATH, trying to find a node binary on your system

1 participant