Skip to content

Commit

Permalink
Adds note that absolute path is required
Browse files Browse the repository at this point in the history
An absolute path is required when calling `require()` from within the github-script
  • Loading branch information
Jochen Ulrich authored and GitHub committed Jul 16, 2020
1 parent 1ba1e95 commit c19d6ba
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,7 @@ jobs:
const scriptPath = path.resolve('./path/to/script.js')
console.log(require(scriptPath)({context}))
```
_(Note that the script path given to `require()` must be an absolute path in this case.)_

And then export a function from your module:

Expand Down

0 comments on commit c19d6ba

Please sign in to comment.