feat(publish): add registry resolution (useBase/extendBase) and migrate filesystem operations to async SmartFs; improve publish flow and docs

This commit is contained in:
2025-12-16 12:29:39 +00:00
parent 47fdb00d5b
commit 0f1fa22c46
10 changed files with 2792 additions and 2280 deletions

View File

@@ -9,6 +9,10 @@
`@git.zone/tspublish` is your Swiss Army knife for managing and publishing multiple TypeScript packages from a monorepo. It automates the tedious parts of package publishing while giving you full control over the process. Whether you're maintaining a suite of microservices, a component library, or any collection of related packages, tspublish makes your life easier.
## Issue Reporting and Security
For reporting bugs, issues, or security vulnerabilities, please visit [community.foss.global/](https://community.foss.global/). This is the central community hub for all issue reporting. Developers who sign and comply with our contribution agreement and go through identification can also get a [code.foss.global/](https://code.foss.global/) account to submit Pull Requests directly.
### ✨ Key Features
- 📦 **Automatic Package Discovery** - Scans your monorepo for publishable packages
@@ -149,7 +153,11 @@ for (const [name, config] of Object.entries(modules)) {
### Registry Configuration
TSPublish supports multiple registries with different access levels:
TSPublish supports multiple registries with different access levels. You have three approaches:
#### 1⃣ Explicit Registries
Define specific registries directly in your `tspublish.json`:
```json
{
@@ -161,6 +169,38 @@ TSPublish supports multiple registries with different access levels:
}
```
#### 2⃣ Use Base Configuration (`useBase`)
Inherit registries from your project's `npmextra.json` configuration (managed by `gitzone config`):
```json
{
"registries": ["useBase"]
}
```
This reads from `npmextra.json` under `@git.zone/cli.release.registries`.
#### 3⃣ Extend Base Configuration (`extendBase`)
Start with base registries and add/remove specific ones:
```json
{
"registries": [
"extendBase",
"custom-registry.example.com:public",
"-https://registry.npmjs.org" // Exclude this registry
]
}
```
The `-` prefix excludes a registry from the base configuration.
#### Empty Registries
If no registries are configured, the package will be built but **not published** (a warning is logged).
### Build Order Management
When packages depend on each other, use the `order` field to ensure correct build sequence:
@@ -346,30 +386,27 @@ interface ITsPublishJson {
- Check that all dependencies are installed
- Review the build output for specific errors
## 🔮 Future Features
- 🎯 Selective publishing with pattern matching
- 🔄 Automatic version bumping strategies
- 📊 Dry-run mode with detailed preview
- 🏷️ Git tag integration
- 📝 Changelog generation
- 🔐 Enhanced authentication handling
**useBase/extendBase error**
- Ensure your `npmextra.json` has registries configured at `@git.zone/cli.release.registries`
- Use `gitzone config add <registry-url>` to configure base registries
## License and Legal Information
This repository contains open-source code that is licensed under the MIT License. A copy of the MIT License can be found in the [license](license) file within this repository.
This repository contains open-source code licensed under the MIT License. A copy of the license can be found in the [LICENSE](./LICENSE) file.
**Please note:** The MIT License does not grant permission to use the trade names, trademarks, service marks, or product names of the project, except as required for reasonable and customary use in describing the origin of the work and reproducing the content of the NOTICE file.
### Trademarks
This project is owned and maintained by Task Venture Capital GmbH. The names and logos associated with Task Venture Capital GmbH and any related products or services are trademarks of Task Venture Capital GmbH and are not included within the scope of the MIT license granted herein. Use of these trademarks must comply with Task Venture Capital GmbH's Trademark Guidelines, and any usage must be approved in writing by Task Venture Capital GmbH.
This project is owned and maintained by Task Venture Capital GmbH. The names and logos associated with Task Venture Capital GmbH and any related products or services are trademarks of Task Venture Capital GmbH or third parties, and are not included within the scope of the MIT license granted herein.
Use of these trademarks must comply with Task Venture Capital GmbH's Trademark Guidelines or the guidelines of the respective third-party owners, and any usage must be approved in writing. Third-party trademarks used herein are the property of their respective owners and used only in a descriptive manner, e.g. for an implementation of an API or similar.
### Company Information
Task Venture Capital GmbH
Registered at District court Bremen HRB 35230 HB, Germany
Task Venture Capital GmbH
Registered at District Court Bremen HRB 35230 HB, Germany
For any legal inquiries or if you require further information, please contact us via email at hello@task.vc.
For any legal inquiries or further information, please contact us via email at hello@task.vc.
By using this repository, you acknowledge that you have read this section, agree to comply with its terms, and understand that the licensing of the code does not imply endorsement by Task Venture Capital GmbH of any derivative works.