- Replaces custom release and changelog logic with auto-changelog action
- Reduces complexity and maintenance effort in the release process
- Ensures consistent changelog generation and release creation
- Introduces detection for 'zstd' to handle .zst archives if available
- Adds checksum verification and decompression for .zst files
- Falls back to uncompressed binary download if 'zstd' is unavailable
- Improves installation flexibility and reduces binary download size
- Ensures reproducible builds by adding the `--locked` flag to cargo install
- Improves dependency resolution consistency during git-cliff installation
- Introduce functions to validate CLI inputs like paths, identifiers, and environment variables
- Add error messages for invalid inputs to support user feedback
- Include unit tests to ensure correctness and robustness of validation logic
- Introduces compile steps for amd64 and arm64 targets in CI workflow
- Updates failure condition to include compile step outcomes
- Enhances local CI task to include amd64 build process
- Add `@std/jsonc` as a dependency in `deno.jsonc` and `deno.lock`
- Update i18n loader to support `.jsonc` files with comments
- Rename locale files from `.json` to `.jsonc` and add inline comments
- Set VSCode to use Deno JSONC formatter for `jsonc` files
This change enables the i18n module to load translation files written in JSONC format, allowing for inline comments and improved readability. The `@std/jsonc` library is added as a dependency and used to parse both JSON and JSONC files. The loader prioritizes `.jsonc` files when both `.json` and `.jsonc` exist. VSCode settings are updated to use the Deno formatter for JSONC files. Locale files are renamed and enhanced with comments for clarity.
Merged from feature/change-language-json-to-jsonc into main
- Adds inline comments to JSON files to improve readability
- Renames `.json` files to `.jsonc` to support comments
- Improves organization of translation entries
- Add tests for rollback behavior in `writeUnitFiles` on errors
- Simulate file write and delete failures in test scenarios
- Log rollback failures when file deletion is not possible
- Update all test descriptions and comments to English
- Add `testing/mock.ts` dependency in `deno.lock`
This change adds comprehensive tests for the `writeUnitFiles` function to verify that files are properly rolled back if errors occur during their creation. The tests simulate failures when writing `.service` or `.timer` files, as well as when file deletion is blocked, and check that the function responds by cleaning up as expected or logging rollback failures. All test comments and descriptions have been updated to English for clarity. The `testing/mock.ts` dependency was added to enable function stubbing in tests.
#2
Merged from test/fail-write-and-rollback into main
- Add tests to verify rollback behavior when file writing fails
- Simulate various error scenarios to ensure proper cleanup
- Log rollback failures when file deletion is prohibited
- Introduces a CI workflow triggered on push, pull requests, and manual dispatch
- Includes steps for code formatting, linting, and testing using Deno
- Fails the workflow if any of the steps do not succeed
- Centralize CLI text strings using the i18n module for localization
- Refactor `createCommand` and `createCli` to improve modularity
- Update logging and error messages to use translated strings
- Add tests for `loadLocale` to verify translations load correctly
- Add tests for `t` to ensure fallback behavior for missing keys
- Add tests for `getCurrentLanguage` to validate language detection logic
- Introduce functions to initialize and load locale files dynamically
- Add support for translation keys with placeholder replacements
- Default to English if locale files are missing or not found
- Determine system language using environment variables