Skip to content

Commit ee5f866

Browse files
committed
Make respectLatest nullable with default true
1 parent 0f5f791 commit ee5f866

File tree

1 file changed

+15
-3
lines changed

1 file changed

+15
-3
lines changed

buddy-bot.config.ts

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,16 @@
11
import type { BuddyBotConfig } from 'buddy-bot'
22

3-
const config: BuddyBotConfig = {
3+
// Extended configuration with nullable respectLatest
4+
interface ExtendedBuddyBotConfig extends BuddyBotConfig {
5+
packages?: {
6+
strategy?: string
7+
ignore?: string[]
8+
ignorePaths?: string[]
9+
respectLatest?: boolean | null // Nullable, defaults to true
10+
}
11+
}
12+
13+
const config: ExtendedBuddyBotConfig = {
414
repository: {
515
owner: 'stacksjs',
616
name: 'launchpad',
@@ -34,8 +44,10 @@ const config: BuddyBotConfig = {
3444
// Example: 'packages/test-*/**', '**/*test-envs/**', 'apps/legacy/**'
3545
'packages/launchpad/test/fixtures/pkgx.yml', // Ignore test fixtures that use 'latest'
3646
],
37-
// Configuration for respecting 'latest' versions
38-
respectLatest: true, // Don't create PRs for packages set to 'latest'
47+
// Configuration for respecting 'latest' versions (nullable, defaults to true)
48+
respectLatest: process.env.BUDDY_BOT_RESPECT_LATEST === 'false' ? false :
49+
process.env.BUDDY_BOT_RESPECT_LATEST === 'true' ? true :
50+
null, // null means use default behavior (true)
3951
},
4052
verbose: false,
4153
}

0 commit comments

Comments
 (0)