nordtheme / dircolors

An arctic, north-bluish clean and elegant dircolors theme.
https://www.nordtheme.com/ports/dircolors
MIT License
523 stars 104 forks source link

Add basic programmer's colors #23

Open defr0std opened 3 years ago

defr0std commented 3 years ago

Coloring the files which programmers are often dealing with:

The list is not exhaustive, we can add more popular types of files later if needed.

Fixes #22.

defr0std commented 3 years ago

@arcticicestudio, could you please have a look?

ghost commented 3 years ago

Is it possible to create another file for this (ex: src/dir_colors_programming) ? I'm a programmer and I don't like when my 'ls' looks like a christmas tree (personal taste). Can we just keep the "main" src/dir_colors clean and simple please?

defr0std commented 3 years ago

Yeah, I tried to separate this into multiple files, but then the installation process becomes cumbersome. Currently, there is one file that you could symlink and then run dircolors on it, which is very convenient.

With multiple files, we'd need first to merge the files into one. We can add a shell script for it (e.g. install.sh), which would by default merge the files and place the result into ~/.dir_colors. There would be no auto-update on git pull then, but I guess you could always re-run install.sh when needed. After all, this repository does not seem to be updated often.

Invoking dircolors utility twice doesn't work either because it outputs the code "LS_COLORS=xxx", so the second invocation would overwrite the first one, unless we start messing with its output.

P.S. Regarding the christmas tree, I don't like it either and I tried to avoid it as much as possible. For example, most of the source code file combinations are green (like .cc and .h for c++, .ts and .html for frontend, etc), so typically your project would have a single dominant color. The exceptions would be when you have a large mix of source/configuration files (e.g. c++ and text files) in the same folder, but I think this is less common. Directories with images/fonts/stylesheets would also look quite colorful, but that could be ok because you typically need to find something to edit.