@lombard.finance/ts-verifier 0.1.1 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,59 @@
1
+ name: Publish
2
+ run-name: Publish ts-verifier from ${{ github.ref_name }}
3
+
4
+ on:
5
+ workflow_dispatch:
6
+
7
+ jobs:
8
+ publish:
9
+ runs-on: [self-hosted]
10
+ environment: production
11
+ container:
12
+ image: ${{ vars.AWS_ECR_REGISTRY }}/library/alpine-git-node-aws:latest
13
+ concurrency:
14
+ group: ${{ github.workflow }}-${{ github.ref }}-publish
15
+ cancel-in-progress: true
16
+
17
+ steps:
18
+ - name: Checkout
19
+ uses: actions/checkout@v4
20
+ with:
21
+ fetch-depth: 0
22
+ ref: ${{ github.ref || github.sha }}
23
+
24
+ - name: Allow Git to access repo
25
+ run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
26
+
27
+ - name: Debug Git status
28
+ run: |
29
+ echo "PWD: $(pwd)"
30
+ ls -la
31
+ git status
32
+
33
+ - name: Set Git identity
34
+ run: |
35
+ git config user.name "${{ github.actor }}"
36
+ git config user.email "${{ github.actor }}@users.noreply.github.com"
37
+ echo "✅ Git identity configured successfully."
38
+
39
+ - name: Setup node
40
+ uses: actions/setup-node@v4
41
+ with:
42
+ node-version-file: '.nvmrc'
43
+ cache: yarn
44
+
45
+ - name: Install dependencies
46
+ run: yarn install --immutable
47
+
48
+ - name: Build package
49
+ run: yarn build
50
+
51
+ - name: Configure registry
52
+ working-directory: ./
53
+ run: |
54
+ npm config set access public -ws=false -iwr
55
+ npm config set //registry.npmjs.org/:_authToken ${{ secrets.NPMJS_TOKEN }} -ws=false -iwr
56
+
57
+ - name: Publish
58
+ working-directory: ./
59
+ run: npm publish
package/.nvmrc ADDED
@@ -0,0 +1 @@
1
+ 22.14.0
package/CODEOWNERS ADDED
@@ -0,0 +1,2 @@
1
+ # Restrict any changes to GitHub workflow files without approval. This is required to protect sensitive NPM token.
2
+ /.github/workflows/ @megatron757 @fruit37 @le0n229
package/package.json CHANGED
@@ -1,19 +1,35 @@
1
1
  {
2
2
  "name": "@lombard.finance/ts-verifier",
3
3
  "description": "Lombard Deposit Address Verifier",
4
- "version": "0.1.1",
5
- "homepage": "/",
4
+ "version": "0.1.2",
5
+ "license": "MIT",
6
6
  "scripts": {
7
+ "build": "yarn types && vite build && yarn build-types",
8
+ "build-types": "tsc -b tsconfig.build.json",
9
+ "types": "tsc --noEmit",
7
10
  "format": "prettier *.js \"*{.js,.ts}\" -w",
8
11
  "lint": "prettier *.js \"*{.js,.ts}\" --check"
9
12
  },
13
+ "engines": {
14
+ "node": ">= 22.14.0"
15
+ },
16
+ "exports": {
17
+ ".": {
18
+ "types": "./dist/index.d.ts",
19
+ "import": "./dist/index.js",
20
+ "require": "./dist/index.cjs"
21
+ }
22
+ },
23
+ "type": "module",
24
+ "types": "./src/index.ts",
10
25
  "dependencies": {
11
26
  "@solana/spl-token": "^0.4.13",
12
27
  "@solana/web3.js": "^1.98.2",
13
28
  "bitcoinjs-lib": "^6.1.7",
14
29
  "bs58": "^6.0.0",
15
30
  "secp256k1": "^5.0.1",
16
- "typescript": "^5.8.3"
31
+ "typescript": "^5.8.3",
32
+ "vite": "^6.3.5"
17
33
  },
18
34
  "devDependencies": {
19
35
  "@types/bs58": "^5.0.0",
@@ -0,0 +1 @@
1
+ /// <reference types="vite/client" />
@@ -0,0 +1,14 @@
1
+ {
2
+ "extends": "./tsconfig.json",
3
+ "compilerOptions": {
4
+ "noEmit": false,
5
+ "emitDeclarationOnly": true,
6
+ "declaration": true,
7
+ "declarationMap": true,
8
+ "outDir": "dist",
9
+ "rootDir": "src",
10
+ "incremental": false
11
+ },
12
+ "include": ["src/**/*"],
13
+ "exclude": ["node_modules"]
14
+ }
@@ -0,0 +1,15 @@
1
+ {
2
+ "compilerOptions": {
3
+ "composite": true,
4
+ "module": "ESNext",
5
+ "moduleResolution": "Node",
6
+ "allowSyntheticDefaultImports": true,
7
+ "resolveJsonModule": true,
8
+ "target": "ESNext",
9
+ "useDefineForClassFields": true,
10
+ "esModuleInterop": false,
11
+ "baseUrl": "src",
12
+ "sourceMap": true
13
+ },
14
+ "include": ["vite.config.ts", "package.json"]
15
+ }
package/vite.config.ts ADDED
@@ -0,0 +1,30 @@
1
+ import path from 'node:path';
2
+
3
+ import { defineConfig } from 'vite';
4
+
5
+ export default defineConfig({
6
+ plugins: [],
7
+ build: {
8
+ sourcemap: false,
9
+ lib: {
10
+ entry: path.resolve(__dirname, 'src/index.ts'),
11
+ },
12
+ rollupOptions: {
13
+ output: [
14
+ {
15
+ format: 'es',
16
+ dir: 'dist',
17
+ entryFileNames: '[name].js',
18
+ chunkFileNames: '[name].js',
19
+ },
20
+ {
21
+ format: 'commonjs',
22
+ dir: 'dist',
23
+ entryFileNames: '[name].cjs',
24
+ chunkFileNames: '[name].cjs',
25
+ },
26
+ ],
27
+ plugins: [],
28
+ },
29
+ },
30
+ });