5 ms·
Show HN: Bash Script to generate static responsive image web galleries
- Cyclenerd 10y agoI have built a small Bash Script to generate static web galleries. Feedback and pull request welcome.
- eveningcoffee 10y agoYou can improve it by separating design into separate files (say header, footer, etc). Doing things from shell is not very much different from doing things from browser. You can use very simple template language with sed or awk (just replace keywords with actual values for example). Alternative: just rewrite it to command some template engine (no, I do not have any recommendations). Edit: Positive side is that it is a single file, so I can see your point. But as the projects as multiple files anyway, it is perhaps still worth a consideration.
- Cyclenerd 10y agoAt first we had similar thoughts. But I really wanted to try it with one file. If the script becomes bigger and more complex, I think again.
- strebler 10y agoI love this, I have been (passively) wanting to find something like this for ages (i.e. bash script, with minimal deps, to generate a nice gallery in HTML). Thank you! One idea / suggestion I have would be to use Isotope for layout: http://isotope.metafizzy.co/ http://isotope.metafizzy.co/ Then you'd basically be able to generate a mini Pinterest...
- rsync 10y agoI think you've had this for ~20 years ... it was (is) called "gallery" and it was a perl/cgi script that basically everyone on the web used until ~2000 ...
- detaro 10y agoWith projects like this, I'd love to see a demo site instead of just a screenshot. Since it's static you could just throw it up on GitHub Pages.
- Cyclenerd 10y agogood idea: https://cyclenerd.github.io/gallery_shell_demo/ https://cyclenerd.github.io/gallery_shell_demo/