-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create new workflow with first job of creating the package file
- Loading branch information
1 parent
51a96ef
commit b3f18b3
Showing
1 changed file
with
26 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
name: Publish new package | ||
on: | ||
workflow_dispatch: | ||
pull_request: #TODO - For testing, remove before final merge | ||
jobs: | ||
package: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Check out code | ||
uses: actions/checkout@v4 | ||
- name: Set up environment | ||
uses: ./.github/actions/set-up-environment | ||
- name: Create package | ||
run: | | ||
npm run prepare | ||
cp README.md package.json ./dist/tech-carbon-estimator/ | ||
cd dist/tech-carbon-estimator | ||
npm pkg delete scripts private devDependencies files | ||
npm pkg set main=main.js | ||
npm pack | ||
- name: Upload artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
if-no-files-found: error | ||
path: scottlogic-tech-carbon-estimator-*.tgz | ||
overwrite: true #TODO - For testing, remove before final merge |