All Projects → soyaine → horcrux

soyaine / horcrux

Licence: MIT License
Generate you own online gallery easily. Photo is the horcrux of memory.

Programming Languages

CSS
56736 projects
python
139335 projects - #7 most used programming language
HTML
75241 projects
shell
77523 projects

Projects that are alternatives of or similar to horcrux

Affiliates Jekyll Theme
Affiliates - Jekyll Blogging Theme for Affiliate Marketers
Stars: ✭ 145 (+326.47%)
Mutual labels:  jekyll, jekyll-theme, jekyll-themes, jekyll-template
Will Jekyll Template
A simple Jekyll theme.
Stars: ✭ 360 (+958.82%)
Mutual labels:  jekyll, jekyll-theme, jekyll-themes, jekyll-template
Jekyll Text Theme
💎 🐳 A super customizable Jekyll theme for personal site, team site, blog, project, documentation, etc.
Stars: ✭ 2,150 (+6223.53%)
Mutual labels:  jekyll, jekyll-theme, jekyll-themes, jekyll-template
Mundana Theme Jekyll
Mundana is a free Jekyll theme, Medium styled.
Stars: ✭ 402 (+1082.35%)
Mutual labels:  jekyll, jekyll-theme, jekyll-themes, jekyll-template
Millennial
A minimalist Jekyll theme for running an online publication
Stars: ✭ 223 (+555.88%)
Mutual labels:  jekyll, jekyll-theme, jekyll-themes, jekyll-template
Jalpc
🍎Jalpc -- A flexible Jekyll theme, 3 steps to build your website.
Stars: ✭ 859 (+2426.47%)
Mutual labels:  jekyll, jekyll-theme, gh-pages, jekyll-themes
fuse-core
The 'Fuse Core' Jekyll theme.
Stars: ✭ 29 (-14.71%)
Mutual labels:  jekyll, jekyll-theme, jekyll-themes, jekyll-template
Long Haul
A minimal, type-focused Jekyll theme.
Stars: ✭ 524 (+1441.18%)
Mutual labels:  jekyll, jekyll-theme, jekyll-themes, jekyll-template
Moving
A clean and minimalist theme for Jekyll.
Stars: ✭ 701 (+1961.76%)
Mutual labels:  jekyll, jekyll-theme, jekyll-themes, jekyll-template
Mediumish Theme Jekyll
Jekyll Template - Mediumish
Stars: ✭ 786 (+2211.76%)
Mutual labels:  jekyll, jekyll-theme, jekyll-themes, jekyll-template
Autm Rb
Jekyll theme
Stars: ✭ 80 (+135.29%)
Mutual labels:  jekyll, jekyll-theme, jekyll-themes, jekyll-template
Urban Jekyll Template
☁️ Agency template for Jekyll
Stars: ✭ 160 (+370.59%)
Mutual labels:  jekyll, jekyll-theme, jekyll-template
Hitchens
An inarguably well-designed Jekyll theme.
Stars: ✭ 162 (+376.47%)
Mutual labels:  jekyll, jekyll-theme, jekyll-template
Resume
A minimalist resume template for Jekyll and Hexo
Stars: ✭ 174 (+411.76%)
Mutual labels:  jekyll, jekyll-theme, jekyll-themes
Wu Kan.github.io
✨ my homepage & template for jekyll-theme-WuK
Stars: ✭ 171 (+402.94%)
Mutual labels:  jekyll, jekyll-theme, jekyll-themes
Oscailte
Oscailte — A powerful light, clean, and responsive Jekyll theme.
Stars: ✭ 178 (+423.53%)
Mutual labels:  jekyll, jekyll-theme, jekyll-themes
Minima
Minima is a one-size-fits-all Jekyll theme for writers.
Stars: ✭ 2,452 (+7111.76%)
Mutual labels:  jekyll, jekyll-theme, jekyll-themes
No Style Please
A (nearly) no-CSS, fast, minimalist Jekyll theme.
Stars: ✭ 192 (+464.71%)
Mutual labels:  jekyll, jekyll-theme, jekyll-themes
Frisco Jekyll Template
📱 App marketing template for Jekyll
Stars: ✭ 135 (+297.06%)
Mutual labels:  jekyll, jekyll-theme, jekyll-template
Jekyll Theme Massively
Preview
Stars: ✭ 187 (+450%)
Mutual labels:  jekyll, jekyll-theme, jekyll-template

Horcrux

Generate your own online photograph gallery easily.

demo

Features

  • Simple but beautiful UI.
  • Auto-watermark your photos.
  • Auto-generate thumbnails for better load speed.
  • Sort photos by time, modify as you like, and keep it when you add new photos.
  • Keep the order when you put new photos in.
  • Support multi-level albums.
  • Based on Jekyll and GitHub Pages.

Demo

Here is a live demo: https://soyaine.github.io/horcrux/

Quick Start

Fork this repo, or clone to your local.

$ git clone [email protected]:soyaine/horcrux.git

Make sure you have installed Python3, check current python version.

$ python3 -V
  • If your command python rather than python3 point to Python3, please change the code in two command file, modify python3 -m venv venv to python -m venv venv.
    # setup.command / config.command
    python -m venv venv 
  • If version < 3 or error, install Python3, and then recheck.
    $ brew install python3
    $ python3 -V
    
  • If the check passes, next step.

Change the config in file _config.yml, especially the name, which will shown as the site header and the watermark text in your photos.

name: Horcrux
instagram: your_ins_account_id

Remove all resources under ./photos/, then create folder in it, the folder name will shown as headline of a group of photos. Copy some photos into it.

photos
├── 2019
│    ├── Duo
│    │   ├── 07.jpg
│    │   ├── 08.jpg
│    │   ├── 09.jpg
│    └── Hey
│        ├── 02.jpg
│        └── 1.jpg
└── Mey
    ├── 02.jpg
    └── 1.jpg

⚠️NOTE

Please always keep your own original photo files in other place, because the watermark will change the original one.

When you first try this, just put several photos in, to see wheather you like the watermark effect or not.

Double click the setup.command, the process is doing:

  • Generate thumbnails with the suffix of .min.jpg
  • Watermark original photos with name value set in _config.yml
  • Traverse all folders and files, generate a file _data/config.json

Run and greet your gallery in locally by Jekyll.

$ jekyll serve --watch

Git push to the remote branch gh-pages, then it will be online. 🎉

$ git add .
$ git commit -m "init gallery"
$ git push -u origin gh-pages

Make It Yours

If you have run successfully locally, here are more details you can reform it. The following is the default settings of Horcrux, almost all config are set in _config.yml:

Headline and Instagram Link

name: Horcrux # Headline of the page, watermark text

instagram: ins_id
  • The value of name is both the website headline and the watermark text.
  • There is a text link to your Instagram page at the bottom of the page, just set it blank if you don't want.

Albums and photos process

# How to process the photos and albums to config
process:
  keep_order: True
  nested_album:
    separator: ' · '
  album:
    sort_by_time: True # False: sort by filename
    order_by: create # other two value can be: access, modify
    reverse: True
  photo:
    sort_by_time: False
    order_by: modify
    reverse: True
    min_width: 600
    watermark:
      thumbnail: False
      original: True
      fontsize: 40
      fontfamily: Eczar-Medium.ttf
      rotate: 0

sort_by_time, order_by, reverse:

  • Sort the albums (folder under photos) by create time, from new to old.
  • Sort the photos by name.

keep_order:

  • When you change the order value in JSON under _data, and add new photos or new albums, then double click setup.command, a new config.json file will be generated, all old order set manually will be retained.
  • If you just modify order without new photo added, you can just double click config.command, which will read all JSON files (Horcrux.json and others under albums folder), and regenerate the config.json file.

separator:

  • If you created nested folders under the photos folder, Horcrux can handle it too.
  • The album which path in ./photos/2019/duo/, its displayed title in page will be: DUO · 2019, spliced by separator ·.

watermark:

  • Watermark the original photos.
  • The text of the watermark is the value of name.
  • The position is in the middle of the bottom of the photo.

Gallery Style

frame_padding: 10px # the white gap between photo and outer border

# Widescreen
column: 3 
column_gap: 30px
row_gap: 30px

# Smallscreen
small_screen:
  column: 2
  column_gap: 10px
  row_gap: 10px

column:

  • In wide screen, photos divided into 3 columns.
  • In small screen, photos divided into 2 columns.

frame_padding, column_gap, row_gap:

  • Each photo has a white square frame background. The white gap between photo and frame outer border is 10px.
  • In wide screen, the spacing between columns is 30px, the same for rows.
  • In small screen, the spacing between columns is 10px, the same for rows.

Color Palette

Most of the color palette is defined in ./sass/base.scss, you can change them to your color.

$background: #fafafa;
$surface: #fff;

$title: #5f5f5f;
$subtitle: #868686;
$text: #C8C8C8;
$link: #98A3AA;
  • $background: whole page's background color
  • $surface: the color of photo square frame

Acknowledgments

The idea of generating album JSON for using Jekyll and GitHub Pages is inspired by AndyZhang's gallery.

Special thanks to my friend Hugo , the photographs both in the mockup above and in the live demo were taken by him. In the beginning, I just wanted to write a tool for him to share photography. Later I found it can be open-sourced. So there is Horcrux, he named it.

Author

© Soyaine

Support

If you have any question about Horcrux, feel free to start an issue.

You can also reach out to me by email [email protected]

License

MIT

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].