Skip to content

Commit f9928a4

Browse files
authored
chore: add typo check (#254)
* chore: addd similarity * chore: add typos * chore: format * ci(lefthook): add typos check to pre-push hook - Add typos check to pre-push hook to catch spelling errors before pushing - Explicitly specify typos.toml configuration file - Runs after staged changes but before knip linter * ci: add typos * chore: make cis parallel * chore(lint): exclude CHANGELOG.md from oxlint checks Add CHANGELOG.md to oxlint ignorePatterns to prevent linting errors. The changelog is auto-generated and should not be linted alongside application code. It was already excluded from oxfmt. * chore(changelog): revert format to match main branch Revert changelog formatting from dash bullets to asterisk bullets, and restore blank lines after section headers. This aligns with the canonical format maintained on the main branch. * chore: oxfmt
1 parent add74ed commit f9928a4

23 files changed

+117
-64
lines changed

.github/workflows/ci.yaml

Lines changed: 29 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ permissions:
1616
id-token: write
1717

1818
jobs:
19-
ci:
19+
typos:
2020
runs-on: ubuntu-latest
2121
steps:
2222
- name: Checkout repository
@@ -25,36 +25,56 @@ jobs:
2525
- name: Setup Nix
2626
uses: ./.github/actions/setup-nix
2727

28+
- name: Run Typo Check
29+
run: nix develop --command typos .
30+
31+
lint:
32+
runs-on: ubuntu-latest
33+
steps:
34+
- name: Checkout repository
35+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
36+
- name: Setup Nix
37+
uses: ./.github/actions/setup-nix
2838
- name: Run Lint
2939
run: nix develop --command pnpm run lint
3040

41+
build-and-test:
42+
runs-on: ubuntu-latest
43+
steps:
44+
- name: Checkout repository
45+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
46+
47+
- name: Setup Nix
48+
uses: ./.github/actions/setup-nix
49+
3150
- name: Run Build
3251
run: nix develop --command pnpm run build
3352

3453
- name: Run Tests
35-
if: github.ref != 'refs/heads/main'
3654
run: nix develop --command pnpm test
3755

56+
coverage:
57+
runs-on: ubuntu-latest
58+
if: github.ref == 'refs/heads/main'
59+
steps:
60+
- name: Checkout repository
61+
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
62+
- name: Setup Nix
63+
uses: ./.github/actions/setup-nix
3864
- name: Run Tests with Coverage
39-
if: github.ref == 'refs/heads/main'
4065
run: nix develop --command pnpm run coverage
41-
4266
- name: Create Coverage Badge
43-
if: github.ref == 'refs/heads/main'
4467
uses: jaywcjlove/coverage-badges-cli@bd6ccbf422c0ed54c01f283019fd2bc648f58541 # v2.2.0
4568
with:
4669
source: coverage/coverage-summary.json
4770
output: coverage/badges.svg
48-
4971
- name: Upload coverage artifact
50-
if: github.ref == 'refs/heads/main'
5172
uses: actions/upload-pages-artifact@7b1f4a764d45c48632c6b24a0339c27f5614fb0b # v4.0.0
5273
with:
5374
path: coverage
5475

5576
deploy-coverage:
56-
if: github.ref == 'refs/heads/main'
57-
needs: ci
77+
needs: coverage
5878
runs-on: ubuntu-latest
5979
environment:
6080
name: github-pages

.oxlintrc.jsonc

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,15 @@
99
"node": true,
1010
},
1111
// Ignore patterns
12-
"ignorePatterns": ["dist", "node_modules", ".claude", "tmp", "*.log", "/nix/store/**"],
12+
"ignorePatterns": [
13+
"dist",
14+
"node_modules",
15+
".claude",
16+
"tmp",
17+
"*.log",
18+
"/nix/store/**",
19+
"CHANGELOG.md",
20+
],
1321
// Rule categories - strict base configuration
1422
// - correctness (196 rules): Catch definite bugs and errors
1523
// - suspicious (47 rules): Flag potentially problematic patterns

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -458,7 +458,7 @@ You can use the `dryRun` option to return the api arguments from a tool call wit
458458
```typescript
459459
import { StackOneToolSet } from "@stackone/ai";
460460

461-
// Initialise the toolset
461+
// Initialize the toolset
462462
const toolset = new StackOneToolSet({
463463
baseUrl: "https://api.stackone.com",
464464
});

examples/ai-sdk-integration.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ if (!apiKey) {
2626
const accountId = 'your-bamboohr-account-id';
2727

2828
const aiSdkIntegration = async (): Promise<void> => {
29-
// Initialise StackOne
29+
// Initialize StackOne
3030
const toolset = new StackOneToolSet({
3131
accountId,
3232
baseUrl: process.env.STACKONE_BASE_URL ?? 'https://api.stackone.com',

examples/anthropic-integration.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ if (!apiKey) {
1717
const accountId = 'your-hris-account-id';
1818

1919
const anthropicIntegration = async (): Promise<void> => {
20-
// Initialise StackOne
20+
// Initialize StackOne
2121
const toolset = new StackOneToolSet({
2222
accountId,
2323
baseUrl: process.env.STACKONE_BASE_URL ?? 'https://api.stackone.com',
@@ -29,7 +29,7 @@ const anthropicIntegration = async (): Promise<void> => {
2929
});
3030
const anthropicTools = tools.toAnthropic();
3131

32-
// Initialise Anthropic client
32+
// Initialize Anthropic client
3333
const anthropic = new Anthropic();
3434

3535
// Create a message with tool calls

examples/claude-agent-sdk-integration.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ if (!apiKey) {
2121
const accountId = 'your-bamboohr-account-id';
2222

2323
const claudeAgentSdkIntegration = async (): Promise<void> => {
24-
// Initialise StackOne
24+
// Initialize StackOne
2525
const toolset = new StackOneToolSet({
2626
accountId,
2727
baseUrl: process.env.STACKONE_BASE_URL ?? 'https://api.stackone.com',

examples/fetch-tools-debug.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ if ((typeof globalThis.Bun as any) !== 'undefined') {
203203
}
204204

205205
const spinner = clack.spinner();
206-
spinner.start('Initialising StackOne client...');
206+
spinner.start('Initializing StackOne client...');
207207

208208
const toolset = new StackOneToolSet({
209209
apiKey,

examples/meta-tools.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ const accountId = 'your-bamboohr-account-id';
2626
const metaToolsWithAISDK = async (): Promise<void> => {
2727
console.log('🔍 Example 1: Dynamic tool discovery with AI SDK\n');
2828

29-
// Initialise StackOne toolset
29+
// Initialize StackOne toolset
3030
const toolset = new StackOneToolSet({
3131
accountId,
3232
baseUrl: process.env.STACKONE_BASE_URL ?? 'https://api.stackone.com',
@@ -64,7 +64,7 @@ const metaToolsWithOpenAI = async (): Promise<void> => {
6464
apiKey: process.env.OPENAI_API_KEY,
6565
});
6666

67-
// Initialise StackOne toolset
67+
// Initialize StackOne toolset
6868
const toolset = new StackOneToolSet({
6969
accountId,
7070
baseUrl: process.env.STACKONE_BASE_URL ?? 'https://api.stackone.com',
@@ -118,7 +118,7 @@ const metaToolsWithOpenAI = async (): Promise<void> => {
118118
const directMetaToolUsage = async (): Promise<void> => {
119119
console.log('\n🛠️ Example 3: Direct meta tool usage\n');
120120

121-
// Initialise toolset
121+
// Initialize toolset
122122
const toolset = new StackOneToolSet({
123123
accountId,
124124
baseUrl: process.env.STACKONE_BASE_URL ?? 'https://api.stackone.com',

examples/openai-integration.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ describe('openai-integration example e2e', () => {
3333
expect(openAITools[0]).toHaveProperty('type', 'function');
3434
expect(openAITools[0]).toHaveProperty('function');
3535

36-
// Initialise OpenAI client
36+
// Initialize OpenAI client
3737
const openai = new OpenAI();
3838

3939
// Create a chat completion with tool calls

examples/openai-integration.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ if (!apiKey) {
1717
const accountId = 'your-bamboohr-account-id';
1818

1919
const openaiIntegration = async (): Promise<void> => {
20-
// Initialise StackOne
20+
// Initialize StackOne
2121
const toolset = new StackOneToolSet({
2222
accountId,
2323
baseUrl: process.env.STACKONE_BASE_URL ?? 'https://api.stackone.com',
@@ -27,7 +27,7 @@ const openaiIntegration = async (): Promise<void> => {
2727
const tools = await toolset.fetchTools();
2828
const openAITools = tools.toOpenAI();
2929

30-
// Initialise OpenAI client
30+
// Initialize OpenAI client
3131
const openai = new OpenAI();
3232

3333
// Create a chat completion with tool calls

0 commit comments

Comments
 (0)