Add a2a-server package to gemini-cli (#6597)

This commit is contained in:
Adam Weidman
2025-08-26 20:49:25 +00:00
committed by GitHub
parent 08bdd08412
commit bfef867ba7
27 changed files with 6246 additions and 304 deletions

View File

@@ -0,0 +1,28 @@
/**
* @license
* Copyright 2025 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
import winston from 'winston';
const logger = winston.createLogger({
level: 'info',
format: winston.format.combine(
// First, add a timestamp to the log info object
winston.format.timestamp({
format: 'YYYY-MM-DD HH:mm:ss.SSS A', // Custom timestamp format
}),
// Here we define the custom output format
winston.format.printf((info) => {
const { level, timestamp, message, ...rest } = info;
return (
`[${level.toUpperCase()}] ${timestamp} -- ${message}` +
`${Object.keys(rest).length > 0 ? `\n${JSON.stringify(rest, null, 2)}` : ''}`
); // Only print ...rest if present
}),
),
transports: [new winston.transports.Console()],
});
export { logger };