alexander-bauer/distru

CSS and related files make Distru non-relocatable

alexander-bauer opened this issue · 4 comments

Distru tries to load ui/search.css, and some other files in ui/ when serving the web interface. I'm not quite sure how this should be fixed; they could be kept in a resources directory, such as /etc/distru/, but that's slightly inelegant, as is the alternative of incorporating them in the source.

Thinking about it another way, this also does allow people to style Distru however they want.

Yeah, but the install process for anyone not intimately familiar with it is sort of a bitch.

We probably should keep them separate, but not like they are now. They should probably be moved to something like /etc/distru/ in an install script.

Yeah, I know. Is there a way to include it in a binary?

I don't know of an elegant way to do it, really. The easiest is probably to include an install script in the repository which moves (or symlinks) the style and html files to a data repository, along with compiling Distru, ensuring that the configuration file is writable, and starting Distru as a daemon.