Making instagram at home
Monday 18 December 2023

youtube_video

Problem

  • Social media profiles are not owned spaces
  • Instagram doesn’t show EXIF data
  • Unsplash is similar to social media. ownership is down the toilet

Solutions

  • Use existing program that generate gallery
  • Write my own solution

Solution

  • Write my own
    • To learn how to know more about EXIF
    • Improve my own website
    • Improve Xlog for other people to use
  • Write Xlog shotcode to read a directory and build timeline out of it
  • Every photo has a page with original size and some Exif data. not all

Challenges

  • Github hosted pages limit is 1GB, and 100GB/month
    • I had to resize the images and compress them while keeping EXIF data
    • Find all files over 1MB where it’s jpg or png
    • pass them all to mogrify and limit width and height to 1000 max
    • reduce quality to 80%
    • and rotate them according to the exif data rotation
1find photos \
2-type f \
3-size +1M \( -iname *.jpg -o -iname *.png \) \
4-exec mogrify \
5-resize "1000x1000>" \
6-quality 80 \
7-auto-orient {} \;

Implementation

Caveats

  • All images are in one page, resized and lazy loaded

Social media

See Also