Or will be better to parse an env variable, for example, LS_ICONS in the following format:
LS_ICONS="*.rb=e21e:*.vim=e62b:*.sh=f292:"
similar to LS_COLORS.
@ogham What about this?
Or will be better to parse an env variable, for example,
LS_ICONSin the following format:LS_ICONS="*.rb=e21e:*.vim=e62b:*.sh=f292:"similar to
LS_COLORS.
This idea is pretty good, I'd recommend adding the following concepts:
Example:
LS_MIMETYPES="application/octet-stream=\Uf471;application/gzip=\U15FDC:application/*=📦:image/png=\U1F3A8\e01;35m:image/*=\e38;5;97m🖼️"
LS_EXT2MIME="png,jpg,gif=image/*;tar.gz=application/*"
This allows exa to be extended using mime type file categorization or by file extension. The LS_MIMETYPES is a list of mimetype keys that support wildcards e.g. image/, audio/, video/*. It can act as an override of LS_COLORS in that it allows a user to define unicode escapes \UXXXX, directly paste unicode characters, and specify SGR escapes.
By using file magic mime type analysis, users would not be required to maintain a LS_EXT2MIME variable or set LS_COLORS. To avoid the performance hit, users could define LS_EXT2MIME for forced mapping of file extensions to mimetypes.
@pagerc I think this is very complicated. In any case, this project is developing very slowly.
Most helpful comment
Or will be better to parse an env variable, for example,
LS_ICONSin the following format:similar to
LS_COLORS.