Compare commits

...

4 Commits

Author SHA1 Message Date
f0adff8784 v2.12.0
Some checks failed
Default (tags) / security (push) Failing after 0s
Default (tags) / test (push) Failing after 0s
Default (tags) / release (push) Has been skipped
Default (tags) / metadata (push) Has been skipped
2025-12-15 17:34:36 +00:00
fb453e62c3 feat(ci,test): feat(ci/test): add test scaffold, GitLab CI, update gitea workflows and .gitignore 2025-12-15 17:34:36 +00:00
001721a8e9 v2.11.1
Some checks failed
Default (tags) / security (push) Failing after 0s
Default (tags) / test (push) Failing after 0s
Default (tags) / release (push) Has been skipped
Default (tags) / metadata (push) Has been skipped
2025-12-15 17:30:51 +00:00
b191464ff9 fix(mod_format/formatters): fix(packagejson.formatter): correctly parse scoped package dependency arguments and default to latest 2025-12-15 17:30:51 +00:00
10 changed files with 130 additions and 36 deletions

View File

@@ -6,19 +6,19 @@ on:
- '**'
env:
IMAGE: code.foss.global/hosttoday/ht-docker-node:npmci
NPMCI_COMPUTED_REPOURL: https://${{gitea.repository_owner}}:${{secrets.GITEA_TOKEN}}@/${{gitea.repository}}.git
NPMCI_TOKEN_NPM: ${{secrets.NPMCI_TOKEN_NPM}}
NPMCI_TOKEN_NPM2: ${{secrets.NPMCI_TOKEN_NPM2}}
NPMCI_GIT_GITHUBTOKEN: ${{secrets.NPMCI_GIT_GITHUBTOKEN}}
NPMCI_URL_CLOUDLY: ${{secrets.NPMCI_URL_CLOUDLY}}
IMAGE: code.foss.global/host.today/ht-docker-node:npmci
NPMCI_COMPUTED_REPOURL: https://${-{gitea.repository_owner}-}:${-{secrets.GITEA_TOKEN}-}@{{module.githost}}/${-{gitea.repository}-}.git
NPMCI_TOKEN_NPM: ${-{secrets.NPMCI_TOKEN_NPM}-}
NPMCI_TOKEN_NPM2: ${-{secrets.NPMCI_TOKEN_NPM2}-}
NPMCI_GIT_GITHUBTOKEN: ${-{secrets.NPMCI_GIT_GITHUBTOKEN}-}
NPMCI_URL_CLOUDLY: ${-{secrets.NPMCI_URL_CLOUDLY}-}
jobs:
security:
runs-on: ubuntu-latest
continue-on-error: true
container:
image: ${{ env.IMAGE }}
image: ${-{ env.IMAGE }-}
steps:
- uses: actions/checkout@v3
@@ -44,11 +44,11 @@ jobs:
continue-on-error: true
test:
if: ${{ always() }}
if: ${-{ always() }-}
needs: security
runs-on: ubuntu-latest
container:
image: ${{ env.IMAGE }}
image: ${-{ env.IMAGE }-}
steps:
- uses: actions/checkout@v3

View File

@@ -6,19 +6,19 @@ on:
- '*'
env:
IMAGE: code.foss.global/hosttoday/ht-docker-node:npmci
NPMCI_COMPUTED_REPOURL: https://${{gitea.repository_owner}}:${{secrets.GITEA_TOKEN}}@/${{gitea.repository}}.git
NPMCI_TOKEN_NPM: ${{secrets.NPMCI_TOKEN_NPM}}
NPMCI_TOKEN_NPM2: ${{secrets.NPMCI_TOKEN_NPM2}}
NPMCI_GIT_GITHUBTOKEN: ${{secrets.NPMCI_GIT_GITHUBTOKEN}}
NPMCI_URL_CLOUDLY: ${{secrets.NPMCI_URL_CLOUDLY}}
IMAGE: code.foss.global/host.today/ht-docker-node:npmci
NPMCI_COMPUTED_REPOURL: https://${-{gitea.repository_owner}-}:${-{secrets.GITEA_TOKEN}-}@{{module.githost}}/${-{gitea.repository}-}.git
NPMCI_TOKEN_NPM: ${-{secrets.NPMCI_TOKEN_NPM}-}
NPMCI_TOKEN_NPM2: ${-{secrets.NPMCI_TOKEN_NPM2}-}
NPMCI_GIT_GITHUBTOKEN: ${-{secrets.NPMCI_GIT_GITHUBTOKEN}-}
NPMCI_URL_CLOUDLY: ${-{secrets.NPMCI_URL_CLOUDLY}-}
jobs:
security:
runs-on: ubuntu-latest
continue-on-error: true
container:
image: ${{ env.IMAGE }}
image: ${-{ env.IMAGE }-}
steps:
- uses: actions/checkout@v3
@@ -42,11 +42,11 @@ jobs:
continue-on-error: true
test:
if: ${{ always() }}
if: ${-{ always() }-}
needs: security
runs-on: ubuntu-latest
container:
image: ${{ env.IMAGE }}
image: ${-{ env.IMAGE }-}
steps:
- uses: actions/checkout@v3
@@ -74,7 +74,7 @@ jobs:
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')
runs-on: ubuntu-latest
container:
image: ${{ env.IMAGE }}
image: ${-{ env.IMAGE }-}
steps:
- uses: actions/checkout@v3
@@ -95,7 +95,7 @@ jobs:
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')
runs-on: ubuntu-latest
container:
image: ${{ env.IMAGE }}
image: ${-{ env.IMAGE }-}
continue-on-error: true
steps:

6
.gitignore vendored
View File

@@ -3,8 +3,6 @@
# artifacts
coverage/
public/
test/
test2/
# installs
node_modules/
@@ -18,6 +16,10 @@ node_modules/
dist/
dist_*/
# AI
.claude/
.serena/
#------# custom
.serena
test-output.json

View File

@@ -1,6 +1,24 @@
# Changelog
## 2025-12-15 - 2.12.0 - feat(ci,test)
feat(ci/test): add test scaffold, GitLab CI, update gitea workflows and .gitignore
- Add comprehensive test/ scaffold including sample tests, test package.json, npmextra.json, test fixtures and TypeScript test sources
- Add GitLab CI pipeline (test/.gitlab-ci.yml), test-specific .npmrc, VSCode launch/settings and supporting qenv/readme files for CI/local test runs
- Update .gitea workflow YAML files to use templated placeholders and corrected container image path for CI execution
- Update .gitignore to exclude AI assistant and tooling dirs (.claude/, .serena/) and add test/.gitignore to ignore test artifacts
- Update changelog and documentation files to reflect recent formatter/commit/service changes and the new test/CI additions
## 2025-12-15 - 2.11.1 - fix(mod_format/formatters)
fix(packagejson.formatter): correctly parse scoped package dependency arguments and default to latest
- Handle scoped packages (e.g. @scope/name@version) by detecting the last '@' after the scope slash so package name and version are split correctly.
- Fallback to 'latest' when no version is provided.
- Fixes earlier incorrect splitting on every '@' which broke scoped package names.
## 2025-12-15 - 2.11.0 - feat(mod_format)
feat(mod_format): use unified diff formatter with filenames and context in BaseFormatter.displayDiff
- Replaced plugins.smartdiff.formatLineDiffForConsole(...) with plugins.smartdiff.formatUnifiedDiffForConsole(...) when both before and after are present.
@@ -8,6 +26,7 @@ feat(mod_format): use unified diff formatter with filenames and context in BaseF
- Improves console output for multi-line diffs by using unified diff format and including file names.
## 2025-12-15 - 2.10.0 - feat(mod_format)
Refactor formatting modules to new BaseFormatter and implement concrete analyze/apply logic
- Replace generic LegacyFormatter with explicit BaseFormatter implementations for formatters: copy, gitignore, license, npmextra, packagejson, prettier, readme, templates, tsconfig (legacy.formatter.ts removed).
@@ -23,6 +42,7 @@ Refactor formatting modules to new BaseFormatter and implement concrete analyze/
- General: extensive use of plugins (smartfs, path, smartnpm, smartinteract, smartobject, smartlegal), improved logging and verbose messages.
## 2025-12-15 - 2.9.0 - feat(format)
Add --diff option to format command to display file diffs; pass flag through CLI and show formatter diffs. Bump @git.zone/tsdoc to ^1.11.0.
- Add a diff boolean option to mod_format to enable showing file diffs during format operations.
@@ -31,6 +51,7 @@ Add --diff option to format command to display file diffs; pass flag through CLI
- Update dependency @git.zone/tsdoc from ^1.10.2 to ^1.11.0.
## 2025-12-15 - 2.8.0 - feat(commit)
Add commit configuration and automatic pre-commit tests
- Add CommitConfig class to manage @git.zone/cli.commit settings in npmextra.json (alwaysTest, alwaysBuild).
@@ -42,6 +63,7 @@ Add commit configuration and automatic pre-commit tests
- Add 'gitzone config services' entry to configure services via ServiceManager.
## 2025-12-14 - 2.7.0 - feat(mod_format)
Add check-only formatting with interactive diff preview; make formatting default to dry-run and extend formatting API
- Add BaseFormatter.check(), displayDiff() and displayAllDiffs() to compute and render diffs without applying changes.
@@ -54,6 +76,7 @@ Add check-only formatting with interactive diff preview; make formatting default
- Bump dependency @push.rocks/smartdiff to ^1.1.0.
## 2025-12-14 - 2.6.1 - fix(npmextra)
Normalize npmextra.json: move tsdoc legal entry and reposition @git.zone/cli configuration
- Move TSDoc legal text into a top-level "tsdoc.legal" property in npmextra.json
@@ -62,6 +85,7 @@ Normalize npmextra.json: move tsdoc legal entry and reposition @git.zone/cli con
- Pure configuration change (JSON structure) — no functional code changes
## 2025-12-14 - 2.6.0 - feat(mod_commit)
Add execution plan output to commit command
- Print an execution plan at the start of the commit flow (shows active options and planned steps)
@@ -70,6 +94,7 @@ Add execution plan output to commit command
- Execution plan reflects flags: auto-accept (-y), push (-p), build (-b), release (-r), --format, and target registries
## 2025-12-14 - 2.5.0 - feat(mod_standard)
Add interactive main menu and help to standard CLI module; route commands via dynamic imports
- Introduce interactive CLI menu using @push.rocks/smartinteract to prompt user for actions.
@@ -78,6 +103,7 @@ Add interactive main menu and help to standard CLI module; route commands via dy
- Remove previous static template listing and logger.warn placeholder.
## 2025-12-14 - 2.4.0 - feat(cli)
Add optional build step to release flow and auto-format npmextra config when registries change
- Introduce a --build/-b flag in the commit/release flow to run 'pnpm build' before pushing/releases
@@ -88,6 +114,7 @@ Add optional build step to release flow and auto-format npmextra config when reg
- Add npmextra registry config entry (https://verdaccio.lossless.digital) to npmextra.json
## 2025-12-14 - 2.3.0 - feat(config)
Add interactive menu and help to config command, handle unknown commands, and bump dependencies
- When running the 'config' command with no arguments, show an interactive menu (via SmartInteract) to choose actions (show, add, remove, clear, access, help) instead of defaulting to 'show'.
@@ -96,6 +123,7 @@ Add interactive menu and help to config command, handle unknown commands, and bu
- Update dependency: @push.rocks/smartjson -> ^6.0.0.
## 2025-12-04 - 2.2.1 - fix(commit)
Prevent auto-accept for BREAKING CHANGE commits; require manual confirmation and warn when --yes is used
- Do not auto-accept AI commit recommendations when the suggested change is a BREAKING CHANGE (major bump).
@@ -104,6 +132,7 @@ Prevent auto-accept for BREAKING CHANGE commits; require manual confirmation and
- Introduced isBreakingChange and canAutoAccept flags to centralize the auto-accept logic.
## 2025-12-02 - 2.2.0 - feat(services)
Improve services manager and configuration; switch test templates to @git.zone/tstest; bump dev dependencies and update docs
- services: Add robust ServiceConfiguration (creates .nogit/env.json with sane defaults, syncs ports from existing Docker containers, validates and can reconfigure ports)
@@ -114,6 +143,7 @@ Improve services manager and configuration; switch test templates to @git.zone/t
- docs: README updates — add issue reporting/security section, AI-powered commit recommendation notes, and clarify trademark/legal wording
## 2025-11-29 - 2.1.0 - feat(mod_services)
Add global service registry and global commands for managing project containers
- Introduce GlobalRegistry class to track registered projects, their containers, ports and last activity (ts/mod_services/classes.globalregistry.ts)
@@ -123,30 +153,34 @@ Add global service registry and global commands for managing project containers
- Bump dependency @push.rocks/smartfile to ^13.1.0 in package.json
## 2025-11-27 - 2.0.0 - BREAKING CHANGE(core)
Migrate filesystem to smartfs (async) and add Elasticsearch service support; refactor format/commit/meta modules
- Replace @push.rocks/smartfile usage with @push.rocks/smartfs across the codebase; all filesystem operations are now async (SmartFs.file(...).read()/write(), SmartFs.directory(...).list()/create()/delete(), etc.)
- Convert formerly synchronous helpers and APIs to async (notable: detectProjectType, getProjectName, readCurrentVersion and related version bumping logic). Callers updated accordingly.
- Add Elasticsearch support to services: new config fields (ELASTICSEARCH_*), Docker run/start/stop/logs/status handling, and ELASTICSEARCH_URL in service configuration.
- Add Elasticsearch support to services: new config fields (ELASTICSEARCH\_\*), Docker run/start/stop/logs/status handling, and ELASTICSEARCH_URL in service configuration.
- Refactor formatting subsystem: cache and rollback/backup systems removed/disabled for stability, format planner execution simplified (sequential), diff/stats reporting updated to use smartfs.
- Update package.json dependencies: bump @git.zone/tsbuild, tsrun, tstest; upgrade @push.rocks/smartfile to v13 and add @push.rocks/smartfs dependency; update @types/node.
- Update commit flow and changelog generation to use smartfs for reading/writing files and to await version/branch detection where necessary.
- Expose a SmartFs instance via plugins and adjust all mod.* plugin files to import/use smartfs where required.
- Expose a SmartFs instance via plugins and adjust all mod.\* plugin files to import/use smartfs where required.
- Breaking change: Public and internal APIs that previously used synchronous smartfile APIs are now asynchronous. Consumers and scripts must await these functions and use the new smartfs API.
## 2025-11-17 - 1.21.5 - fix(tsconfig)
Remove emitDecoratorMetadata from tsconfig template
- Removed the "emitDecoratorMetadata" compiler option from assets/templates/tsconfig_update/tsconfig.json
- This updates the tsconfig template to avoid emitting decorator metadata when targeting ES2022
## 2025-11-17 - 1.21.4 - fix(tsconfig template)
Remove experimentalDecorators and useDefineForClassFields from tsconfig template
- Removed experimentalDecorators option from assets/templates/tsconfig_update/tsconfig.json
- Removed useDefineForClassFields option from assets/templates/tsconfig_update/tsconfig.json
## 2025-11-17 - 1.21.3 - fix(assets/templates/multienv)
Remove unused Bun configuration template (assets/templates/multienv/bunfig.toml)
- Deleted assets/templates/multienv/bunfig.toml which previously provided Bun TypeScript decorator configuration
@@ -154,17 +188,20 @@ Remove unused Bun configuration template (assets/templates/multienv/bunfig.toml)
- No functional code changes; removes an unused asset file
## 2025-11-17 - 1.21.2 - fix(templates/multienv)
Disable useDefineForClassFields in multienv TypeScript configs to ensure decorator compatibility
- Set useDefineForClassFields = false in assets/templates/multienv/bunfig.toml to keep Bun's transpiler compatible with decorator usage
- Set "useDefineForClassFields": false in assets/templates/multienv/deno.json to ensure Deno/TypeScript compiler emits class fields compatible with decorators
## 2025-11-17 - 1.21.1 - fix(templates.multienv)
Enable checkJs in multienv Deno template to enable JS type checking
- Added "checkJs": true to compilerOptions in assets/templates/multienv/deno.json to enable JavaScript type checking for the Deno multienv template
## 2025-11-17 - 1.21.0 - feat(multienv)
Add multi-env templates enabling TypeScript decorators for Bun and Deno; rename npmextra config key to szci
- Added assets/templates/multienv/bunfig.toml to enable Bun TypeScript transpiler experimentalDecorators
@@ -172,6 +209,7 @@ Add multi-env templates enabling TypeScript decorators for Bun and Deno; rename
- Updated npmextra.json: renamed top-level config key from "npmci" to "szci" (keeps npmGlobalTools, npmAccessLevel and npmRegistryUrl unchanged)
## 2025-11-06 - 1.20.0 - feat(commit)
Add non-interactive --yes (-y) flag to commit command to auto-accept AI recommendations and optionally push with -p
- Add -y / --yes flag to gitzone commit to auto-accept AI-generated commit recommendations without interactive prompts
@@ -181,6 +219,7 @@ Add non-interactive --yes (-y) flag to commit command to auto-accept AI recommen
- Updated CLI usage and documentation (readme.hints.md) to document the new flags
## 2025-11-05 - 1.19.9 - fix(mod_commit)
Refactor version bumping to a unified implementation for npm and Deno; remove npm-exec based helpers and add file-based version readers/updaters to avoid npm warning pollution
- Removed legacy npm/deno-specific helpers (bumpNpmVersion, syncVersionToDenoJson, bumpDenoVersion) that relied on executing npm and caused warning pollution
@@ -191,39 +230,46 @@ Refactor version bumping to a unified implementation for npm and Deno; remove np
- Benefits: no npm warning pollution in deno.json, simpler git history, consistent behavior across project types
## 2025-11-04 - 1.19.8 - fix(package.json)
Bump @git.zone/tsdoc dependency to ^1.9.2
- Updated dependency @git.zone/tsdoc from ^1.9.1 to ^1.9.2 in package.json
## 2025-11-04 - 1.19.7 - fix(dependencies)
Bump @git.zone/tsdoc to ^1.9.1
- Updated package.json dependency @git.zone/tsdoc from ^1.9.0 to ^1.9.1
## 2025-11-04 - 1.19.6 - fix(cli)
Bump @git.zone/tsdoc dependency to ^1.9.0
- Updated dependency @git.zone/tsdoc from ^1.8.3 to ^1.9.0 in package.json
## 2025-11-04 - 1.19.5 - fix(cli)
Bump @git.zone/tsdoc to ^1.8.3 and add local .claude settings for allowed permissions
- Updated dependency @git.zone/tsdoc from ^1.8.2 to ^1.8.3
- Added .claude/settings.local.json to declare allowed permissions for local tooling (Bash commands, Docker, npm, WebFetch and MCP actions)
## 2025-11-03 - 1.19.3 - fix(tsdoc)
Bump @git.zone/tsdoc to ^1.8.0 and add .claude local settings
- Upgrade dependency @git.zone/tsdoc from ^1.6.1 to ^1.8.0 in package.json
- Add .claude/settings.local.json for local assistant permissions/configuration
## 2025-11-03 - 1.19.2 - fix(tsdoc)
Bump @git.zone/tsdoc to ^1.6.1 and add .claude/settings.local.json
- Update dependency @git.zone/tsdoc from ^1.6.0 to ^1.6.1
- Add .claude/settings.local.json to include local Claude settings/permissions
## 2025-11-02 - 1.19.1 - fix(dependencies)
Bump dependencies and add local Claude settings
- Bump devDependencies: @git.zone/tsbuild -> ^2.7.1, @git.zone/tsrun -> ^1.6.2, @git.zone/tstest -> ^2.7.0
@@ -231,6 +277,7 @@ Bump dependencies and add local Claude settings
- Add .claude/settings.local.json (local project permissions/settings file)
## 2025-10-23 - 1.19.0 - feat(mod_commit)
Add CLI UI helpers and improve commit workflow with progress, recommendations and summary
- Introduce ts/mod_commit/mod.ui.ts: reusable CLI UI helpers (pretty headers, sections, AI recommendation box, step printer, commit summary and helpers for consistent messaging).
@@ -239,6 +286,7 @@ Add CLI UI helpers and improve commit workflow with progress, recommendations an
- Add .claude/settings.local.json: local permissions configuration for development tooling.
## 2025-10-23 - 1.18.9 - fix(mod_commit)
Stage and commit deno.json when bumping/syncing versions and create/update git tags
- bumpDenoVersion now creates a Smartshell instance and runs git add deno.json, git commit -m "v<newVersion>", and git tag v<newVersion> to persist the version bump
@@ -246,6 +294,7 @@ Stage and commit deno.json when bumping/syncing versions and create/update git t
- Added informative logger messages after creating commits and tags
## 2025-10-23 - 1.18.8 - fix(mod_commit)
Improve commit workflow: detect project type and current branch; add robust version bump helpers for npm/deno
- Add mod_commit/mod.helpers.ts with utilities: detectCurrentBranch(), detectProjectType(), bumpProjectVersion(), bumpDenoVersion(), bumpNpmVersion(), syncVersionToDenoJson(), and calculateNewVersion()
@@ -255,12 +304,14 @@ Improve commit workflow: detect project type and current branch; add robust vers
- Add local Claude settings file (.claude/settings.local.json) (editor/CI config) — no code behavior change but included in diff
## 2025-09-07 - 1.18.7 - fix(claude)
Add .claude local settings to whitelist dev tool permissions
- Add .claude/settings.local.json to configure allowed permissions for local AI/tooling helpers (Bash commands, WebFetch, and mcp_serena actions).
- Disable enableAllProjectMcpServers (set to false) to limit automatic project MCP server usage.
## 2025-09-07 - 1.18.6 - fix(deps)
Bump dependency versions and add local Claude settings
- Updated devDependencies: @git.zone/tsbuild ^2.6.4 → ^2.6.8, @git.zone/tstest ^2.3.4 → ^2.3.6, @push.rocks/smartfile ^11.2.5 → ^11.2.7
@@ -268,6 +319,7 @@ Bump dependency versions and add local Claude settings
- Added .claude/settings.local.json to configure local Claude permissions/settings
## 2025-08-17 - 1.18.5 - fix(dependencies)
Bump smartshell and smartscaf versions; add .claude local settings
- Update @push.rocks/smartshell from ^3.2.4 to ^3.3.0 in package.json
@@ -275,6 +327,7 @@ Bump smartshell and smartscaf versions; add .claude local settings
- Add .claude/settings.local.json for local assistant permissions/configuration
## 2025-08-17 - 1.18.4 - fix(cli)
Update dependencies, add local Claude settings, and update gitignore template
- Bump several dependencies: @git.zone/tsbuild -> ^2.6.4, @git.zone/tspublish -> ^1.10.1, @git.zone/tstest -> ^2.3.4, @push.rocks/smartfile -> ^11.2.5, @push.rocks/npmextra -> ^5.3.3, @push.rocks/smartchok -> ^1.1.1, @push.rocks/smartlog -> ^3.1.8, @push.rocks/smartpath -> ^6.0.0, prettier -> ^3.6.2
@@ -283,6 +336,7 @@ Update dependencies, add local Claude settings, and update gitignore template
- Add pnpm onlyBuiltDependencies entries: esbuild and mongodb-memory-server
## 2025-08-16 - 1.18.3 - fix(services)
Simplify S3 endpoint handling in ServiceConfiguration to store host only
- S3_ENDPOINT now stores the raw host (e.g. 'localhost') instead of a full URL with protocol and port.
@@ -291,6 +345,7 @@ Simplify S3 endpoint handling in ServiceConfiguration to store host only
- Consumers that previously relied on S3_ENDPOINT containing protocol and port should now construct the full endpoint URL using S3_USESSL, S3_HOST and S3_PORT.
## 2025-08-16 - 1.18.1 - fix(services)
Improve services and commit flow: stop AiDoc, use silent docker inspect, sync ports with logging, fix config loading, and bump deps
- Ensure AiDoc is stopped after building commit recommendation to avoid resource leaks
@@ -302,6 +357,7 @@ Improve services and commit flow: stop AiDoc, use silent docker inspect, sync po
- Add local Claude settings file (.claude/settings.local.json) with development permissions
## 2025-08-16 - 1.18.0 - feat(services)
Add Docker port mapping sync and reconfigure workflow for local services
- Add getPortMappings to DockerContainer to extract port bindings from docker inspect output
@@ -314,6 +370,7 @@ Add Docker port mapping sync and reconfigure workflow for local services
- Add .claude/settings.local.json (local permissions config) to repository
## 2025-08-15 - 1.17.5 - fix(services)
Update S3 credentials naming and add S3_ENDPOINT/S3_USESSL support for improved MinIO integration
- Replaced S3_USER/S3_PASS with S3_ACCESSKEY/S3_SECRETKEY in ServiceConfiguration
@@ -323,6 +380,7 @@ Update S3 credentials naming and add S3_ENDPOINT/S3_USESSL support for improved
- Added .claude/settings.local.json for local permission settings
## 2025-08-15 - 1.17.4 - fix(services)
Update S3 credentials naming and add S3_ENDPOINT/S3_USESSL support for improved MinIO integration
- Replaced S3_USER/S3_PASS with S3_ACCESSKEY/S3_SECRETKEY in ServiceConfiguration
@@ -331,12 +389,14 @@ Update S3 credentials naming and add S3_ENDPOINT/S3_USESSL support for improved
- Updated ServiceManager to use new credential names in container setup and logging
## 2025-08-15 - 1.17.3 - fix(serviceconfig)
Update service configuration to include dynamic MongoDB connection string and add local permissions settings
- Added .claude/settings.local.json for local permissions configuration
- Updated ServiceConfiguration to compute and update MONGODB_URL based on current config values
## 2025-08-15 - 1.17.2 - fix(ci-test-services)
Update CI/CD configurations, test settings, and Docker service for MongoDB.
- Add .claude/settings.local.json with updated permission settings
@@ -345,6 +405,7 @@ Update CI/CD configurations, test settings, and Docker service for MongoDB.
- Fix MongoDB Docker container command by adding '--bind_ip_all' for proper network binding
## 2025-08-15 - 1.17.1 - fix(services)
Improve services module logging and enhance MongoDB Compass integration
- Refactored services module to use centralized logger from gitzone.logging.ts
@@ -353,6 +414,7 @@ Improve services module logging and enhance MongoDB Compass integration
- Consistent logging across all service commands
## 2025-08-14 - 1.17.0 - feat(services)
Add comprehensive development services management for MongoDB and MinIO containers
- Implemented `gitzone services` command for managing local development services
@@ -366,6 +428,7 @@ Add comprehensive development services management for MongoDB and MinIO containe
- Interactive confirmations for destructive operations
## 2025-08-08 - 1.16.10 - fix(format)
Improve concurrency control in caching and rollback modules, refine gitignore custom section handling, and enhance Prettier file processing.
- Added mutex locking in ChangeCache and RollbackManager to prevent race conditions during manifest updates

View File

@@ -1,7 +1,7 @@
{
"name": "@git.zone/cli",
"private": false,
"version": "2.11.0",
"version": "2.12.0",
"description": "A comprehensive CLI tool for enhancing and managing local development workflows with gitzone utilities, focusing on project setup, version control, code formatting, and template management.",
"main": "dist_ts/index.ts",
"typings": "dist_ts/index.d.ts",

View File

@@ -96,6 +96,7 @@ The format module is responsible for project standardization:
The commit module's version bumping has been refactored to eliminate npm command dependencies:
**Changes:**
- Removed `bumpNpmVersion()` - was causing npm warnings to pollute deno.json
- Removed `syncVersionToDenoJson()` - no longer needed with unified approach
- Removed separate `bumpDenoVersion()` - replaced by unified implementation
@@ -104,6 +105,7 @@ The commit module's version bumping has been refactored to eliminate npm command
- Unified `bumpProjectVersion()` - handles npm/deno/both with single clean code path
**Benefits:**
- No npm warning pollution in version fields
- Full control over version bumping process
- Simpler git history (no amending, no force-tagging)
@@ -115,11 +117,13 @@ The commit module's version bumping has been refactored to eliminate npm command
The commit module now supports `-y/--yes` flag for non-interactive commits:
**Usage:**
- `gitzone commit -y` - Auto-accepts AI recommendations without prompts
- `gitzone commit -yp` - Auto-accepts and pushes to origin
- Separate `-p/--push` flag controls push behavior
**Implementation:**
- Creates AnswerBucket programmatically when `-y` flag detected
- Preserves all UI output for transparency
- Fully backward compatible with interactive mode
@@ -248,10 +252,12 @@ gitzone format --clean-backups
The project has been fully migrated from @push.rocks/smartfile v11 to v13, which introduced a major breaking change where filesystem operations were split into two separate packages:
**Packages:**
- `@push.rocks/smartfile` v13.0.1 - File representation classes (SmartFile, StreamFile, VirtualDirectory)
- `@push.rocks/smartfs` v1.1.0 - Filesystem operations (read, write, exists, stat, etc.)
**Key API Changes:**
1. **File Reading**:
- Old: `plugins.smartfile.fs.toStringSync(path)` or `plugins.smartfile.fs.toObjectSync(path)`
- New: `await plugins.smartfs.file(path).encoding('utf8').read()` + JSON.parse if needed
@@ -290,13 +296,15 @@ The project has been fully migrated from @push.rocks/smartfile v11 to v13, which
All sync methods must become async. Functions that were previously synchronous (like `getProjectName()`) now return `Promise<T>` and must be awaited.
**Affected Modules:**
- ts/mod_format/* (largest area - 15+ files)
- ts/mod_commit/* (version bumping)
- ts/mod_services/* (configuration management)
- ts/mod_meta/* (meta repository management)
- ts/mod_standard/* (template listing)
- ts/mod_template/* (template operations)
- ts/mod_format/\* (largest area - 15+ files)
- ts/mod_commit/\* (version bumping)
- ts/mod_services/\* (configuration management)
- ts/mod_meta/\* (meta repository management)
- ts/mod_standard/\* (template listing)
- ts/mod_template/\* (template operations)
**Previous API Changes:**
- smartnpm requires instance creation: `new NpmRegistry()`
- Type imports use `import type` for proper verbatim module syntax

View File

@@ -1,11 +1,13 @@
# GitZone Services Command Implementation Plan
## Overview
Implement the `gitzone services` command to manage MongoDB and MinIO containers for development projects.
## Tasks
### Module Structure Setup
- [x] Create `ts/mod_services/` directory
- [x] Create `mod.plugins.ts` with required imports
- [x] Create `helpers.ts` with utility functions
@@ -15,6 +17,7 @@ Implement the `gitzone services` command to manage MongoDB and MinIO containers
- [x] Create `index.ts` with main command logic
### Core Functionality
- [x] Implement ServiceConfiguration class
- [x] Load/create `.nogit/env.json` configuration
- [x] Generate random available ports (20000-30000 range)
@@ -37,6 +40,7 @@ Implement the `gitzone services` command to manage MongoDB and MinIO containers
- [x] Generate MongoDB Compass connection strings
### Commands Implementation
- [x] `start` command - Start services (mongo|s3|all)
- [x] `stop` command - Stop services (mongo|s3|all)
- [x] `restart` command - Restart services (mongo|s3|all)
@@ -48,12 +52,14 @@ Implement the `gitzone services` command to manage MongoDB and MinIO containers
- [x] `clean` command - Remove containers and data
### Integration
- [x] Add `@push.rocks/smartshell` to main plugins.ts
- [x] Add `@push.rocks/smartnetwork` to main plugins.ts
- [x] Add `@push.rocks/smartinteraction` to main plugins.ts
- [x] Register services command in `gitzone.cli.ts`
### Features
- [x] Auto-configuration with smart defaults
- [x] Random port assignment to avoid conflicts
- [x] Project isolation with unique container names
@@ -65,6 +71,7 @@ Implement the `gitzone services` command to manage MongoDB and MinIO containers
- [x] MongoDB Compass connection string with network IP
### Testing
- [ ] Test service start/stop operations
- [ ] Test configuration creation and updates
- [ ] Test port collision handling
@@ -73,6 +80,7 @@ Implement the `gitzone services` command to manage MongoDB and MinIO containers
- [ ] Test all command variations
## Configuration Format
```json
{
"PROJECT_NAME": "derived-from-package-name",
@@ -91,6 +99,7 @@ Implement the `gitzone services` command to manage MongoDB and MinIO containers
```
## Command Examples
```bash
gitzone services start # Start all services
gitzone services start mongo # Start only MongoDB
@@ -104,10 +113,12 @@ gitzone services clean # Remove containers and data
```
## Progress Notes
Implementation started: 2025-08-14
Implementation completed: 2025-08-14
## Summary
Successfully implemented the `gitzone services` command in TypeScript, providing a complete replacement for the `services.sh` shell script. The implementation includes:
1. **Complete Docker service management** for MongoDB and MinIO containers

1
test Submodule

Submodule test added at 0b89443584

View File

@@ -3,6 +3,6 @@
*/
export const commitinfo = {
name: '@git.zone/cli',
version: '2.11.0',
version: '2.12.0',
description: 'A comprehensive CLI tool for enhancing and managing local development workflows with gitzone utilities, focusing on project setup, version control, code formatting, and template management.'
}

View File

@@ -13,9 +13,18 @@ const ensureDependency = async (
constraint: 'exclude' | 'include' | 'latest',
dependencyArg: string,
): Promise<void> => {
const [packageName, version] = dependencyArg.includes('@')
? dependencyArg.split('@').filter(Boolean)
: [dependencyArg, 'latest'];
// Parse package name and version, handling scoped packages like @scope/name@version
const isScoped = dependencyArg.startsWith('@');
const lastAtIndex = dependencyArg.lastIndexOf('@');
// For scoped packages, the version @ must come after the /
// For unscoped packages, any @ indicates a version
const hasVersion = isScoped
? lastAtIndex > dependencyArg.indexOf('/')
: lastAtIndex >= 0;
const packageName = hasVersion ? dependencyArg.slice(0, lastAtIndex) : dependencyArg;
const version = hasVersion ? dependencyArg.slice(lastAtIndex + 1) : 'latest';
const targetSections: string[] = [];