mirror of
https://github.com/tailwindlabs/tailwindcss.git
synced 2025-12-08 21:36:08 +00:00
Ensure CLI builds have a non-zero exit code on failure (#10703)
* ensure simple builds have a non-zero exit code on failure This is not used for the watcher. * update changelog
This commit is contained in:
parent
0c9b3f9333
commit
1874798bdd
@ -23,6 +23,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
|
||||
- Disallow multiple selectors in arbitrary variants ([#10655](https://github.com/tailwindlabs/tailwindcss/pull/10655))
|
||||
- Sort class lists deterministically for Prettier plugin ([#10672](https://github.com/tailwindlabs/tailwindcss/pull/10672))
|
||||
- Ensure CLI builds have a non-zero exit code on failure ([#10703](https://github.com/tailwindlabs/tailwindcss/pull/10703))
|
||||
|
||||
### Changed
|
||||
|
||||
|
||||
@ -44,6 +44,9 @@ export async function build(args, configs) {
|
||||
|
||||
await processor.watch()
|
||||
} else {
|
||||
await processor.build()
|
||||
await processor.build().catch((e) => {
|
||||
console.error(e)
|
||||
process.exit(1)
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
@ -383,7 +383,11 @@ export async function createProcessor(args, cliConfigPath) {
|
||||
// The watcher will start watching the imported CSS files and will be
|
||||
// resilient to future errors.
|
||||
|
||||
console.error(err)
|
||||
if (state.watcher) {
|
||||
console.error(err)
|
||||
} else {
|
||||
return Promise.reject(err)
|
||||
}
|
||||
}
|
||||
)
|
||||
}
|
||||
|
||||
@ -42,6 +42,9 @@ export async function build(args, configs) {
|
||||
|
||||
await processor.watch()
|
||||
} else {
|
||||
await processor.build()
|
||||
await processor.build().catch((e) => {
|
||||
console.error(e)
|
||||
process.exit(1)
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
@ -380,7 +380,11 @@ export async function createProcessor(args, cliConfigPath) {
|
||||
// The watcher will start watching the imported CSS files and will be
|
||||
// resilient to future errors.
|
||||
|
||||
console.error(err)
|
||||
if (state.watcher) {
|
||||
console.error(err)
|
||||
} else {
|
||||
return Promise.reject(err)
|
||||
}
|
||||
}
|
||||
)
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user