feat(compose): expose "Compose Logs" command configuration in settings#346
Open
SamuelJoseph23 wants to merge 1 commit intomicrosoft:mainfrom
Open
feat(compose): expose "Compose Logs" command configuration in settings#346SamuelJoseph23 wants to merge 1 commit intomicrosoft:mainfrom
SamuelJoseph23 wants to merge 1 commit intomicrosoft:mainfrom
Conversation
Adds a new configuration setting `containers.commands.composeLogs` to allow customization of the command used for viewing Compose group logs. This enables users to pass additional flags like `--names` or adjust `--tail` via the "Compose Logs" command template, addressing limitations where Podman Compose logs lacked container names by default. - Added `containers.commands.composeLogs` to package.json - Implemented [selectComposeLogsCommand](cci:1://file:///c:/Users/samue/Documents/GitHub/vscode-containers/src/commands/selectCommandTemplate.ts:80:0-101:1) in command template selection - Updated [composeGroupLogs](cci:1://file:///c:/Users/samue/Documents/GitHub/vscode-containers/src/commands/containers/composeGroup.ts:15:0-24:1) to use the configurable template Closes microsoft#323
Author
|
@microsoft-github-policy-service agree |
Collaborator
|
Apologies for how long it's taken to get to reviewing this--I haven't forgotten though! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Expose "Compose Logs" command configuration
Description
This Pull Request exposes the "Compose Logs" command configuration to VS Code settings. This allows users to fully customize the command template used when viewing logs for a Compose group, bringing it to parity with the existing "Container Logs" configuration.
Motivation & Context
Previously, the extension used a hardcoded command for Compose logs (
logs --tail 1000 -f). This limited flexibility, particularly for Podman Compose users who often need to add the--namesflag to distinguish between different containers in the log stream.With this change, users can now define their own command templates via the
containers.commands.composeLogssetting, enabling them to customize flags (e.g., adding--namesor changing the--tailcount) to better suit their development workflow.How Has This Been Tested?
I have verified this change locally by:
containers.commands.composeLogssetting in VS Code to include the--namesflag.Related Issue
Closes #323