Skip to content

Commit

Permalink
Update workflow and test build system
Browse files Browse the repository at this point in the history
  • Loading branch information
davidnussio committed Nov 4, 2020
1 parent 5724680 commit d00ebd3
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 16 deletions.
16 changes: 1 addition & 15 deletions .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,20 +29,6 @@ jobs:
node-version: 12
registry-url: https://registry.npmjs.org/
- run: npm ci
- run: npm publish
- run: npm publish --tag alpha
env:
NODE_AUTH_TOKEN: ${{secrets.npm_token}}

publish-gpr:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 12
registry-url: https://npm.pkg.github.com/
- run: npm ci
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}
14 changes: 14 additions & 0 deletions internals/build.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
require("esbuild").buildSync({
entryPoints: ["./src/term.js"],
bundle: true,
define: { "process.env.NODE_ENV": "production" },
target: "node12",
platform: "node",
// splitting: true,
// inject: [],
// external: ["terminal-kit"],
format: "cjs",
outdir: "app",
});

// '--define:process.env.NODE_ENV="production"' --platform=node --target='node12' --bundle --outfile=app.js
1 change: 1 addition & 0 deletions jsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"compilerOptions": {
"baseUrl": ".",
"checkJs": true
}
}
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
"main": "index.js",
"bin": "bin/terminal-playground.js",
"scripts": {
"build": "node internals/build.js",
"test": "echo \"Error: no test specified\" && exit 1"
},
"repository": {
Expand Down

0 comments on commit d00ebd3

Please sign in to comment.