exclude
Exclude by path using Regex to match only the files that should be performed.
CLIβ
# Excluding directories and files from tests
npx poku --exclude='some-file-or-dir' ./test
# Excluding directories and files from tests
npx poku --exclude='some-file-or-dir|other-file-or-dir' ./test
Config Fileβ
Excluding directories:
- poku.config.js
- .pokurc.jsonc
import { defineConfig } from 'poku';
export default defineConfig({
exclude: /\/(helpers|tools)\//,
});
{
"$schema": "https://poku.io/schemas/configs.json",
"exclude": "/(helpers|tools)/"
}
Excluding directories using an array:
- poku.config.js
- .pokurc.jsonc
import { defineConfig } from 'poku';
export default defineConfig({
exclude: [/\/helpers\//, /\/tools\//],
});
{
"$schema": "https://poku.io/schemas/configs.json",
"exclude": ["/helpers/", "/tools/"]
}
Excluding specific files:
- poku.config.js
- .pokurc.jsonc
import { defineConfig } from 'poku';
export default defineConfig({
exclude: /(index|common).test.ts/,
});
{
"$schema": "https://poku.io/schemas/configs.json",
"exclude": "(index|common).test.ts"
}
Excluding specific files using an array:
- poku.config.js
- .pokurc.jsonc
import { defineConfig } from 'poku';
export default defineConfig({
exclude: [/index.test.ts/, /common.test.ts/],
});
{
"$schema": "https://poku.io/schemas/configs.json",
"exclude": ["index.test.ts", "common.test.ts"]
}
Excluding directories and files:
- poku.config.js
- .pokurc.jsonc
import { defineConfig } from 'poku';
export default defineConfig({
exclude: /\/(helpers|tools)\/|(index|common).test.ts/,
});
{
"$schema": "https://poku.io/schemas/configs.json",
"exclude": "/(helpers|tools)/|(index|common).test.ts"
}
Excluding directories and files using an array:
- poku.config.js
- .pokurc.jsonc
import { defineConfig } from 'poku';
export default defineConfig({
exclude: [/\/helpers\//, /\/tools\//, /index.test.ts/, /common.test.ts/],
});
{
"$schema": "https://poku.io/schemas/configs.json",
"exclude": ["/helpers/", "/tools/", "index.test.ts", "common.test.ts"]
}