Skip to content

Conversation

@GaneshPatil7517
Copy link

This PR adds a dedicated Camel icon for *.camel.yaml and *.camel.yml files in the VS Code file explorer, similar to docker-compose.yml behavior.

Changes Made

  • Added iconThemes contribution in package.json
  • Created icon theme definition (camel.json) with file associations
  • Added Camel-themed SVG icon (camel-yaml.svg)

Testing

  • Verified JSON syntax of configuration files
  • Icon paths tested and confirmed correct
  • Ready for VS Code Extension Development Host testing

Fixes

Fixes #719

Copilot AI review requested due to automatic review settings January 17, 2026 04:18
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR aims to add a custom file explorer icon for Camel YAML files (*.camel.yaml and *.camel.yml) in VS Code, similar to how docker-compose.yml files display custom icons.

Changes:

  • Added iconThemes contribution point in package.json
  • Created icon theme definition file (camel.json) with file extension mappings
  • Added SVG icon file (camel-yaml.svg) with Camel-themed design

Reviewed changes

Copilot reviewed 2 out of 3 changed files in this pull request and generated 2 comments.

File Description
karavan-vscode/package.json Adds iconThemes contribution point to register the Karavan icon theme
karavan-vscode/icons/camel.json Defines icon theme with file extension to icon mappings
karavan-vscode/icons/camel-yaml.svg Provides SVG icon design for Camel YAML files

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 7 to 9
"fileExtensions": {
"camel.yaml": "_camel-yaml",
"camel.yml": "_camel-yaml"
Copy link

Copilot AI Jan 17, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

According to VS Code's file icon theme specification, the fileExtensions object should map file extensions to icon IDs. However, for compound extensions like "file.camel.yaml", only the last extension part is used by VS Code (i.e., "yaml"). To match files with patterns like ".camel.yaml", you need to use the fileNames property instead, with patterns like ".camel.yaml" and "*.camel.yml". The current implementation will not correctly match these files.

Suggested change
"fileExtensions": {
"camel.yaml": "_camel-yaml",
"camel.yml": "_camel-yaml"
"fileNames": {
"*.camel.yaml": "_camel-yaml",
"*.camel.yml": "_camel-yaml"

Copilot uses AI. Check for mistakes.
Comment on lines +717 to +723
],
"iconThemes": [
{
"id": "karavan",
"label": "Karavan",
"path": "icons/camel.json"
}
Copy link

Copilot AI Jan 17, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The iconThemes contribution point is designed to replace the entire file icon theme in VS Code, not to augment the existing theme with specific file icons. When a user selects the "Karavan" icon theme, all file icons will be replaced with this theme's definitions, and only files matching ".camel.yaml" and ".camel.yml" will have icons - all other files will have no icons.

The correct approach for adding custom icons for specific file extensions is to use the contributes.icons contribution point combined with contributes.languages or file associations. Alternatively, consider using the approach of declaring file icon associations as part of the language definition if you have language support for these files.

Suggested change
],
"iconThemes": [
{
"id": "karavan",
"label": "Karavan",
"path": "icons/camel.json"
}

Copilot uses AI. Check for mistakes.
Adds VS Code file explorer icon mapping for Camel YAML files to improve visual clarity in the file explorer.
@GaneshPatil7517 GaneshPatil7517 force-pushed the feature/vscode-camel-yaml-icon branch from aa511a0 to c466a1a Compare January 17, 2026 04:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Camel icon in VSCode file explorer for xxx.camel.yaml files

1 participant