Skip to content

Commit ea025a9

Browse files
committed
Publish to NPM.
1 parent 545575e commit ea025a9

File tree

4 files changed

+49
-4
lines changed

4 files changed

+49
-4
lines changed
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: Publish to npm
2+
on: push
3+
4+
jobs:
5+
build:
6+
name: Build distribution
7+
runs-on: ubuntu-latest
8+
permissions:
9+
contents: read
10+
id-token: write
11+
steps:
12+
- uses: actions/checkout@v4
13+
- uses: actions/setup-node@v4
14+
with:
15+
node-version: '20.x'
16+
- run: npm ci
17+
- run: npm build
18+
publish-to-npm:
19+
name: Publish to npm
20+
if: startsWith(github.ref, 'refs/tags/')
21+
needs:
22+
- build
23+
runs-on: ubuntu-latest
24+
permissions:
25+
contents: read
26+
id-token: write
27+
steps:
28+
- uses: actions/checkout@v4
29+
- uses: actions/setup-node@v4
30+
with:
31+
node-version: '20.x'
32+
registry-url: 'https://registry.npmjs.org'
33+
- run: npm ci
34+
- run: npm publish --access public
35+
env:
36+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
.vscode
22
node_modules
33
build
4-
src/index.ts
4+
src/main.ts

package.json

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,18 @@
11
{
2-
"name": "ceres",
3-
"private": "true",
4-
"version": "0.0.0",
2+
"name": "@voxelstack/ceres",
3+
"version": "0.1.0",
4+
"description": "Web development for me.",
5+
"keywords": ["UI", "framework"],
6+
"homepage": "https://github.com/voxelstack/ceres",
7+
"license": "MIT",
8+
"author": "voxelstack <voxelstack@gmail.com>",
9+
"repository": {
10+
"type": "git",
11+
"url": "git+https://github.com/voxelstack/ceres.git"
12+
},
513
"type": "module",
614
"main": "index.js",
15+
"types": "index.d.ts",
716
"scripts": {
817
"dev": "run-p build:watch serve",
918
"serve": "http-server -o -c-1",
File renamed without changes.

0 commit comments

Comments
 (0)