diff --git a/.github/workflows/audit.yml b/.github/workflows/audit.yml index 052c6b8..5a908c3 100644 --- a/.github/workflows/audit.yml +++ b/.github/workflows/audit.yml @@ -1,7 +1,7 @@ # AUTO-GENERATED — do not edit directly. # Source: theholocron/holocron · packages/cli/src/commands/setup-workflows.ts -# Tool: holocron sync-github -# Changes: edit source in theholocron/holocron and push to alpha or main. +# Tool: holocron setup +# Changes: run `holocron setup` to regenerate. name: Audit on: # yamllint disable-line rule:truthy diff --git a/.github/workflows/deploy-docs.yml b/.github/workflows/deploy-docs.yml index 4b12b59..d570fe3 100644 --- a/.github/workflows/deploy-docs.yml +++ b/.github/workflows/deploy-docs.yml @@ -1,7 +1,7 @@ # AUTO-GENERATED — do not edit directly. # Source: theholocron/holocron · packages/cli/src/commands/setup-workflows.ts -# Tool: holocron sync-github -# Changes: edit source in theholocron/holocron and push to alpha or main. +# Tool: holocron setup +# Changes: run `holocron setup` to regenerate. name: Deploy Docs on: # yamllint disable-line rule:truthy @@ -24,4 +24,7 @@ jobs: deploy-docs: name: Deploy Docs uses: theholocron/.github/.github/workflows/deploy-docs.yml@main + with: + name: node-template + use-turbo: false secrets: inherit diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 6cd7662..f76943b 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,7 +1,7 @@ # AUTO-GENERATED — do not edit directly. # Source: theholocron/holocron · packages/cli/src/commands/setup-workflows.ts -# Tool: holocron sync-github -# Changes: edit source in theholocron/holocron and push to alpha or main. +# Tool: holocron setup +# Changes: run `holocron setup` to regenerate. name: Release on: # yamllint disable-line rule:truthy diff --git a/codecov.yml b/codecov.yml new file mode 100644 index 0000000..1f6062f --- /dev/null +++ b/codecov.yml @@ -0,0 +1,30 @@ +# Scaffolded by holocron setup — edit this file freely. +# Source: theholocron/holocron · packages/cli/src/commands/setup.ts + +codecov: + require_ci_to_pass: true + +coverage: + precision: 2 + round: down + status: + project: + default: + target: auto + threshold: 2% + patch: + default: + target: 80% + +comment: + layout: "reach,diff,flags,components" + behavior: default + require_changes: true + +component_management: + default_rules: + statuses: + - type: patch + target: 80% + individual_components: + [] diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 5bca6dc..b64741b 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -105,11 +105,11 @@ catalogs: version: 4.1.10 holocron: '@theholocron/cli': - specifier: ^3.10.0 - version: 3.10.0 + specifier: ^3.18.5 + version: 3.18.5 '@theholocron/holocron-plugin-github': - specifier: ^3.10.0 - version: 3.10.0 + specifier: ^3.18.5 + version: 3.18.5 overrides: '@commitlint/config-conventional>conventional-changelog-conventionalcommits': '7' @@ -138,7 +138,7 @@ importers: version: 12.0.9(semantic-release@25.0.8(typescript@5.9.3)) '@theholocron/cli': specifier: catalog:holocron - version: 3.10.0(@opentelemetry/core@2.10.0(@opentelemetry/api@1.9.1))(@types/node@26.1.2)(vitest@4.1.10) + version: 3.18.5(@opentelemetry/core@2.10.0(@opentelemetry/api@1.9.1))(@types/node@26.1.2)(vitest@4.1.10) '@theholocron/commitlint-config': specifier: catalog:configs version: 7.8.1(@commitlint/cli@21.2.1(@types/node@26.1.2)(conventional-commits-parser@7.1.2)(typescript@5.9.3))(@commitlint/config-conventional@21.2.0) @@ -147,10 +147,10 @@ importers: version: 7.8.1(@eslint/js@10.0.1(eslint@10.8.0(jiti@2.7.0)))(eslint-plugin-n@18.2.2(eslint@10.8.0(jiti@2.7.0))(typescript@5.9.3))(eslint-plugin-simple-import-sort@14.0.0(eslint@10.8.0(jiti@2.7.0)))(eslint@10.8.0(jiti@2.7.0))(globals@17.9.0)(typescript-eslint@8.65.0(eslint@10.8.0(jiti@2.7.0))(typescript@5.9.3)) '@theholocron/holocron-config': specifier: catalog:configs - version: 7.8.1(@theholocron/cli@3.10.0(@opentelemetry/core@2.10.0(@opentelemetry/api@1.9.1))(@types/node@26.1.2)(vitest@4.1.10)) + version: 7.8.1(@theholocron/cli@3.18.5(@opentelemetry/core@2.10.0(@opentelemetry/api@1.9.1))(@types/node@26.1.2)(vitest@4.1.10)) '@theholocron/holocron-plugin-github': specifier: catalog:holocron - version: 3.10.0(@theholocron/cli@3.10.0(@opentelemetry/core@2.10.0(@opentelemetry/api@1.9.1))(@types/node@26.1.2)(vitest@4.1.10))(@theholocron/github-client@1.6.0(vitest@4.1.10)) + version: 3.18.5(@theholocron/cli@3.18.5(@opentelemetry/core@2.10.0(@opentelemetry/api@1.9.1))(@types/node@26.1.2)(vitest@4.1.10))(@theholocron/github-client@1.6.0(vitest@4.1.10)) '@theholocron/lint-staged-config': specifier: catalog:configs version: 7.8.1(husky@9.1.7)(lint-staged@16.4.0)(sort-package-json@4.0.0) @@ -1986,8 +1986,8 @@ packages: '@standard-schema/spec@1.1.0': resolution: {integrity: sha512-l2aFy5jALhniG5HgqrD6jXLi/rUWrKvqN/qJx6yoJsgKhblVd+iqqU4RCXavm/jPityDo5TCvKMnpjKnOriy0w==} - '@theholocron/cli@3.10.0': - resolution: {integrity: sha512-/C7g95njivFGAN1FCamwPeOZBnoQarDnnTqhVzsmKpjqnx6tetTjpUBfwltJFRAVmVfzN2Zv0HWeZRgNia1DXg==} + '@theholocron/cli@3.18.5': + resolution: {integrity: sha512-csfeElWzLIfGC6W3+xit6thbyhRrIHV77cF5C1GWzvH1bs99L/bxbRBxwUzr4uF9KlsPdWDOeJGHDyzlteFyfw==} hasBin: true '@theholocron/commitlint-config@7.8.1': @@ -2043,10 +2043,10 @@ packages: peerDependencies: '@theholocron/cli': '>=2.0.0-alpha.1' - '@theholocron/holocron-plugin-github@3.10.0': - resolution: {integrity: sha512-d+BBxLco8cO7X1nBFWDbiCUmJTxd3Aw9uzR731OFYfo/qHxLyPj+3+3KYoQQLt7/mgQHEG4JoTeKTsVF9FIa7g==} + '@theholocron/holocron-plugin-github@3.18.5': + resolution: {integrity: sha512-p4h9r1mNwD5F7XOh31qSOTzferiWP7gkDZRlR9RXC6IwjwqpBsKD0nj9ZhTLPs3IVYH3m3ucJZqvAmUhXi3QyQ==} peerDependencies: - '@theholocron/cli': 3.10.0 + '@theholocron/cli': 3.18.5 '@theholocron/github-client': ^1.6.0 '@theholocron/http-client@1.6.0': @@ -4956,6 +4956,11 @@ packages: tslib@2.8.1: resolution: {integrity: sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==} + tsx@4.22.4: + resolution: {integrity: sha512-X8EX+XV4QR5xCsrgxaED954zTDfY8KqlDtskKEL0cHhyS/P8b4IFOvGDQpsC9Q1XnLq915wEfwwY/zzskCtmhg==} + engines: {node: '>=18.0.0'} + hasBin: true + tsx@4.23.1: resolution: {integrity: sha512-GQHnkIfxyx1wYCOS/wonik5MVRZU9hi1TEZmzGZSCJB1y9YgoZ8H6itNE/u4suE+yLmOzuE4E5S4TZ/ZX2wcWQ==} engines: {node: '>=18.0.0'} @@ -6950,7 +6955,7 @@ snapshots: '@standard-schema/spec@1.1.0': {} - '@theholocron/cli@3.10.0(@opentelemetry/core@2.10.0(@opentelemetry/api@1.9.1))(@types/node@26.1.2)(vitest@4.1.10)': + '@theholocron/cli@3.18.5(@opentelemetry/core@2.10.0(@opentelemetry/api@1.9.1))(@types/node@26.1.2)(vitest@4.1.10)': dependencies: '@inquirer/prompts': 8.5.2(@types/node@26.1.2) '@napi-rs/keyring': 1.3.0 @@ -6959,7 +6964,7 @@ snapshots: '@theholocron/http-client': 1.6.0(vitest@4.1.10) chalk: 6.0.0 ora: 9.4.1 - tsx: 4.23.1 + tsx: 4.22.4 yargs: 18.1.0 transitivePeerDependencies: - '@opentelemetry/core' @@ -6995,13 +7000,13 @@ snapshots: transitivePeerDependencies: - vitest - '@theholocron/holocron-config@7.8.1(@theholocron/cli@3.10.0(@opentelemetry/core@2.10.0(@opentelemetry/api@1.9.1))(@types/node@26.1.2)(vitest@4.1.10))': + '@theholocron/holocron-config@7.8.1(@theholocron/cli@3.18.5(@opentelemetry/core@2.10.0(@opentelemetry/api@1.9.1))(@types/node@26.1.2)(vitest@4.1.10))': dependencies: - '@theholocron/cli': 3.10.0(@opentelemetry/core@2.10.0(@opentelemetry/api@1.9.1))(@types/node@26.1.2)(vitest@4.1.10) + '@theholocron/cli': 3.18.5(@opentelemetry/core@2.10.0(@opentelemetry/api@1.9.1))(@types/node@26.1.2)(vitest@4.1.10) - '@theholocron/holocron-plugin-github@3.10.0(@theholocron/cli@3.10.0(@opentelemetry/core@2.10.0(@opentelemetry/api@1.9.1))(@types/node@26.1.2)(vitest@4.1.10))(@theholocron/github-client@1.6.0(vitest@4.1.10))': + '@theholocron/holocron-plugin-github@3.18.5(@theholocron/cli@3.18.5(@opentelemetry/core@2.10.0(@opentelemetry/api@1.9.1))(@types/node@26.1.2)(vitest@4.1.10))(@theholocron/github-client@1.6.0(vitest@4.1.10))': dependencies: - '@theholocron/cli': 3.10.0(@opentelemetry/core@2.10.0(@opentelemetry/api@1.9.1))(@types/node@26.1.2)(vitest@4.1.10) + '@theholocron/cli': 3.18.5(@opentelemetry/core@2.10.0(@opentelemetry/api@1.9.1))(@types/node@26.1.2)(vitest@4.1.10) '@theholocron/github-client': 1.6.0(vitest@4.1.10) libsodium-wrappers: 0.8.4 @@ -10417,11 +10422,18 @@ snapshots: tslib@2.8.1: optional: true + tsx@4.22.4: + dependencies: + esbuild: 0.28.1 + optionalDependencies: + fsevents: 2.3.3 + tsx@4.23.1: dependencies: esbuild: 0.28.1 optionalDependencies: fsevents: 2.3.3 + optional: true tunnel@0.0.6: {} diff --git a/pnpm-workspace.yaml b/pnpm-workspace.yaml index accc27e..cb2e608 100644 --- a/pnpm-workspace.yaml +++ b/pnpm-workspace.yaml @@ -41,5 +41,5 @@ catalogs: '@theholocron/vitest-config': ^7.8.1 holocron: - '@theholocron/cli': ^3.10.0 - '@theholocron/holocron-plugin-github': ^3.10.0 + '@theholocron/cli': ^3.18.5 + '@theholocron/holocron-plugin-github': ^3.18.5 diff --git a/src/add.test.ts b/src/add.test.ts new file mode 100644 index 0000000..017ab1e --- /dev/null +++ b/src/add.test.ts @@ -0,0 +1,17 @@ +import { describe, expect, test } from "vitest"; + +import { add } from "./add.js"; + +describe("add", () => { + test("returns the correct sum", () => { + expect(add(2, 3)).toBe(5); + }); + + test("handles negative numbers", () => { + expect(add(-2, -3)).toBe(-5); + }); + + test("handles zero", () => { + expect(add(0, 5)).toBe(5); + }); +}); diff --git a/src/add.ts b/src/add.ts new file mode 100644 index 0000000..1a2e299 --- /dev/null +++ b/src/add.ts @@ -0,0 +1,3 @@ +export function add(a: number, b: number): number { + return a + b; +} diff --git a/src/index.test.ts b/src/index.test.ts deleted file mode 100644 index acaa02d..0000000 --- a/src/index.test.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { describe, test, expect } from "vitest"; -import add from "./index.js"; - -describe("add function", () => { - test("should return the correct sum", () => { - expect(add(2, 3)).toBe(5); - }); - - test("should handle negative numbers", () => { - expect(add(-2, -3)).toBe(-5); - }); - - test("should handle zero", () => { - expect(add(0, 5)).toBe(5); - }); -}); diff --git a/src/index.ts b/src/index.ts index c311579..257b82c 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,3 +1 @@ -export default function add(a: number, b: number): number { - return a + b; -} +export { add } from "./add.js";