Skip to content

Commit

Permalink
feat: start updating package.json
Browse files Browse the repository at this point in the history
update webpack config

copy everything over

format and fix everything

workflow

finish
  • Loading branch information
roninjin10 committed Oct 12, 2024
1 parent 31cfa61 commit f034863
Show file tree
Hide file tree
Showing 20 changed files with 5,896 additions and 3,694 deletions.
71 changes: 71 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
name: Build, Lint, and Publish

on:
push:
branches:
- main
workflow_dispatch:
inputs:
publish_type:
description: 'Type of publish: dry, production, or canary'
required: true
default: 'dry'

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: 🛎️ Checkout repository
uses: actions/checkout@v3

- name: 🛠️ Set up Node.js
uses: actions/setup-node@v3
with:
node-version: '22'

- name: 🔧 Set up Rust
uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true

- name: 📦 Cargo build
run: cargo build --release

- name: 📥 Install dependencies
working-directory: ./helios-ts
run: npm ci --frozen-lockfile

- name: 🔍 Run linters
working-directory: ./helios-ts
run: npm run lint:check
continue-on-error: true

- name: 🎨 Check formatting
working-directory: ./helios-ts
run: npm run format:check
continue-on-error: true

- name: 📦 Lint package
working-directory: ./helios-ts
run: npm run lint:package
continue-on-error: true

- name: 🏗️ Build Helios-TS
working-directory: ./helios-ts
run: npm run build
continue-on-error: true

- name: 🚀 Publish Package
if: ${{ success() &&
github.event.inputs.publish_type != 'dry' }}
working-directory: ./helios-ts
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
run: |
if [ "${{ github.event.inputs.publish_type }}" == "production" ]; then
npm run publish
elif [ "${{ github.event.inputs.publish_type }}" == "canary" ]; then
npm run publish:canary
fi
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ target

helios-ts/node_modules
helios-ts/dist
helios-ts/types
helios-ts/helios-*.tgz
helios-ts/pkg

Expand Down
49 changes: 49 additions & 0 deletions helios-ts/biome.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
{
"$schema": "./node_modules/@biomejs/biome/configuration_schema.json",
"organizeImports": {
"enabled": true
},
"files": {
"ignore": ["dist/**", "pkg/**", "node_modules/**"]
},
"formatter": {
"enabled": true,
"formatWithErrors": false,
"indentStyle": "space",
"indentWidth": 2,
"lineWidth": 120
},
"linter": {
"enabled": true,
"rules": {
"recommended": true,
"style": {
"useImportType": "off"
},
"performance": {
"noDelete": "off",
"noAccumulatingSpread": "off"
},
"complexity": {
"noForEach": "off",
"noBannedTypes": "off",
"useLiteralKeys": "off"
},
"suspicious": {
"noExplicitAny": "off",
"noGlobalAssign": "off",
"noArrayIndexKey": "off",
"noConfusingVoidType": "off",
"noAssignInExpressions": "off",
"noRedeclare": "off"
}
}
},
"javascript": {
"formatter": {
"quoteStyle": "single",
"trailingCommas": "all",
"semicolons": "asNeeded"
}
}
}
Loading

0 comments on commit f034863

Please sign in to comment.