mirror of
https://github.com/danbee/danbarber.me.hugo.git
synced 2025-03-04 08:59:18 +00:00
Compare commits
No commits in common. "2b00bc0a011d6d53b3001e9bffb537932e9c68ac" and "67281a6be016bc22e47bf54fa6e582624a76e5d2" have entirely different histories.
2b00bc0a01
...
67281a6be0
@ -1,2 +1 @@
|
|||||||
hugo extended_0.120.4
|
hugo extended_0.120.4
|
||||||
ruby 3.2.2
|
|
||||||
|
|||||||
26
Gemfile.lock
26
Gemfile.lock
@ -1,26 +0,0 @@
|
|||||||
GEM
|
|
||||||
remote: https://rubygems.org/
|
|
||||||
specs:
|
|
||||||
cgi (0.4.1)
|
|
||||||
coderay (1.1.3)
|
|
||||||
erb (4.0.4)
|
|
||||||
cgi (>= 0.3.3)
|
|
||||||
exiftool (1.2.5)
|
|
||||||
json
|
|
||||||
json (2.7.2)
|
|
||||||
method_source (1.1.0)
|
|
||||||
pry (0.14.2)
|
|
||||||
coderay (~> 1.1)
|
|
||||||
method_source (~> 1.0)
|
|
||||||
|
|
||||||
PLATFORMS
|
|
||||||
arm64-darwin-23
|
|
||||||
ruby
|
|
||||||
|
|
||||||
DEPENDENCIES
|
|
||||||
erb
|
|
||||||
exiftool
|
|
||||||
pry
|
|
||||||
|
|
||||||
BUNDLED WITH
|
|
||||||
2.5.9
|
|
||||||
@ -1,20 +0,0 @@
|
|||||||
---
|
|
||||||
title: "<%= photo[:title] %>"
|
|
||||||
date: <%= date %>
|
|
||||||
categories:
|
|
||||||
tags:
|
|
||||||
layout: post
|
|
||||||
image: <%= photo[:file_name] %>
|
|
||||||
---
|
|
||||||
|
|
||||||
<figure class="photo photo--wide">
|
|
||||||
<img src="<%= photo[:file_name] %>" alt="<%= photo[:image_description] %>">
|
|
||||||
|
|
||||||
<figcaption>
|
|
||||||
<%= photo[:model] %>,
|
|
||||||
<%= (photo[:focal_length35efl] || photo[:focal_length]).gsub(" mm", "mm") %>,
|
|
||||||
ISO <%= photo[:iso] %>,
|
|
||||||
<%= photo[:shutter_speed] %>
|
|
||||||
at ƒ/<%= photo[:f_number] %>
|
|
||||||
</figcaption>
|
|
||||||
</figure>
|
|
||||||
@ -1,30 +0,0 @@
|
|||||||
#!/usr/bin/env ruby
|
|
||||||
require "erb"
|
|
||||||
require "exiftool"
|
|
||||||
require "i18n"
|
|
||||||
require "pry"
|
|
||||||
|
|
||||||
I18n.config.available_locales = :en
|
|
||||||
|
|
||||||
def parameterize(string)
|
|
||||||
I18n.transliterate(string)
|
|
||||||
.downcase
|
|
||||||
.gsub(/[^a-z]+/, "-")
|
|
||||||
end
|
|
||||||
|
|
||||||
photo_path = ARGV.first
|
|
||||||
|
|
||||||
photo = Exiftool.new(photo_path)
|
|
||||||
date = Date.today.iso8601
|
|
||||||
|
|
||||||
template = ERB.new(File.read("archetypes/photos/index.md.erb"))
|
|
||||||
|
|
||||||
post_dir = "content/photos/#{date}-#{parameterize(photo[:title])}"
|
|
||||||
|
|
||||||
if !Dir.exist?(post_dir)
|
|
||||||
Dir.mkdir(post_dir)
|
|
||||||
end
|
|
||||||
|
|
||||||
FileUtils.cp(photo_path, "#{post_dir}/#{photo[:file_name]}")
|
|
||||||
|
|
||||||
File.write("#{post_dir}/index.md", template.result)
|
|
||||||
Binary file not shown.
|
Before Width: | Height: | Size: 2.2 MiB |
@ -1,20 +0,0 @@
|
|||||||
---
|
|
||||||
title: "I Destroy Silence"
|
|
||||||
date: 2024-04-21
|
|
||||||
categories:
|
|
||||||
tags:
|
|
||||||
layout: post
|
|
||||||
image: IMG_6362.jpeg
|
|
||||||
---
|
|
||||||
|
|
||||||
<figure class="photo photo--wide">
|
|
||||||
<img src="IMG_6362.jpeg" alt="Sofía and I at my SMC gig on Saturday">
|
|
||||||
|
|
||||||
<figcaption>
|
|
||||||
iPhone 15 Pro Max,
|
|
||||||
6.8mm (35mm equivalent: 24.0mm),
|
|
||||||
ISO 3200,
|
|
||||||
1/15
|
|
||||||
at ƒ/1.8
|
|
||||||
</figcaption>
|
|
||||||
</figure>
|
|
||||||
Loading…
Reference in New Issue
Block a user