Skip to content

Commit

Permalink
feat: ci
Browse files Browse the repository at this point in the history
  • Loading branch information
qq15725 committed Sep 24, 2024
1 parent 2efa1c7 commit b5ffc39
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 9 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
test:
timeout-minutes: 10
runs-on: ubuntu-latest
name: "Build&Test: node-lts, ubuntu-latest"
name: 'Build&Test: node-lts, ubuntu-latest'
steps:
- name: ⤵️ Checkout
uses: actions/checkout@v4
Expand Down Expand Up @@ -65,7 +65,7 @@ jobs:
lint:
timeout-minutes: 10
runs-on: ubuntu-latest
name: "Lint: node-lts, ubuntu-latest"
name: 'Lint: node-lts, ubuntu-latest'
steps:
- name: ⤵️ Checkout
uses: actions/checkout@v4
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: 🚀 Publish Package
on:
push:
tags:
- "v*" # Push events to matching v*, i.e. v1.0, v20.15.10
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10

jobs:
publish:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: 🚀 Add GitHub Release Tag
on:
push:
tags:
- "v*" # Push events to matching v*, i.e. v1.0, v20.15.10
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10

# $GITHUB_REF_NAME - https://docs.github.com/en/actions/learn-github-actions/environment-variables#default-environment-variables

Expand Down
11 changes: 6 additions & 5 deletions vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { basename, resolve } from 'path'
import { basename, resolve } from 'node:path'
import { defineConfig } from 'vite'
import { browser, name } from './package.json'

Expand All @@ -8,12 +8,13 @@ export default defineConfig({
build: {
lib: {
formats: ['umd'],
fileName: format => {
if (format === 'umd') return basename(browser)
return `${ name }.${ format }`
fileName: (format) => {
if (format === 'umd')
return basename(browser)
return `${name}.${format}`
},
entry: resolvePath('./src/index.ts'),
name: name.replace(/-(\w)/ig, (_, v) => v.toUpperCase()),
name: name.replace(/-(\w)/g, (_, v) => v.toUpperCase()),
},
},
})

0 comments on commit b5ffc39

Please sign in to comment.