Compare commits

..

7 Commits

Author SHA1 Message Date
7074a19a7f 1.18.4
Some checks failed
Default (tags) / security (push) Failing after 1s
Default (tags) / test (push) Failing after 1s
Default (tags) / release (push) Has been skipped
Default (tags) / metadata (push) Has been skipped
2025-08-17 13:31:39 +00:00
5774fb4da2 fix(cli): Update dependencies, add local Claude settings, and update gitignore template 2025-08-17 13:31:38 +00:00
be45ce765d 1.18.3
Some checks failed
Default (tags) / security (push) Failing after 1s
Default (tags) / test (push) Failing after 1s
Default (tags) / release (push) Has been skipped
Default (tags) / metadata (push) Has been skipped
2025-08-16 13:25:57 +00:00
2a250b8823 fix(services): Simplify S3 endpoint handling in ServiceConfiguration to store host only 2025-08-16 13:25:57 +00:00
9a436cb4be 1.18.2
Some checks failed
Default (tags) / security (push) Failing after 1s
Default (tags) / test (push) Failing after 1s
Default (tags) / release (push) Has been skipped
Default (tags) / metadata (push) Has been skipped
2025-08-16 11:51:28 +00:00
86782c39dd 1.18.1
Some checks failed
Default (tags) / security (push) Failing after 1s
Default (tags) / test (push) Failing after 1s
Default (tags) / release (push) Has been skipped
Default (tags) / metadata (push) Has been skipped
2025-08-16 11:38:21 +00:00
fba3e9d2b0 fix(services): Improve services and commit flow: stop AiDoc, use silent docker inspect, sync ports with logging, fix config loading, and bump deps 2025-08-16 11:38:21 +00:00
8 changed files with 3155 additions and 2213 deletions

View File

@@ -19,4 +19,8 @@ node_modules/
dist/
dist_*/
# AI
.claude/
.serena/
#------# custom

View File

@@ -1,5 +1,32 @@
# Changelog
## 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
- Add .claude/settings.local.json with local permissions configuration for AI tooling
- Update assets/templates/gitignore to ignore .claude/ and .serena/ directories
- 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.
- Default .nogit/env.json creation uses the host-only S3_ENDPOINT.
- Sync/update logic (when syncing with Docker or reconfiguring ports) sets S3_ENDPOINT to the 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
- Use execSilent for `docker inspect` in DockerContainer to avoid shell noise and improve JSON parsing
- Sync Docker-exposed ports into service configuration with explicit notes (logs) when MongoDB / S3 ports are updated
- Fix synchronous config loading by removing an unnecessary await in ServiceConfiguration.loadConfig
- Bump dependencies: @push.rocks/smartshell -> ^3.2.4, @git.zone/tsdoc -> ^1.5.1
- Add pnpm.onlyBuiltDependencies for puppeteer and sharp to package.json
- 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

View File

@@ -1,7 +1,7 @@
{
"name": "@git.zone/cli",
"private": false,
"version": "1.18.0",
"version": "1.18.4",
"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",
@@ -57,45 +57,45 @@
},
"homepage": "https://gitlab.com/gitzone/private/gitzone#readme",
"devDependencies": {
"@git.zone/tsbuild": "^2.3.2",
"@git.zone/tsbuild": "^2.6.4",
"@git.zone/tsrun": "^1.3.3",
"@git.zone/tstest": "^1.0.96",
"@git.zone/tstest": "^2.3.4",
"@push.rocks/smartdelay": "^3.0.5",
"@push.rocks/smartfile": "^11.2.0",
"@push.rocks/smartfile": "^11.2.5",
"@push.rocks/smartinteract": "^2.0.16",
"@push.rocks/smartnetwork": "^4.1.2",
"@push.rocks/smartshell": "^3.2.3",
"@push.rocks/smartshell": "^3.2.4",
"@types/node": "^22.15.18"
},
"dependencies": {
"@git.zone/tsdoc": "^1.5.0",
"@git.zone/tspublish": "^1.9.1",
"@git.zone/tsdoc": "^1.5.1",
"@git.zone/tspublish": "^1.10.1",
"@push.rocks/commitinfo": "^1.0.12",
"@push.rocks/early": "^4.0.4",
"@push.rocks/gulp-function": "^3.0.7",
"@push.rocks/lik": "^6.2.2",
"@push.rocks/npmextra": "^5.1.2",
"@push.rocks/npmextra": "^5.3.3",
"@push.rocks/projectinfo": "^5.0.2",
"@push.rocks/smartchok": "^1.0.34",
"@push.rocks/smartchok": "^1.1.1",
"@push.rocks/smartcli": "^4.0.11",
"@push.rocks/smartdiff": "^1.0.3",
"@push.rocks/smartgulp": "^3.0.4",
"@push.rocks/smartjson": "^5.0.20",
"@push.rocks/smartlegal": "^1.0.27",
"@push.rocks/smartlog": "^3.0.9",
"@push.rocks/smartlog": "^3.1.8",
"@push.rocks/smartlog-destination-local": "^9.0.2",
"@push.rocks/smartmustache": "^3.0.2",
"@push.rocks/smartnpm": "^2.0.4",
"@push.rocks/smartobject": "^1.0.12",
"@push.rocks/smartopen": "^2.0.0",
"@push.rocks/smartpath": "^5.0.18",
"@push.rocks/smartpath": "^6.0.0",
"@push.rocks/smartpromise": "^4.2.3",
"@push.rocks/smartscaf": "^4.0.16",
"@push.rocks/smartstream": "^3.2.5",
"@push.rocks/smartunique": "^3.0.9",
"@push.rocks/smartupdate": "^2.0.6",
"@types/through2": "^2.0.41",
"prettier": "^3.5.3",
"prettier": "^3.6.2",
"through2": "^4.0.2"
},
"files": [
@@ -114,7 +114,13 @@
"last 1 chrome versions"
],
"pnpm": {
"overrides": {}
"overrides": {},
"onlyBuiltDependencies": [
"esbuild",
"mongodb-memory-server",
"puppeteer",
"sharp"
]
},
"packageManager": "pnpm@10.7.0+sha512.6b865ad4b62a1d9842b61d674a393903b871d9244954f652b8842c2b553c72176b278f64c463e52d40fff8aba385c235c8c9ecf5cc7de4fd78b8bb6d49633ab6"
}

5277
pnpm-lock.yaml generated

File diff suppressed because it is too large Load Diff

View File

@@ -3,6 +3,6 @@
*/
export const commitinfo = {
name: '@git.zone/cli',
version: '1.18.0',
version: '1.18.4',
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

@@ -16,6 +16,8 @@ export const run = async (argvArg: any) => {
const nextCommitObject = await aidoc.buildNextCommitObject(paths.cwd);
await aidoc.stop();
logger.log(
'info',
`---------

View File

@@ -215,7 +215,7 @@ export class DockerContainer {
*/
public async inspect(containerName: string): Promise<any> {
try {
const result = await this.smartshell.exec(`docker inspect ${containerName} 2>/dev/null`);
const result = await this.smartshell.execSilent(`docker inspect ${containerName}`);
if (result.exitCode === 0) {
return JSON.parse(result.stdout);
}
@@ -231,7 +231,7 @@ export class DockerContainer {
public async getPortMappings(containerName: string): Promise<{ [key: string]: string } | null> {
try {
// Use docker inspect without format to get full JSON, then extract PortBindings
const result = await this.smartshell.exec(`docker inspect ${containerName} 2>/dev/null`);
const result = await this.smartshell.execSilent(`docker inspect ${containerName}`);
if (result.exitCode === 0 && result.stdout) {
const inspectData = JSON.parse(result.stdout);

View File

@@ -86,7 +86,7 @@ export class ServiceConfiguration {
* Load configuration from file
*/
private async loadConfig(): Promise<void> {
const configContent = await plugins.smartfile.fs.toStringSync(this.configPath);
const configContent = plugins.smartfile.fs.toStringSync(this.configPath);
this.config = JSON.parse(configContent);
}
@@ -126,7 +126,7 @@ export class ServiceConfiguration {
S3_ACCESSKEY: 'defaultadmin',
S3_SECRETKEY: 'defaultpass',
S3_BUCKET: `${projectName}-documents`,
S3_ENDPOINT: `http://${s3Host}:${s3PortStr}`,
S3_ENDPOINT: s3Host,
S3_USESSL: false
};
@@ -244,8 +244,7 @@ export class ServiceConfiguration {
// Always update S3_ENDPOINT based on current settings
const oldEndpoint = this.config.S3_ENDPOINT;
const protocol = this.config.S3_USESSL ? 'https' : 'http';
this.config.S3_ENDPOINT = `${protocol}://${this.config.S3_HOST}:${this.config.S3_PORT}`;
this.config.S3_ENDPOINT = this.config.S3_HOST;
if (oldEndpoint !== this.config.S3_ENDPOINT) {
fieldsAdded.push('S3_ENDPOINT');
updated = true;
@@ -301,6 +300,7 @@ export class ServiceConfiguration {
if (portMappings && portMappings['27017']) {
const dockerPort = portMappings['27017'];
if (this.config.MONGODB_PORT !== dockerPort) {
logger.log('note', `📍 Syncing MongoDB port from Docker: ${dockerPort}`);
this.config.MONGODB_PORT = dockerPort;
updated = true;
}
@@ -315,6 +315,7 @@ export class ServiceConfiguration {
if (portMappings['9000']) {
const dockerPort = portMappings['9000'];
if (this.config.S3_PORT !== dockerPort) {
logger.log('note', `📍 Syncing S3 API port from Docker: ${dockerPort}`);
this.config.S3_PORT = dockerPort;
updated = true;
}
@@ -322,6 +323,7 @@ export class ServiceConfiguration {
if (portMappings['9001']) {
const dockerPort = portMappings['9001'];
if (this.config.S3_CONSOLE_PORT !== dockerPort) {
logger.log('note', `📍 Syncing S3 Console port from Docker: ${dockerPort}`);
this.config.S3_CONSOLE_PORT = dockerPort;
updated = true;
}
@@ -332,10 +334,10 @@ export class ServiceConfiguration {
if (updated) {
// Update derived fields
this.config.MONGODB_URL = `mongodb://${this.config.MONGODB_USER}:${this.config.MONGODB_PASS}@${this.config.MONGODB_HOST}:${this.config.MONGODB_PORT}/${this.config.MONGODB_NAME}?authSource=admin`;
const protocol = this.config.S3_USESSL ? 'https' : 'http';
this.config.S3_ENDPOINT = `${protocol}://${this.config.S3_HOST}:${this.config.S3_PORT}`;
this.config.S3_ENDPOINT = this.config.S3_HOST;
await this.saveConfig();
logger.log('ok', '✅ Configuration synced with Docker containers');
}
}
@@ -389,8 +391,7 @@ export class ServiceConfiguration {
if (updated) {
// Update derived fields
this.config.MONGODB_URL = `mongodb://${this.config.MONGODB_USER}:${this.config.MONGODB_PASS}@${this.config.MONGODB_HOST}:${this.config.MONGODB_PORT}/${this.config.MONGODB_NAME}?authSource=admin`;
const protocol = this.config.S3_USESSL ? 'https' : 'http';
this.config.S3_ENDPOINT = `${protocol}://${this.config.S3_HOST}:${this.config.S3_PORT}`;
this.config.S3_ENDPOINT = this.config.S3_HOST;
await this.saveConfig();
}
@@ -419,8 +420,7 @@ export class ServiceConfiguration {
// Update derived fields
this.config.MONGODB_URL = `mongodb://${this.config.MONGODB_USER}:${this.config.MONGODB_PASS}@${this.config.MONGODB_HOST}:${this.config.MONGODB_PORT}/${this.config.MONGODB_NAME}?authSource=admin`;
const protocol = this.config.S3_USESSL ? 'https' : 'http';
this.config.S3_ENDPOINT = `${protocol}://${this.config.S3_HOST}:${this.config.S3_PORT}`;
this.config.S3_ENDPOINT = this.config.S3_HOST;
await this.saveConfig();