Skip to content

Commit 7ae611a

Browse files
committed
fix(publint): package dir for workspace
1 parent df36ab5 commit 7ae611a

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/features/publint.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import path from 'node:path'
12
import process from 'node:process'
23
import { dim } from 'ansis'
34
import Debug from 'debug'
@@ -16,9 +17,10 @@ export async function publint(options: ResolvedOptions): Promise<void> {
1617
debug('Running publint')
1718
const { publint } = await import('publint')
1819
const { formatMessage } = await import('publint/utils')
19-
const { messages } = await publint(
20-
options.publint === true ? {} : options.publint,
21-
)
20+
const { messages } = await publint({
21+
...(options.publint === true ? {} : options.publint),
22+
pkgDir: path.dirname(options.pkg.packageJsonPath),
23+
})
2224
debug('Found %d issues', messages.length)
2325

2426
if (!messages.length) {

0 commit comments

Comments
 (0)