(condition, message)
| 13 | import chalk from "chalk"; |
| 14 | |
| 15 | function invariant(condition, message) { |
| 16 | if (!condition) { |
| 17 | console.error(chalk.bold.red(message)); |
| 18 | process.exit(1); |
| 19 | } |
| 20 | } |
| 21 | |
| 22 | // Executing publish script: node path/to/publish.mjs {name} --version {version} --tag {tag} |
| 23 | // Default "tag" to "next" so we won't publish the "latest" tag by accident. |