compose.yml , should have the same icon as docker-compose.yml and Dockerfile
Nikola-Milovic opened this issue · 9 comments
It seems that docker-compose.yaml
is now compose.yaml
as preferred by docker compose
, source, would be nice to have the blue whale icon instead of the cog that is currently there
You're right, thanks for reporting it.
You're right, thanks for reporting it.
What of compose-*.yml?
You're right, thanks for reporting it.
What of compose-*.yml?
It doesn't look like they are part of the spec: https://docs.docker.com/compose/compose-application-model/
What's your use case?
You're right, thanks for reporting it.
What of compose-*.yml?
It doesn't look like they are part of the spec: https://docs.docker.com/compose/compose-application-model/
What's your use case?
Different compose file for test, development and production. e.g. compose-dev.yaml
This is common practice but we can't anticipate and add all possible filenames and since we are not pattern match at all I am afraid it is down to users to set additional configuration.
This is common practice but we can't anticipate and add all possible filenames and since we are not pattern match at all I am afraid it is down to users to set additional configuration.
How do i set it?
You could:
- add a filetype mapping for
dockerfile
e.g.require("nvim-web-devicons").set_icon_by_filetype { dockerfile = "Dockerfile", }
- add individual mappings like
compose-dev.yaml
in your setup
1 will not work for plugins that don't see filetype like nvim-tree but should work for dynamic plugins like lualine.
You could:
1. add a [filetype mapping](https://github.com/nvim-tree/nvim-web-devicons?tab=readme-ov-file#getting-and-setting-icons-by-filetype) for `dockerfile` e.g. `require("nvim-web-devicons").set_icon_by_filetype { dockerfile = "Dockerfile", }` 2. add individual mappings like `compose-dev.yaml` in your [setup](https://github.com/nvim-tree/nvim-web-devicons?tab=readme-ov-file#setup)
1 will not work for plugins that don't see filetype like nvim-tree but should work for dynamic plugins like lualine.
i did this and it worked
require("nvim-web-devicons").set_icon {
["compose-prod.yaml"] = {
icon = "",
color = "#458ee6",
cterm_color = "68",
name = "Dockerfile"
},
}