2 Commits

Author SHA1 Message Date
750ac4a47b 1.2.2
Some checks failed
Release / build-and-release (push) Failing after 4s
2025-10-24 08:21:13 +00:00
8119ff264c fix(logging): Refactor logging and plugin imports: remove push.rocks dependencies and provide a simple console-based logger with a compatibility shim 2025-10-24 08:21:13 +00:00
6 changed files with 38 additions and 35 deletions

View File

@@ -1,5 +1,13 @@
# Changelog # Changelog
## 2025-10-24 - 1.2.2 - fix(logging)
Refactor logging and plugin imports: remove push.rocks dependencies and provide a simple console-based logger with a compatibility shim
- Replaced smartlog-based logger with a simple console-based log utility in ts/logging.ts; added a small logger shim (logger.log) for compatibility.
- Removed push.rocks exports from ts/plugins.ts and consolidated external imports to std modules (@std/*); updated deno.json to remove push.rocks packages and keep @std/cli.
- Updated code to use the new console logger and simplified plugin surface; this reduces external dependencies and simplifies runtime footprint.
- Added .claude/settings.local.json (local settings file) — development/local config only, no runtime change.
## 2025-10-24 - 1.2.1 - fix(deno) ## 2025-10-24 - 1.2.1 - fix(deno)
Set Deno nodeModulesDir to 'auto' and add local .claude settings Set Deno nodeModulesDir to 'auto' and add local .claude settings

View File

@@ -1,6 +1,6 @@
{ {
"name": "@serve.zone/isocreator", "name": "@serve.zone/isocreator",
"version": "1.2.1", "version": "1.2.2",
"exports": "./mod.ts", "exports": "./mod.ts",
"tasks": { "tasks": {
"dev": "deno run --allow-all mod.ts", "dev": "deno run --allow-all mod.ts",
@@ -19,11 +19,7 @@
"@std/yaml": "jsr:@std/yaml@^1.0.0", "@std/yaml": "jsr:@std/yaml@^1.0.0",
"@std/assert": "jsr:@std/assert@^1.0.0", "@std/assert": "jsr:@std/assert@^1.0.0",
"@std/fmt": "jsr:@std/fmt@^1.0.0", "@std/fmt": "jsr:@std/fmt@^1.0.0",
"@push.rocks/smartcli": "npm:@push.rocks/smartcli@^5.0.0", "@std/cli": "jsr:@std/cli@^1.0.0"
"@push.rocks/smartlog": "npm:@push.rocks/smartlog@^3.0.0",
"@push.rocks/smartfile": "npm:@push.rocks/smartfile@^11.0.0",
"@push.rocks/smartpromise": "npm:@push.rocks/smartpromise@^4.0.0",
"@push.rocks/smartrequest": "npm:@push.rocks/smartrequest@^2.0.0"
}, },
"nodeModulesDir": "auto", "nodeModulesDir": "auto",
"compilerOptions": { "compilerOptions": {

View File

@@ -1,6 +1,6 @@
{ {
"name": "@serve.zone/isocreator", "name": "@serve.zone/isocreator",
"version": "1.2.1", "version": "1.2.2",
"description": "Ubuntu ISO customization tool for PC and Raspberry Pi with WiFi and cloud-init configuration", "description": "Ubuntu ISO customization tool for PC and Raspberry Pi with WiFi and cloud-init configuration",
"type": "module", "type": "module",
"bin": { "bin": {

View File

@@ -3,6 +3,6 @@
*/ */
export const commitinfo = { export const commitinfo = {
name: '@serve.zone/isocreator', name: '@serve.zone/isocreator',
version: '1.2.1', version: '1.2.2',
description: 'Ubuntu ISO customization tool for PC and Raspberry Pi with WiFi and cloud-init configuration' description: 'Ubuntu ISO customization tool for PC and Raspberry Pi with WiFi and cloud-init configuration'
} }

View File

@@ -1,29 +1,34 @@
/** /**
* Logging utilities for isocreator * Logging utilities for isocreator
* Simple console-based logging (following nupst pattern)
*/ */
import { smartlog } from './plugins.ts';
// Create logger instance
export const logger = new smartlog.Smartlog({
logContext: {
company: 'Lossless GmbH',
companyunit: 'serve.zone',
containerName: 'isocreator',
environment: 'cli',
runtime: 'deno',
zone: 'local',
},
minimumLogLevel: 'info',
});
/** /**
* Log levels for convenience * Log levels for convenience
*/ */
export const log = { export const log = {
info: (message: string) => logger.log('info', message), info: (message: string) => console.log(` ${message}`),
success: (message: string) => logger.log('info', `${message}`), success: (message: string) => console.log(`${message}`),
warn: (message: string) => logger.log('warn', `⚠️ ${message}`), warn: (message: string) => console.warn(`⚠️ ${message}`),
error: (message: string) => logger.log('error', `${message}`), error: (message: string) => console.error(`${message}`),
debug: (message: string) => logger.log('silly', message), debug: (message: string) => console.log(`🔍 ${message}`),
};
// Export a simple logger object for compatibility
export const logger = {
log: (level: string, message: string) => {
switch (level) {
case 'info':
log.info(message);
break;
case 'warn':
log.warn(message);
break;
case 'error':
log.error(message);
break;
default:
console.log(message);
}
},
}; };

View File

@@ -9,10 +9,4 @@ export * as fs from '@std/fs';
export * as yaml from '@std/yaml'; export * as yaml from '@std/yaml';
export * as assert from '@std/assert'; export * as assert from '@std/assert';
export * as fmt from '@std/fmt'; export * as fmt from '@std/fmt';
export * as cli from '@std/cli';
// Push.rocks ecosystem
export { smartcli } from '@push.rocks/smartcli';
export { smartlog } from '@push.rocks/smartlog';
export { smartfile } from '@push.rocks/smartfile';
export { Deferred } from '@push.rocks/smartpromise';
export { smartrequest } from '@push.rocks/smartrequest';