master
Denis Knauf 2022-07-13 18:55:59 +02:00
commit f3629f9796
34 changed files with 2383 additions and 0 deletions

71
.gitignore vendored Normal file
View File

@ -0,0 +1,71 @@
# No files with whitespaces
*\ *
# ---> Ruby
/.rake_tasks
*.gem
*.rbc
/.config
/coverage/
/InstalledFiles
/pkg/
/spec/reports/
/spec/examples.txt
/test/tmp/
/test/version_tmp/
/tmp/
/.cache/
!/.cache/.keep
# Ignore the build directory
/build
# Ignore cache
.*.swp
.*.kate-swp
.*.swo
*~
# Logs
/log
## Specific to RubyMotion:
.dat*
.repl_history
build/
/assets/build
## Documentation cache and generated files:
/.yardoc/
/_yardoc/
/doc/
/rdoc/
## Environment normalisation:
/.bundle/
/vendor/bundle
/lib/bundler/man/
# for a library or gem, you might want to ignore these files since the code is
# intended to run in multiple environments; otherwise, check them in:
# Gemfile.lock
# .ruby-version
# .ruby-gemset
# unless supporting rvm < 1.11.0 or doing something fancy, ignore this:
.rvmrc
# ---> Vim
[._]*.s[a-w][a-z]
[._]s[a-w][a-z]
*.un~
Session.vim
.netrwhist
*~
*.css.map
/.sass-cache/
/.cache
/.fonts_cache

41
Gemfile Normal file
View File

@ -0,0 +1,41 @@
# If you do not have OpenSSL installed, change
# the following line to use 'http://'
source 'https://rubygems.org'
gem 'rake'
gem 'puma'
gem 'awesome_print'
gem 'execjs'
#gem 'mini_racer'
#gem 'duktape'
gem 'ffi', '~> 1.13', '!= 1.14.2'
# For faster file watcher updates on Windows:
#gem 'wdm', '~> 0.1.0', platforms: [:mswin, :mingw]
# Windows does not come with time zone data
#gem 'tzinfo-data', platforms: [:mswin, :mingw, :jruby]
# Middleman Gems
gem 'middleman', '>= 4.0.0'
gem 'middleman-livereload'
gem 'middleman-deploy', git: 'https://github.com/middleman-contrib/middleman-deploy.git'
gem 'middleman-minify-html'
gem 'middleman-blog'
gem 'middleman-asciidoc'
gem 'middleman-fonts', git: 'https://git.denkn.at/deac/middleman-fonts.git'
gem 'haml'
gem 'coffee-script'
gem 'font-awesome-sass', '~> 6.0' # '~> 5.15'
gem 'builder'
gem 'activesupport', require: 'active_support/all'
gem 'mini_magick'
gem 'oga'
gem 'nokogiri'
gem 'r18n-desktop'
gem 'pry'

201
Gemfile.lock Normal file
View File

@ -0,0 +1,201 @@
GIT
remote: https://git.denkn.at/deac/middleman-fonts.git
revision: 4664814b80cf2d13bb64255be2e9e4c133961a38
specs:
middleman-fonts (0.0.1)
GIT
remote: https://github.com/middleman-contrib/middleman-deploy.git
revision: 4d04b550b4c6888265d83ee9689f41e29dbae535
specs:
middleman-deploy (2.0.0.pre.alpha)
middleman-core (>= 3.2)
net-sftp
ptools
GEM
remote: https://rubygems.org/
specs:
activesupport (6.1.5)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 1.6, < 2)
minitest (>= 5.1)
tzinfo (~> 2.0)
zeitwerk (~> 2.3)
addressable (2.8.0)
public_suffix (>= 2.0.2, < 5.0)
ansi (1.5.0)
asciidoctor (2.0.17)
ast (2.4.2)
awesome_print (1.9.2)
backports (3.23.0)
builder (3.2.4)
coderay (1.1.3)
coffee-script (2.4.1)
coffee-script-source
execjs
coffee-script-source (1.12.2)
concurrent-ruby (1.1.10)
contracts (0.13.0)
dotenv (2.7.6)
em-websocket (0.5.3)
eventmachine (>= 0.12.9)
http_parser.rb (~> 0)
erubis (2.7.0)
eventmachine (1.2.7)
execjs (2.8.1)
fast_blank (1.0.1)
fastimage (2.2.6)
ffi (1.15.5)
font-awesome-sass (6.1.1)
sassc (~> 2.0)
haml (5.2.2)
temple (>= 0.8.0)
tilt
hamster (3.0.0)
concurrent-ruby (~> 1.0)
hashie (3.6.0)
htmlcompressor (0.2.0)
http_parser.rb (0.8.0)
i18n (1.6.0)
concurrent-ruby (~> 1.0)
kramdown (2.3.2)
rexml
listen (3.0.8)
rb-fsevent (~> 0.9, >= 0.9.4)
rb-inotify (~> 0.9, >= 0.9.7)
memoist (0.16.2)
method_source (1.0.0)
middleman (4.4.2)
coffee-script (~> 2.2)
haml (>= 4.0.5)
kramdown (>= 2.3.0)
middleman-cli (= 4.4.2)
middleman-core (= 4.4.2)
middleman-asciidoc (1.0.0)
asciidoctor (>= 1.5.0)
middleman-core (~> 4.0)
middleman-blog (4.0.3)
addressable (~> 2.3)
middleman-core (>= 4.0.0)
tzinfo (>= 0.3.0)
middleman-cli (4.4.2)
thor (>= 0.17.0, < 2.0)
middleman-core (4.4.2)
activesupport (>= 6.1, < 7.0)
addressable (~> 2.4)
backports (~> 3.6)
bundler (~> 2.0)
contracts (~> 0.13.0)
dotenv
erubis
execjs (~> 2.0)
fast_blank
fastimage (~> 2.0)
hamster (~> 3.0)
hashie (~> 3.4)
i18n (~> 1.6.0)
listen (~> 3.0.0)
memoist (~> 0.14)
padrino-helpers (~> 0.15.0)
parallel
rack (>= 1.4.5, < 3)
sassc (~> 2.0)
servolux
tilt (~> 2.0.9)
toml
uglifier (~> 3.0)
webrick
middleman-livereload (3.4.7)
em-websocket (~> 0.5.1)
middleman-core (>= 3.3)
rack-livereload (~> 0.3.15)
middleman-minify-html (3.4.1)
htmlcompressor (~> 0.2.0)
middleman-core (>= 3.2)
mini_magick (4.11.0)
mini_portile2 (2.8.0)
minitest (5.15.0)
net-sftp (3.0.0)
net-ssh (>= 5.0.0, < 7.0.0)
net-ssh (6.1.0)
nio4r (2.5.8)
nokogiri (1.13.4)
mini_portile2 (~> 2.8.0)
racc (~> 1.4)
oga (3.3)
ast
ruby-ll (~> 2.1)
padrino-helpers (0.15.1)
i18n (>= 0.6.7, < 2)
padrino-support (= 0.15.1)
tilt (>= 1.4.1, < 3)
padrino-support (0.15.1)
parallel (1.22.1)
parslet (2.0.0)
pry (0.14.1)
coderay (~> 1.1)
method_source (~> 1.0)
ptools (1.4.2)
public_suffix (4.0.7)
puma (5.6.4)
nio4r (~> 2.0)
r18n-core (5.0.1)
r18n-desktop (5.0.1)
r18n-core (~> 5.0)
racc (1.6.0)
rack (2.2.3)
rack-livereload (0.3.17)
rack
rake (13.0.6)
rb-fsevent (0.11.1)
rb-inotify (0.10.1)
ffi (~> 1.0)
rexml (3.2.5)
ruby-ll (2.1.2)
ansi
ast
sassc (2.4.0)
ffi (~> 1.9)
servolux (0.13.0)
temple (0.8.2)
thor (1.2.1)
tilt (2.0.10)
toml (0.3.0)
parslet (>= 1.8.0, < 3.0.0)
tzinfo (2.0.4)
concurrent-ruby (~> 1.0)
uglifier (3.2.0)
execjs (>= 0.3.0, < 3)
webrick (1.7.0)
zeitwerk (2.5.4)
PLATFORMS
ruby
DEPENDENCIES
activesupport
awesome_print
builder
coffee-script
execjs
ffi (~> 1.13, != 1.14.2)
font-awesome-sass (~> 6.0)
haml
middleman (>= 4.0.0)
middleman-asciidoc
middleman-blog
middleman-deploy!
middleman-fonts!
middleman-livereload
middleman-minify-html
mini_magick
nokogiri
oga
pry
puma
r18n-desktop
rake
BUNDLED WITH
2.2.33

23
README.adoc Normal file
View File

@ -0,0 +1,23 @@
= homepage
== init
bundle update
== compile
rake
== deploy
rake deploy:test
or
rake deploy:production
== run server (local)
rake run
Will listen on port `:9290`

274
Rakefile Normal file
View File

@ -0,0 +1,274 @@
# encoding: UTF-8
# vim: set noet sw=2 ts=2 sts=2:
require 'pathname'
require 'font-awesome-sass'
require 'set'
require "mini_magick"
MiniMagick.configure do |config|
config.cli = :graphicsmagick
config.timeout = 5
end
class Pathname
def each_parent top_dir = nil, &exe
top_dir =
case top_dir
when nil then Pahname.new '/'
when Pathname then top_dir.expand_path
else Pathname.new( top_dir.to_s).expand_path
end
each_parent_till_dir top_dir, &exe
end
def each_parent_till_dir top_dir, &exe
return to_enum( self, __method__) unless block_given?
d = self
until top_dir == d
yield d
d = d.dirname
end
end
def parents top_dir = nil
each_parent( top_dir).to_a
end
def parents_till_dir top_dir, &exe
each_parent_till_dir( top_dir).to_a
end
end
def bexec *a
sh *%w[bundle exec], *a.map(&:to_s)
end
def middleman *a
bexec :middleman, *a
end
def opal_c *a
bexec %w[opal -c], *a
end
def coffee_c *a
sh *%w[coffee -mc], *a.map(&:to_s)
end
def deploy env
ENV['TARGET'] = env.to_s
middleman :deploy
end
def flatten_args_ *as, &e
as.each do |a|
case a
when Array then flatten_args_ *a, &e
else yield a.to_s
end
end
end
def flatten_args *as, &e
if block_given?
flatten_args_ *as, &e
else
r = []
flatten_args_ *as, &r.method( :push)
r
end
end
def font_sfnt2woff t, cache_dir
STDERR.puts "Build font > #{t.name} < #{t.source}"
f = Pathname.new( t.source).basename
symdest = Pathname.new( t.source).relative_path_from cache_dir
symlink = cache_dir + f
cacdest = cache_dir.join( Pathname.new( t.name).basename)
symlink.unlink if begin symlink.lstat; rescue Errno::ENOENT; false; end
symlink.make_symlink symdest
pid = Process.spawn 'sfnt2woff-zopfli', f.to_s, chdir: cache_dir.to_s
_, status = Process.wait2 pid
# sfnt2woff-zopfli will not return anything else than exit-status 0
raise "sfnt2woff-zopfli failed!" unless 0 == status.exitstatus
raise "sfnt2woff-zopfli failed!" unless cacdest.exist?
cacdest.rename t.name
end
def font_webify t, cache_dir
STDERR.puts "Build font: #{t.name}"
f = Pathname.new( t.source).basename
symdest = Pathname.new( t.source).relative_path_from cache_dir
symlink = cache_dir + f
cacdest = cache_dir.join( Pathname.new( t.name).basename)
symlink.unlink if begin symlink.lstat; rescue Errno::ENOENT; false; end
symlink.make_symlink symdest
pid = Process.spawn 'webify', f.to_s, chdir: cache_dir.to_s
_, status = Process.wait2 pid
# webify will not return anything else than exit-status 0
raise "Webify failed!" unless 0 == status.exitstatus
raise "Webify failed!" unless cacdest.exist?
cacdest.rename t.name
end
def tmp_fork dest, *exec_args, &e
unless exec_args.empty?
args = flatten_args exec_args
return tmp_fork( dest) { Kernel.exec *args }
end
tmp = Pathname.new "#{dest}.tmp"
child = fork do
STDOUT.reopen tmp.open( 'w')
yield
end
Process.waitpid child
if 0 == $?.exitstatus
tmp.rename dest
true
else
false
end
end
asset_source_dir = Pathname.new( 'assets') + 'src'
asset_build_dir = Pathname.new( 'assets') + 'build' + 'assets'
cache_dir = Pathname.new '.cache'
font_build_dir = asset_build_dir + 'fonts'
fa_fonts_dir = Pathname.new FontAwesome::Sass::fonts_path
fa_fonts =
fa_fonts_dir.find.select( &:file?).map do |f|
font_build_dir + f.relative_path_from( fa_fonts_dir)
end
all_js = [] # asset_build_dir.join 'scripts', 'all.js'
#all_css = asset_build_dir.join 'styles', 'baroque.css'
directory asset_build_dir
#directory all_js.dirname
script_srcs = []
font_metadata_srcs = []
asset_source_dir.find do |f|
case f.basename.to_s
when /^\./ then Find.prune
when /\.opal$/ then script_srcs.push f
when /\.coffee$/ then script_srcs.push f
when /\.js$/ then script_srcs.push f
when 'METADATA.json' then font_metadata_srcs.push f
end
end
#file all_js => [asset_source_dir.join( 'all.coffee'),
# all_js.dirname, *script_srcs] do |t|
# STDERR.puts "COFFEE >#{t.name} <#{t.source}"
# coffee_c '-o', asset_build_dir+'scripts', t.source
#end
fa_fonts.each do |font|
directory *fa_fonts.map {|f| f.dirname }.uniq
file font => [fa_fonts_dir + font.relative_path_from( font_build_dir), font.dirname] do |t|
cp t.source, t.name
end
end
#directory all_css.dirname => asset_build_dir
#file all_css => [asset_source_dir + 'styles' + 'baroque.css', asset_source_dir+'styles'] do
# STDERR.puts "SCSS >#{t.name} <#{t.source}"
# tmp_fork t.name, %w[bundle exec scss], all_css.dirname, t.source
#end
fonts_source_dir = asset_source_dir + 'fonts'
fonts_build_dir = asset_build_dir + 'fonts'
fonts_cache_dir = cache_dir + 'fonts'
all_fonts = []
fonts_source_dir.find do |f|
case f.basename.to_s
when /^\./ then Find.prune
when /^(.*)\.(ttf|otf)$/ then
#file fonts_build_dir + f.basename => [f, fonts_build_dir] do |t|
# cp t.source, t.name
#end
#%w[svg woff eot].each do |ext|
%w[woff].each do |ext|
d = fonts_build_dir + "#$1.#{ext}"
all_fonts.push d
file d => [f, fonts_cache_dir, fonts_build_dir] do |t|
font_sfnt2woff t, fonts_cache_dir
end
end
d = fonts_build_dir + f.basename
all_fonts.push d
file d => f do |t|
cp t.source, t.name
end
#when /^(.*)\.otf$/ then from_otf += %w[svg woff eot].map {|ext| fonts_build_dir + "#$1.#{ext}" }
end
end
directory fonts_cache_dir => cache_dir
directory fonts_build_dir => asset_build_dir
directory asset_build_dir+'styles' => asset_build_dir
fonts_css = asset_build_dir+'styles'+'fonts.css'
task fonts_css => font_metadata_srcs+[fonts_css.dirname, cache_dir] do |t|
STDERR.puts "Generate #{t.name}"
require 'json'
require 'active_support/all'
cache_file = cache_dir+File.basename( t.name)
File.open cache_file, 'w' do |d|
font_metadata_srcs.each do |f|
STDERR.puts " <= #{f}"
JSON.parse( File.read( f))['fonts'].each do |font|
font = font.symbolize_keys
font[:ttf] = "/assets/fonts/#{font[:filename]}"
font[:woff] = "/assets/fonts/#{font[:filename].gsub /\.[ot]tf\Z/, '.woff'}"
d.puts sprintf( <<EOF, font).gsub(/^\s*(.*?)\s*$/, '\1').gsub(/\n/m,'')
@font-face {
font-family: "%<name>s";
font-weight: %<weight>i;
font-style: %<style>s;
src:
local("%<fullName>s"),
local("%<postScriptName>s"),
url("%<woff>s") format("woff"),
url("%<ttf>s") format("truetype");
}
EOF
end
end
end
cp cache_file.to_s, t.name.to_s
end
task all_fonts: all_fonts
task fontawesome: fa_fonts
task :all_js #: all_js
task fonts_css: fonts_css
task assets: [:all_js, :fontawesome, :all_fonts, :fonts_css]
task :build do
middleman :build, '--environment', 'production'
end
task default: :build
task :run do
middleman :server, '--port', 9296, '--environment', 'development'
#middleman :server, '--bind-address', '127.0.0.1', '--port', 9290, '--environment', 'development'
#bexec :puma, '--bind', 'tcp://127.0.0.1:9290', '--tag', :denkn
#bexec :rackup, '--port', 9290
end
task :clean do
rm_r 'assets/build' rescue Errno::ENOENT
rm_r 'build' rescue Errno::ENOENT
rm_r '.cache' rescue Errno::ENOENT
rm_r '.sass-cache' rescue Errno::ENOENT
end
namespace :deploy do
task :production do
deploy :production
end
task :test do
deploy :test
end
end

0
assets/src/fonts/.keep Normal file
View File

236
config.rb Normal file
View File

@ -0,0 +1,236 @@
# encoding: UTF-8
# vim: set noet sw=2 ts=2:
###
# Page options, layouts, aliases and proxies
###
require 'asciidoctor'
require 'middleman-asciidoc'
require 'active_support/all'
require 'awesome_print'
require 'font-awesome-sass'
require_relative 'lib/adoc'
require_relative 'lib/gallery'
Haml::TempleEngine.disable_option_validator!
#env = ENV['TARGET'].to_s.downcase
config[:css_dir] = '/assets/styles'
config[:js_dir] = '/assets/scripts'
config[:images_dir] = 'assets/images'
config[:sass_assets_paths] += Array.wrap(FontAwesome::Sass.stylesheets_path)
require 'yaml'
require_relative 'lib/repertoire.rb'
$repertoire = Repertoire.build YAML.load( File.read( 'db/repertoire.yml'), 'db/repertoire.yml', symbolize_names: true)
# Per-page layout changes:
#
# With no layout
page '*.xml', layout: false
page '*.json', layout: false
page '*.txt', layout: false
page 'events/*', layout: :events, data: {type: :events, blog: :events}
page 'gallery/*/*/*/*/*/index.html', layout: :album_image, data: {type: :album_image, blog: :gallery}
page 'gallery/*', layout: :gallery, data: {type: :gallery, blog: :gallery}
page '*.html', layout: :page
#page 'gallery/**/*.webp', layout: false, data: {type: :image}
#page 'gallery/**/*.jpeg', layout: false, data: {type: :image}
ignore '**/.*.sw?'
ignore '.*.sw?'
# With alternative layout
# page "/path/to/file.html", layout: :otherlayout
# Proxy pages (http://middlemanapp.com/basics/dynamic-pages/)
# proxy "/this-page-has-no-template.html", "/template-file.html", locals: {
# which_fake_page: "Rendering a fake page with a local variable" }
# General configuration
activate :i18n, mount_at_root: :de
# Reload the browser automatically whenever files change
configure :development do
activate :livereload
end
configure :production do
activate :deploy,
deploy_method: :rsync,
host: '....',
path: '....',
build_before: true
end
configure :development do
activate :deploy,
deploy_method: :rsync,
host: '....',
path: '....',
build_before: false
end
activate :external_pipeline,
name: :assets,
command: 'rake assets',
source: "assets/build"
#activate :external_pipeline,
# name: :gallery_images,
# command: 'rake gallery:all',
# source: '.cache/gallery'
activate :blog do |events|
# This will add a prefix to all links, template references and source paths
events.name = :events
events.prefix = '/events'
events.permalink = "{year}/{month}/{day}/{title}"
#Matcher for blog source files
#events.sources = "{year}-{month}-{day}-{title}.html"
#events.taglink = "tags/{tag}.html"
events.layout = :events
events.summary_separator = /(READMORE)/
events.summary_length = 256
events.year_link = "{year}.html"
events.month_link = "{year}/{month}.html"
events.day_link = "{year}/{month}/{day}.html"
events.default_extension = ".adoc"
events.tag_template = "tag.html"
events.calendar_template = "calendar.html"
events.publish_future_dated = true
# Enable pagination
events.paginate = true
events.per_page = 20
events.page_link = "page/{num}"
end
activate :blog do |gal|
gal.name = :gallery
gal.prefix = '/gallery'
gal.permalink = "{year}/{month}/{day}/{title}"
gal.sources = "{year}-{month}-{day}-{title}/index.html"
gal.layout = :gallery
gal.default_extension = ".adoc"
gal.paginate = true
gal.per_page = 20
gal.page_link = "page/{num}"
end
activate :asciidoc do |adoc|
adoc.template_dirs = ['asciidoctor-backends/haml/html5']
adoc.template_engine = 'haml'
adoc.template_cache = false
adoc.attributes = {
'source-highlighter' => 'coderay',
'fa-music' => 'pass:[<i class="fas fa-music"></i>]',
'fa-paint-brush' => 'pass:[<i class="fas fa-paint-brush"></i>]',
'ldquo' => "",
'rdquo' => "",
#'template_dirs': ['asciidoctor-backends/haml/html5'],
#'template_engine': 'haml',
#'template_cache': false
}
end
activate :directory_indexes
activate :fonts4web
activate :fonts_css
###
# Helpers
###
helpers do
Months = %w[Jänner Februar März April Mai Juni Juli August September Oktober November Dezember]
def longdate_at time_or_date
d = time_or_date
h = {day: d.day, month: Months[d.month-1], year: d.year}
s =
if Time === d and [d.hour, d.min].any? {|i| 0!=i}
h = h.update hour: d.hour, min: d.min, sec: d.sec
"%<day>d. %<month>s %<year>d %<hour>02d:%<min>02d"
else
"%<day>d. %<month>s %<year>d"
end
s % h
end
def post_times times, alt_time = nil
times =
Array.wrap(times).map do |time|
case time
when Time, Date
{time: time}
when String
{time: Time.parse( time)}
when Hash, Middleman::Util::EnhancedHash
case time[:time]
when Time, Date
time
when String
time.merge time: Time.parse( time[:time])
else
raise "A Time/Date or String-representation as `when.time`-entry expected. Given: #{time[:time].inspect}"
end
else
raise "A Time/Date/String-representation or Hash with time-entry for that as `when`-entry expected. Given: #{time.inspect}"
end
end.map do |t|
if t[:time].beginning_of_day == t
t.merge time: t[:time].to_date
else
t
end
end
times = [{time: alt_time}] if times.empty?
times
end
def active_page? uri
x = [uri.to_s, current_page.url].map {|u| Pathname.new URI.parse(u).path.sub( %r!(.+?)/.*\z!, "\\1") }
x.first == x.last
end
end
# Build-specific configuration
configure :production do
# Minify CSS on build
activate :minify_css
# Minify Javascript on build
activate :minify_javascript
activate :minify_html, preserve_line_breaks: true
end
activate :asset_hash, exts: %w(.css .js)
MiniMagick.configure do |config|
config.cli = :graphicsmagick
config.timeout = 5
end
activate :gallery do |g|
g.basepath = 'source/gallery'
g.thumbnail_size = '256x256'
end
# Historisch waren die Veranstaltungen unter /blog zu finden, statt unter /events:
([''] + %w[2019/02/28/lovefails/ 2019/02/28/ 2019/02/
2019/03/23/klavierkonzert/ 2019/03/23/ 2019/03/
2019/11/16/klaviermatinee-mit-russischer-musik/ 2019/11/16/ 2019/11/
2019/05/17/klavierfestival-wotrubakirche/ 2019/05/17/ 2019/05/
2019/04/29/an-american-in-vienna/ 2019/04/29/ 2019/04/
2019/
2020/02/09/klavierabend-mit-russischer-musik/ 2020/02/09/ 2020/02/
2020/03/15/duo-hudler-grube/ 2020/03/15/
2020/03/19/heimathaus-brunn/ 2020/03/19/ 2020/03/
2020/09/20/klavierabend-breitenfurt/ 2020/09/20/ 2020/09/
2020/10/10/pop-up-konzert/ 2020/10/10/
2020/10/25/pop-up-konzert/ 2020/10/25/ 2020/10/
2020/05/08/klavierfestival-wotrubakirche-2020/ 2020/05/08/ 2020/05/
2020/
2021/04/24/1-kunstlergesprach/
2021/04/24/2-konzert-perchtoldsdorf/ 2021/04/24/ 2021/04/
2021/
tags/konzert/ page/2/
]).each {|d| redirect "blog/#{d}index.html".gsub(%r<//>, '/'), to: "/events/#{d}".gsub(%r<//>, '/') }

13
config.ru Normal file
View File

@ -0,0 +1,13 @@
require 'middleman-core/load_paths'
::Middleman.setup_load_paths
require 'middleman-core'
require 'middleman-core/rack'
require 'fileutils'
FileUtils.mkdir('log') unless File.exist?('log')
::Middleman::Logger.singleton("log/#{ENV['RACK_ENV']}.log")
app = ::Middleman::Application.new
run ::Middleman::Rack.new(app).to_app

808
gemset.nix Normal file
View File

@ -0,0 +1,808 @@
{
activesupport = {
dependencies = ["concurrent-ruby" "i18n" "minitest" "tzinfo" "zeitwerk"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0jmqndx3a46hpwz33ximqch27018n3mk9z19azgpylm33w7xpkx4";
type = "gem";
};
version = "6.1.5";
};
addressable = {
dependencies = ["public_suffix"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "022r3m9wdxljpbya69y2i3h9g3dhhfaqzidf95m6qjzms792jvgp";
type = "gem";
};
version = "2.8.0";
};
ansi = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "14ims9zfal4gs2wpx2m5rd8zsrl2k794d359shkrsgg3fhr2a22l";
type = "gem";
};
version = "1.5.0";
};
asciidoctor = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0g8gn3g6qy4bzjv1b14sj283kqynjgwq62bgq569jr4dkqwmwnzd";
type = "gem";
};
version = "2.0.17";
};
ast = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "04nc8x27hlzlrr5c2gn7mar4vdr0apw5xg22wp6m8dx3wqr04a0y";
type = "gem";
};
version = "2.4.2";
};
awesome_print = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0vkq6c8y2jvaw03ynds5vjzl1v9wg608cimkd3bidzxc0jvk56z9";
type = "gem";
};
version = "1.9.2";
};
backports = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "13ql00lw0fpvyil0ikw3y5cwn19nvk5h5fm2z8ai19c302j2dz48";
type = "gem";
};
version = "3.23.0";
};
builder = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "045wzckxpwcqzrjr353cxnyaxgf0qg22jh00dcx7z38cys5g1jlr";
type = "gem";
};
version = "3.2.4";
};
coderay = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0jvxqxzply1lwp7ysn94zjhh57vc14mcshw1ygw14ib8lhc00lyw";
type = "gem";
};
version = "1.1.3";
};
coffee-script = {
dependencies = ["coffee-script-source" "execjs"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0rc7scyk7mnpfxqv5yy4y5q1hx3i7q3ahplcp4bq2g5r24g2izl2";
type = "gem";
};
version = "2.4.1";
};
coffee-script-source = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1907v9q1zcqmmyqzhzych5l7qifgls2rlbnbhy5vzyr7i7yicaz1";
type = "gem";
};
version = "1.12.2";
};
concurrent-ruby = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0s4fpn3mqiizpmpy2a24k4v365pv75y50292r8ajrv4i1p5b2k14";
type = "gem";
};
version = "1.1.10";
};
contracts = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1jqn5pkjpag5fzx1z8s8y97d49pb58j5ng3pmbam4ynk6j6hr5f5";
type = "gem";
};
version = "0.13.0";
};
dotenv = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0iym172c5337sm1x2ykc2i3f961vj3wdclbyg1x6sxs3irgfsl94";
type = "gem";
};
version = "2.7.6";
};
em-websocket = {
dependencies = ["eventmachine" "http_parser.rb"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1a66b0kjk6jx7pai9gc7i27zd0a128gy73nmas98gjz6wjyr4spm";
type = "gem";
};
version = "0.5.3";
};
erubis = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1fj827xqjs91yqsydf0zmfyw9p4l2jz5yikg3mppz6d7fi8kyrb3";
type = "gem";
};
version = "2.7.0";
};
eventmachine = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0wh9aqb0skz80fhfn66lbpr4f86ya2z5rx6gm5xlfhd05bj1ch4r";
type = "gem";
};
version = "1.2.7";
};
execjs = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "121h6af4i6wr3wxvv84y53jcyw2sk71j5wsncm6wq6yqrwcrk4vd";
type = "gem";
};
version = "2.8.1";
};
fast_blank = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1shpmamyzyhyxmv95r96ja5rylzaw60r19647d0fdm7y2h2c77r6";
type = "gem";
};
version = "1.0.1";
};
fastimage = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0nnggg20za5vamdpkgrxxa32z33d8hf0g2bciswkhqnc6amb3yjr";
type = "gem";
};
version = "2.2.6";
};
ffi = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1862ydmclzy1a0cjbvm8dz7847d9rch495ib0zb64y84d3xd4bkg";
type = "gem";
};
version = "1.15.5";
};
font-awesome-sass = {
dependencies = ["sassc"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "033167s6w41chjmx4sacgbkb55q0w6hrza0hrp5gngwbsflhdri7";
type = "gem";
};
version = "6.1.1";
};
haml = {
dependencies = ["temple" "tilt"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "035fgbfr20m08w4603ls2lwqbggr0vy71mijz0p68ib1am394xbf";
type = "gem";
};
version = "5.2.2";
};
hamster = {
dependencies = ["concurrent-ruby"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1n1lsh96vnyc1pnzyd30f9prcsclmvmkdb3nm5aahnyizyiy6lar";
type = "gem";
};
version = "3.0.0";
};
hashie = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "13bdzfp25c8k51ayzxqkbzag3wj5gc1jd8h7d985nsq6pn57g5xh";
type = "gem";
};
version = "3.6.0";
};
htmlcompressor = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "06hxrhfg50ccwngvpxcmh0py1fcrbwk2mpnb84cfw5qy5y58lwwj";
type = "gem";
};
version = "0.2.0";
};
"http_parser.rb" = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1gj4fmls0mf52dlr928gaq0c0cb0m3aqa9kaa6l0ikl2zbqk42as";
type = "gem";
};
version = "0.8.0";
};
i18n = {
dependencies = ["concurrent-ruby"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1hfxnlyr618s25xpafw9mypa82qppjccbh292c4l3bj36az7f6wl";
type = "gem";
};
version = "1.6.0";
};
kramdown = {
dependencies = ["rexml"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0757lqaq593z8hzdv98nai73ag384dkk7jgj3mcq2r6ix7130ifb";
type = "gem";
};
version = "2.3.2";
};
listen = {
dependencies = ["rb-fsevent" "rb-inotify"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1l0y7hbyfiwpvk172r28hsdqsifq1ls39hsfmzi1vy4ll0smd14i";
type = "gem";
};
version = "3.0.8";
};
memoist = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0i9wpzix3sjhf6d9zw60dm4371iq8kyz7ckh2qapan2vyaim6b55";
type = "gem";
};
version = "0.16.2";
};
method_source = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1pnyh44qycnf9mzi1j6fywd5fkskv3x7nmsqrrws0rjn5dd4ayfp";
type = "gem";
};
version = "1.0.0";
};
middleman = {
dependencies = ["coffee-script" "haml" "kramdown" "middleman-cli" "middleman-core"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "085cqirac439rjmsgpwn1mc2hqzwwv91xkaxzrdnrxndadik6v9m";
type = "gem";
};
version = "4.4.2";
};
middleman-asciidoc = {
dependencies = ["asciidoctor" "middleman-core"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1xqaswf3763amak09slms5fkq52j836hih9q9xabkm48myhxk0b1";
type = "gem";
};
version = "1.0.0";
};
middleman-blog = {
dependencies = ["addressable" "middleman-core" "tzinfo"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1n3hhrn3bcjrih8dia1fp1brnx9wzya74lasqy6qj13pdkybar17";
type = "gem";
};
version = "4.0.3";
};
middleman-cli = {
dependencies = ["thor"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "105nahv37gcgm0hvry934w92lw428w3x21sdd4s8mcmaad5kigk5";
type = "gem";
};
version = "4.4.2";
};
middleman-core = {
dependencies = ["activesupport" "addressable" "backports" "contracts" "dotenv" "erubis" "execjs" "fast_blank" "fastimage" "hamster" "hashie" "i18n" "listen" "memoist" "padrino-helpers" "parallel" "rack" "sassc" "servolux" "tilt" "toml" "uglifier" "webrick"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "02y7hz0p6r3npbiic5c90r5cyg6k7qzw0v65d5sn39j933vpcgki";
type = "gem";
};
version = "4.4.2";
};
middleman-deploy = {
dependencies = ["middleman-core" "net-sftp" "ptools"];
groups = ["default"];
platforms = [];
source = {
fetchSubmodules = false;
rev = "4d04b550b4c6888265d83ee9689f41e29dbae535";
sha256 = "101vf8260aw9zp9ypyb3jsbsp3nffi91aslavyhimajx3jqxf1d7";
type = "git";
url = "https://github.com/middleman-contrib/middleman-deploy.git";
};
version = "2.0.0.pre.alpha";
};
middleman-fonts = {
groups = ["default"];
platforms = [];
source = {
fetchSubmodules = false;
rev = "4664814b80cf2d13bb64255be2e9e4c133961a38";
sha256 = "0gv8ra1cc4yxjywg25kzmhvyp0ppvmbjmjppwvaqn94vi5p292rk";
type = "git";
url = "https://git.denkn.at/deac/middleman-fonts.git";
};
version = "0.0.1";
};
middleman-livereload = {
dependencies = ["em-websocket" "middleman-core" "rack-livereload"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0ynzdpyi64brh66gx3qn04d7qsypfa37jf7afai9mx1bhss0f0qx";
type = "gem";
};
version = "3.4.7";
};
middleman-minify-html = {
dependencies = ["htmlcompressor" "middleman-core"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "19vckqic6w6jg700vb82cqzzp89hrc9a00ffnhldr6lvhh33ng7s";
type = "gem";
};
version = "3.4.1";
};
mini_magick = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1aj604x11d9pksbljh0l38f70b558rhdgji1s9i763hiagvvx2hs";
type = "gem";
};
version = "4.11.0";
};
mini_portile2 = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0rapl1sfmfi3bfr68da4ca16yhc0pp93vjwkj7y3rdqrzy3b41hy";
type = "gem";
};
version = "2.8.0";
};
minitest = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "06xf558gid4w8lwx13jwfdafsch9maz8m0g85wnfymqj63x5nbbd";
type = "gem";
};
version = "5.15.0";
};
net-sftp = {
dependencies = ["net-ssh"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "185vsybznqgqbb4i2qnxvf1gam8lb634nqcrq7r3i2zy1g6xd8mi";
type = "gem";
};
version = "3.0.0";
};
net-ssh = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0jp3jgcn8cij407xx9ldb5h9c6jv13jc4cf6kk2idclz43ww21c9";
type = "gem";
};
version = "6.1.0";
};
nio4r = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0xk64wghkscs6bv2n22853k2nh39d131c6rfpnlw12mbjnnv9v1v";
type = "gem";
};
version = "2.5.8";
};
nokogiri = {
dependencies = ["mini_portile2" "racc"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1g43ii497cwdqhfnaxfl500bq5yfc5hfv5df1lvf6wcjnd708ihd";
type = "gem";
};
version = "1.13.4";
};
oga = {
dependencies = ["ast" "ruby-ll"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0k7cxknd4ka33fkzx6sffh0mibn1cl5kf2n7pa7z2knj9mc4l0a0";
type = "gem";
};
version = "3.3";
};
padrino-helpers = {
dependencies = ["i18n" "padrino-support" "tilt"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1487yickg3d3qpz314wkj6m22wdy9y02crk1g9wal554s7w14mf9";
type = "gem";
};
version = "0.15.1";
};
padrino-support = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "053y53nxlx391c34q3wk34b6wga8zf3y98zcx296l09iylk8q6gk";
type = "gem";
};
version = "0.15.1";
};
parallel = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "07vnk6bb54k4yc06xnwck7php50l09vvlw1ga8wdz0pia461zpzb";
type = "gem";
};
version = "1.22.1";
};
parslet = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "01pnw6ymz6nynklqvqxs4bcai25kcvnd5x4id9z3vd1rbmlk0lfl";
type = "gem";
};
version = "2.0.0";
};
pry = {
dependencies = ["coderay" "method_source"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0m445x8fwcjdyv2bc0glzss2nbm1ll51bq45knixapc7cl3dzdlr";
type = "gem";
};
version = "0.14.1";
};
ptools = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1q0c06gjxmbxqash4d76shmqb707q7i1hn2jg3g6vkqm3d1rjwxn";
type = "gem";
};
version = "1.4.2";
};
public_suffix = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1f3knlwfwm05sfbaihrxm4g772b79032q14c16q4b38z8bi63qcb";
type = "gem";
};
version = "4.0.7";
};
puma = {
dependencies = ["nio4r"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0dgr2rybayih2naz3658mbzqwfrg9fxl80zsvhscf6b972kp3jdw";
type = "gem";
};
version = "5.6.4";
};
r18n-core = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0438li8g5jvj3mmjigdiglnpjdnhxvn5dd7n1dxmrp4i0a74akis";
type = "gem";
};
version = "5.0.1";
};
r18n-desktop = {
dependencies = ["r18n-core"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0nacclz89dv7n2gkb4jwkqgas6lk24mb1g905qcps2n89wylmhin";
type = "gem";
};
version = "5.0.1";
};
racc = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0la56m0z26j3mfn1a9lf2l03qx1xifanndf9p3vx1azf6sqy7v9d";
type = "gem";
};
version = "1.6.0";
};
rack = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0i5vs0dph9i5jn8dfc6aqd6njcafmb20rwqngrf759c9cvmyff16";
type = "gem";
};
version = "2.2.3";
};
rack-livereload = {
dependencies = ["rack"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1slzlmvlapgp2pc7389i0zndq3nka0s6sh445vf21cxpz7vz3p5i";
type = "gem";
};
version = "0.3.17";
};
rake = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "15whn7p9nrkxangbs9hh75q585yfn66lv0v2mhj6q6dl6x8bzr2w";
type = "gem";
};
version = "13.0.6";
};
rb-fsevent = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "06c50pvxib7wqnv6q0f3n7gzfcrp5chi3sa48hxpkfxc3hhy11fm";
type = "gem";
};
version = "0.11.1";
};
rb-inotify = {
dependencies = ["ffi"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1jm76h8f8hji38z3ggf4bzi8vps6p7sagxn3ab57qc0xyga64005";
type = "gem";
};
version = "0.10.1";
};
rexml = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "08ximcyfjy94pm1rhcx04ny1vx2sk0x4y185gzn86yfsbzwkng53";
type = "gem";
};
version = "3.2.5";
};
ruby-ll = {
dependencies = ["ansi" "ast"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0hrwkmaywqdcz4916pwy0s0lxlgd0s4fxkx57kb6bird9wjxazqn";
type = "gem";
};
version = "2.1.2";
};
sassc = {
dependencies = ["ffi"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0gpqv48xhl8mb8qqhcifcp0pixn206a7imc07g48armklfqa4q2c";
type = "gem";
};
version = "2.4.0";
};
servolux = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "068mjsim0259122rizmkh54d1yjwdsnx66cvk251s1pqb1ac8cqs";
type = "gem";
};
version = "0.13.0";
};
temple = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "060zzj7c2kicdfk6cpnn40n9yjnhfrr13d0rsbdhdij68chp2861";
type = "gem";
};
version = "0.8.2";
};
thor = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0inl77jh4ia03jw3iqm5ipr76ghal3hyjrd6r8zqsswwvi9j2xdi";
type = "gem";
};
version = "1.2.1";
};
tilt = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0rn8z8hda4h41a64l0zhkiwz2vxw9b1nb70gl37h1dg2k874yrlv";
type = "gem";
};
version = "2.0.10";
};
toml = {
dependencies = ["parslet"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1fg4qvn5c80z4ysy7j1svz0milsq5yqr6mpr8i7fhdlhdbvx148a";
type = "gem";
};
version = "0.3.0";
};
tzinfo = {
dependencies = ["concurrent-ruby"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "10qp5x7f9hvlc0psv9gsfbxg4a7s0485wsbq1kljkxq94in91l4z";
type = "gem";
};
version = "2.0.4";
};
uglifier = {
dependencies = ["execjs"];
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "0wmqvn4xncw6h3d5gp2a44170zwxfyj3iq4rsjp16zarvzbdmgnz";
type = "gem";
};
version = "3.2.0";
};
webrick = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "1d4cvgmxhfczxiq5fr534lmizkhigd15bsx5719r5ds7k7ivisc7";
type = "gem";
};
version = "1.7.0";
};
zeitwerk = {
groups = ["default"];
platforms = [];
source = {
remotes = ["https://rubygems.org"];
sha256 = "09bq7j2p6mkbxnsg71s253dm2463kg51xc7bmjcxgyblqbh4ln7m";
type = "gem";
};
version = "2.5.4";
};
}

82
lib/adoc.rb Normal file
View File

@ -0,0 +1,82 @@
require 'asciidoctor'
require 'tilt/asciidoc'
Haml::Filters.register_tilt_filter :Asciidoc, alias: %w[ad adoc]
class Middleman::Extension
private
unless method_defined? :initialize_without_debug
def initialize_with_debug *a, **o, &e
STDERR.printf "> ME-init: class=%p\nargs=%p\nopts=%p\n", self.class, a, o
initialize_without_debug *a, **o, &e
STDERR.printf "< ME-init: self=%p\n", self
end
alias initialize_without_debug initialize
alias initialize initialize_with_debug
end
end if false
class Middleman::ExtensionManager
unless method_defined? :activate_without_debug
def activate_with_debug *arguments, **options, &exe
STDERR.printf "> MEM-activate: class=%p\narguments=%p\noptions=%p\n", self.class, arguments, options
r = activate_without_debug *arguments, **options, &exe
STDERR.printf "< MEM-activate: r=%p\nasciidoc=%p\n", r, @activated[:asciidoc]
r
end
alias activate_without_debug activate
alias activate activate_with_debug
end
end if false
class Middleman::AsciiDoc::AsciiDocExtension
option :template_dirs, [], 'Custom templates' unless config.defines_setting? :template_dirs
option :template_cache, [], 'Deactivate cache for custom templates' unless config.defines_setting? :template_cache
option :template_engine, nil, 'Template engine to use for custome templates' unless config.defines_setting? :template_engine
end
module ::Asciidoctor
class << self
def load_file_with_debug fn, **opts, &e
# opts[:template_dir] ||= opts[:attributes][:template_dir]
# opts[:template_engine] ||= opts[:attributes][:template_engine]
opts[:template_dir] ||= 'asciidoctor-backends/haml'
opts[:template_engine] ||= 'haml'
opts[:template_cache] = false unless opts.has_key? :template_cache
STDERR.printf "> AD.load_file %p\nopts=%p\n", fn, opts
load_file_without_debug fn, **opts, &e
end
alias load_file_without_debug load_file
alias load_file load_file_with_debug
end unless respond_to? :load_file_without_debug
end if false
class ::Asciidoctor::Document
unless method_defined? :create_converter_without_debug
def create_converter_with_debug
STDERR.printf "> ADD.create_converter options=%p\n", @options
r = create_converter_without_debug
STDERR.printf "< ADD.create_converter return=%p\n", r
r
end
alias create_converter_without_debug create_converter
alias create_converter create_converter_with_debug
end
end if false
class ::Asciidoctor::Document
private
unless private_method_defined? :initialize_without_debug
def initialize_with_debug *args, **opts, &exe
opts = opts.merge template_dir: 'asciidoctor-backends/haml', template_dirs: ['asciidoctor-backends/haml'], template_engine: 'haml', template_cache: false, base_dir: 'source'
initialize_without_debug *args, **opts.symbolize_keys, &exe
end
alias initialize_without_debug initialize
alias initialize initialize_with_debug
end
end

151
lib/fonts4web.rb Normal file
View File

@ -0,0 +1,151 @@
require 'json'
require 'active_support/all'
require 'fileutils'
require 'shellwords'
class ::Metadata2FontsCss < ::Middleman::Extension
def initialize app, **options_hash, &block
super
@additional_extentions = %w[woff]
end
def included() true end
alias registered included
class <<self
def included() true end
alias registered included
end
FontFace = <<EOF.gsub( /^\s*(.*?)\s*$/, '\1').gsub /\n/m, ''
@font-face {
font-family: "%<name>s";
font-weight: %<weight>i;
font-style: %<style>s;
src:
local("%<fullName>s"),
local("%<postScriptName>s"),
url("%<woff>s") format("woff"),
url("%<ttf>s") format("truetype");
}
EOF
def manipulate_resource_list resources
fonts_css = StringIO.new
resources.lazy.
select {|res| Pathname.new( res.path).basename.to_s == 'METADATA.json' }.
map do |res|
JSON.parse( File.read( f))['fonts'].each do |font|
font = font.symbolize_keys
font[:ttf] = "/assets/fonts/#{font[:filename]}"
font[:woff] = "/assets/fonts/#{font[:filename].gsub /\.[ot]tf\Z/, '.woff'}"
fonts_css.printf FontFace, font
end
end
resources.delete_if do |res|
path = Pathname.new res.path
if 'assets' == path.descend.first.to_s
case path.basename.to_s
when 'METADATA.pb' then true
when 'METADATA.json' then true
when 'DESCRIPTION.en_us.html' then true
when 'OFL.txt' then true
else false
end
else false
end
end
resources << ::Middleman::Sitemap::StringResource.new(
self.app.sitemap,
'assets/styles/fonts.css',
fonts_css.string)
resources
end
end
::Middleman::Extensions.register :fonts_css, ::Metadata2FontsCss
class ::Fonts4Web < ::Middleman::Extension
def initialize app, **options_hash, &block
super
@converter = 'sfnt2woff-zopfli'
@cachepath = Pathname.new '.fonts_cache'
end
def included() true end
alias registered included
class <<self
def included() true end
alias registered included
end
def spawn *a, **options
a = a.map &:to_s
if options[:verbose]
pre = ''
pre = "cd #{Shellwords.escape options[:chdir]}; " if options.has_key? :chdir
STDERR.puts "$ #{pre}#{a.shelljoin}"
end
options.delete :verbose
options[:chdir] &&= options[:chdir].to_s
pid = Process.spawn *a, **options
_, status = Process.wait2 pid
status
end
def convert builder, src, dest = nil
# files:
f = src.basename
d = Pathname.new "#{src.basename src.extname}.woff"
# files in cache:
symlink = @cachepath + f
cache_dest = @cachepath + d
relsrc = src.expand_path.relative_path_from @cachepath.expand_path
dest = dest ? Pathname.new( dest) : cache_dest
@cachepath.mkpath
# dest is not older than src, we can use the cache
if dest.exist? and dest.lstat >= src.lstat
builder.trigger :identical, "#{dest}"
return dest
end
# cache_dest is older than source
unless cache_dest.exist? and cache_dest.lstat >= src.lstat
# prepare cache-files:
symlink.unlink if begin symlink.lstat; rescue Errno::ENOENT; false; end
symlink.make_symlink relsrc
# convert:
status = spawn @converter, symlink.basename, chdir: symlink.dirname
raise "Convertion #{src} failed!" unless 0 == status.exitstatus
raise "Convertion #{src} failed!" unless cache_dest.exist?
end
# deliver dest:
unless cache_dest == dest
FileUtils.copy cache_dest, dest, verbose: false
end
builder.trigger :created, "#{dest}"
dest
end
def after_build builder
paths = ::Middleman::Util.all_files_under( app.config[:build_dir])
paths.each do |path|
path = Pathname.new path
if 'assets' == path.relative_path_from( Pathname.new(@app.config[:build_dir])).descend.first.to_s
case path.extname
when '.otf', '.ttf'
new = path.dirname + "#{path.basename path.extname}.woff"
woff = convert builder, path, path.dirname + "#{path.basename path.extname}.woff"
end
end
end
end
end
::Middleman::Extensions.register :fonts4web, ::Fonts4Web

6
locales/de.yml Normal file
View File

@ -0,0 +1,6 @@
---
de:
test: Dies ist ein Test
time:
formats:
month: '%B'

3
locales/en.yml Normal file
View File

@ -0,0 +1,3 @@
---
en:
test: This is a test

13
shell.nix Normal file
View File

@ -0,0 +1,13 @@
with (import <nixpkgs> {});
let
env = bundlerEnv {
name = "homepage-bundler-env";
inherit ruby;
gemfile = ./Gemfile;
lockfile = ./Gemfile.lock;
gemset = ./gemset.nix;
};
in stdenv.mkDerivation {
name = "hudlergrube-homepage";
buildInputs = [ pkgs.ruby env env.gems.puma env.gems.middleman poppler_utils graphicsmagick-imagemagick-compat graphicsmagick ];
}

0
source/.keep Normal file
View File

67
source/404.html Normal file
View File

@ -0,0 +1,67 @@
<!DOCTYPE html>
<html>
<head>
<title>The page you were looking for doesn't exist (404)</title>
<meta name="viewport" content="width=device-width,initial-scale=1">
<style>
.rails-default-error-page {
background-color: #EFEFEF;
color: #2E2F30;
text-align: center;
font-family: arial, sans-serif;
margin: 0;
}
.rails-default-error-page div.dialog {
width: 95%;
max-width: 33em;
margin: 4em auto 0;
}
.rails-default-error-page div.dialog > div {
border: 1px solid #CCC;
border-right-color: #999;
border-left-color: #999;
border-bottom-color: #BBB;
border-top: #B00100 solid 4px;
border-top-left-radius: 9px;
border-top-right-radius: 9px;
background-color: white;
padding: 7px 12% 0;
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
}
.rails-default-error-page h1 {
font-size: 100%;
color: #730E15;
line-height: 1.5em;
}
.rails-default-error-page div.dialog > p {
margin: 0 0 1em;
padding: 1em;
background-color: #F7F7F7;
border: 1px solid #CCC;
border-right-color: #999;
border-left-color: #999;
border-bottom-color: #999;
border-bottom-left-radius: 4px;
border-bottom-right-radius: 4px;
border-top-color: #DADADA;
color: #666;
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
}
</style>
</head>
<body class="rails-default-error-page">
<!-- This file lives in public/404.html -->
<div class="dialog">
<div>
<h1>The page you were looking for doesn't exist.</h1>
<p>You may have mistyped the address or the page may have moved.</p>
</div>
<p>If you are the application owner check the logs for more information.</p>
</div>
</body>
</html>

67
source/422.html Normal file
View File

@ -0,0 +1,67 @@
<!DOCTYPE html>
<html>
<head>
<title>The change you wanted was rejected (422)</title>
<meta name="viewport" content="width=device-width,initial-scale=1">
<style>
.rails-default-error-page {
background-color: #EFEFEF;
color: #2E2F30;
text-align: center;
font-family: arial, sans-serif;
margin: 0;
}
.rails-default-error-page div.dialog {
width: 95%;
max-width: 33em;
margin: 4em auto 0;
}
.rails-default-error-page div.dialog > div {
border: 1px solid #CCC;
border-right-color: #999;
border-left-color: #999;
border-bottom-color: #BBB;
border-top: #B00100 solid 4px;
border-top-left-radius: 9px;
border-top-right-radius: 9px;
background-color: white;
padding: 7px 12% 0;
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
}
.rails-default-error-page h1 {
font-size: 100%;
color: #730E15;
line-height: 1.5em;
}
.rails-default-error-page div.dialog > p {
margin: 0 0 1em;
padding: 1em;
background-color: #F7F7F7;
border: 1px solid #CCC;
border-right-color: #999;
border-left-color: #999;
border-bottom-color: #999;
border-bottom-left-radius: 4px;
border-bottom-right-radius: 4px;
border-top-color: #DADADA;
color: #666;
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
}
</style>
</head>
<body class="rails-default-error-page">
<!-- This file lives in public/422.html -->
<div class="dialog">
<div>
<h1>The change you wanted was rejected.</h1>
<p>Maybe you tried to change something you didn't have access to.</p>
</div>
<p>If you are the application owner check the logs for more information.</p>
</div>
</body>
</html>

66
source/500.html Normal file
View File

@ -0,0 +1,66 @@
<!DOCTYPE html>
<html>
<head>
<title>We're sorry, but something went wrong (500)</title>
<meta name="viewport" content="width=device-width,initial-scale=1">
<style>
.rails-default-error-page {
background-color: #EFEFEF;
color: #2E2F30;
text-align: center;
font-family: arial, sans-serif;
margin: 0;
}
.rails-default-error-page div.dialog {
width: 95%;
max-width: 33em;
margin: 4em auto 0;
}
.rails-default-error-page div.dialog > div {
border: 1px solid #CCC;
border-right-color: #999;
border-left-color: #999;
border-bottom-color: #BBB;
border-top: #B00100 solid 4px;
border-top-left-radius: 9px;
border-top-right-radius: 9px;
background-color: white;
padding: 7px 12% 0;
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
}
.rails-default-error-page h1 {
font-size: 100%;
color: #730E15;
line-height: 1.5em;
}
.rails-default-error-page div.dialog > p {
margin: 0 0 1em;
padding: 1em;
background-color: #F7F7F7;
border: 1px solid #CCC;
border-right-color: #999;
border-left-color: #999;
border-bottom-color: #999;
border-bottom-left-radius: 4px;
border-bottom-right-radius: 4px;
border-top-color: #DADADA;
color: #666;
box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
}
</style>
</head>
<body class="rails-default-error-page">
<!-- This file lives in public/500.html -->
<div class="dialog">
<div>
<h1>We're sorry, but something went wrong.</h1>
</div>
<p>If you are the application owner check the logs for more information.</p>
</div>
</body>
</html>

View File

View File

View File

@ -0,0 +1,21 @@
window.price_sum_field_calculator = (count_fields_sel='.count.field', sum_field_sel='#sum_field') ->
fields = document.querySelectorAll count_fields_sel
sum_field = document.querySelector sum_field_sel
change_f = (e) ->
sum = 0
for el in fields
price = el.getAttribute 'data-price'
sf = el.getAttribute 'for'
s = 1 * el.value * price
sfe = document.querySelector "##{sf}"
sfe.textContent = (if 0==s then '' else s) if sfe
sum += s
sum_field.textContent = sum
for el in fields
el.addEventListener 'change', change_f
el.addEventListener 'input', change_f
change_f()

View File

@ -0,0 +1,30 @@
$fonts-url: '/assets/fonts';
@mixin font-face($family, $local1, $local2, $rpath, $weight: normal, $style: normal) {
$path: "#{$fonts-url}/#{$rpath}";
@font-face {
font-family: $family;
font-weight: $weight;
font-style: $style;
src: local($local1),
local($local2),
url("#{$path}.woff") format("woff"),
url("#{$path}.ttf") format("truetype");
}
}
@include font-face ('Alegreya', 'Alegreya Regular', 'Alegreya-Regular', 'Alegreya/Alegreya-Regular', 400);
@include font-face ('Alegreya', 'Alegreya Italic', 'Alegreya-Italic', 'Alegreya/Alegreya-Italic', 400, italic);
@include font-face ('Alegreya', 'Alegreya Medium', 'Alegreya-Medium', 'Alegreya/Alegreya-Medium', 500);
@include font-face ('Alegreya', 'Alegreya MediumItalic', 'Alegreya-MediumItalic', 'Alegreya/Alegreya-MediumItalic', 500, italic);
@include font-face ('Alegreya', 'Alegreya Bold', 'Alegreya-Bold', 'Alegreya/Alegreya-Bold', 700);
@include font-face ('Alegreya', 'Alegreya BoldItalic', 'Alegreya-BoldItalic', 'Alegreya/Alegreya-BoldItalic', 700, italic);
@include font-face ('Alegreya Sans', 'Alegreya Sans Regular', 'AlegreyaSans-Regular', 'Alegreya_Sans/AlegreyaSans-Regular', 400);
@include font-face ('Alegreya Sans', 'Alegreya Sans Italic', 'AlegreyaSans-Italic', 'Alegreya_Sans/AlegreyaSans-Italic', 400, italic);
@include font-face ('Alegreya Sans', 'Alegreya Sans Medium', 'AlegreyaSans-Medium', 'Alegreya_Sans/AlegreyaSans-Medium', 500);
@include font-face ('Alegreya Sans', 'Alegreya Sans MediumItalic', 'AlegreyaSans-MediumItalic', 'Alegreya_Sans/AlegreyaSans-MediumItalic', 500, italic);
@include font-face ('Alegreya Sans', 'Alegreya Sans Bold', 'AlegreyaSans-Bold', 'Alegreya_Sans/AlegreyaSans-Bold', 700);
@include font-face ('Alegreya Sans', 'Alegreya Sans BoldItalic', 'AlegreyaSans-BoldItalic', 'Alegreya_Sans/AlegreyaSans-BoldItalic', 700, italic);
@include font-face ('Inconsolata', 'Inconsolata Regular', 'Inconsolata-Regular', 'Inconsolata/Inconsolata-Regular', 400);
@include font-face ('Inconsolata', 'Inconsolata Bold', 'Inconsolata-Bold', 'Inconsolata/Inconsolata-Bold', 700);

View File

@ -0,0 +1,12 @@
// vim: set noet sw=2 sts=2 ts=2:
$fa-font-path: "/assets/fonts/font-awesome";
@function font-path($path) {
@return "/assets/fonts/#{$path}";
}
@import "font-awesome";
@import "_fonts.scss";
* {
text-rendering: optimizeLegibility;
}

0
source/favicon.ico Normal file
View File

View File

@ -0,0 +1,20 @@
<!doctype html>
<html>
<head>
<meta content="IE=edge" http-equiv="X-UA-Compatible">
<meta charset="utf-8">
<meta content="width=device-width,initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" name="viewport">
<!-- Use title if it's in the page YAML frontmatter -->
<title><%= current_page.data.title || "Middleman" %></title>
<link href='//fonts.googleapis.com/css?family=Lato:300,400' rel='stylesheet' type='text/css'>
<%= stylesheet_link_tag :site %>
<%= javascript_include_tag :all %>
</head>
<body class="<%= page_classes %>">
<%= yield %>
</body>
</html>

View File

@ -0,0 +1,21 @@
._aside
%aside#navigation
- unless current_page.data.nonav
= partial 'layouts/nav'
-#
%h2 Recent Articles
%ol
- blog.articles[0...10].each do |article|
%li
= link_to article.title, article
%span= article.date.strftime '%b %e'
%h2 Tags
%ol
- blog.tags.each do |tag, articles|
%li= link_to "#{tag} (#{articles.size})", tag_path(tag)
%h2 By Year
%ol
- blog.articles.group_by {|a| a.date.year }.each do |year, articles|
%li= link_to "#{year} (#{articles.size})", blog_year_path(year)

View File

@ -0,0 +1,69 @@
- unless @breadcrumbs.nil?
%nav.breadcrumbs
%ul
- @breadcrumbs.each do |c|
- c = Array.wrap c
- if 1 < c.count
%li= link_to *c
- else
%li= c
._footer
.teaser
%footer
%h1 Renate Hudler &amp; Karl Heinz Grube
.row_maybe.meh
.col
%h4 Datenschutz
%ul
-#.fa-ul
-#%li
-#%span.fa-li.fa-stack
%i.fas.fa-envelope.fa-stack-0_5x
%i.fas.fa-ban.fa-stack-1x(style="color:Tomato")
Keine Cookies :)
%li
-#%span.fa-li.fa-stack
%i.fas.fa-shoe-prints.fa-stack-0_5x
%i.fas.fa-ban.fa-stack-1x(style="color:Tomato")
Kein Tracking :)
%li
-#%span.fa-li
%i.fas.fa-ticket-alt
Bei Ticketbestellungen werden Ihre angegebenen Daten übermittelt und für die Erfüllung der Bestellung gespeichert und nach dem Konzert gelöscht.
%li
Desweiteren wird ein Cookie während der Ticketbestellung gespeichert.
%li
-#%span.fa-li
%i.fas.fa-envelope
Wenn Sie sich für unseren Newsletter anmelden, speichern wir Ihre angegeben Daten solange Sie den Newsletter erhalten möchten.
.col
%h4 Impressum
%dl
%dt Kontakt
%dd
%p
%a(href="mailto:kontakt@hudlergrube.com")
%i.fas.fa-envelope.fa-fw
Renate Hudler &amp; Karl Heinz Grube
%p
%i.fas.fa-map-marker-alt.fa-fw
Renate Hudler
%br
Rudolf-Jankostr. 3
%br
2380 Perchtoldsdorf
-#%p
%i.fas.fa-phone.fa-fw
+43 6
%dt Design
%dd
%a(href="https://denkn.at" title="DenKn" target="_blank")
%i.fas.fa-external-link-square-alt.fa-fw
DenKn.at
%dd
%a(href="https://www.instagram.com/_klararts_/" title="Klaras Instagram" target="_blank")
%i.fab.fa-instagram.fa-fw
Klara Arts
-#.totopto
%a(href="#") &#11014;

View File

@ -0,0 +1,14 @@
%head
%meta(charset="utf-8")
%meta(http-equiv="X-UA-Compatible" content="IE=edge")
%meta(name="viewport" content="width=device-width, initial-scale=1")
%title= current_page.data.title || ''
-#%meta{name: :description, content: site.description}
%link(rel="stylesheet" href="/assets/styles/fonts.css")
%link(rel="stylesheet" href="/assets/styles/all.css")
- if current_page.data.stylesheet
%link(rel="stylesheet" href="/assets/styles/#{current_page.data.stylesheet}.css")
-#%script(type="text/javascript" src="/assets/scripts/all.js")
-#%link(rel="canonical" href="{{ page.url | replace:'index.html','' | prepend: site.baseurl | prepend: site.url }}")
-#%link(rel="alternate" type="application/rss+xml" title="{{ site.title }}" href="{{ '/feed.xml' | prepend: site.baseurl | prepend: site.url }}")

View File

@ -0,0 +1,5 @@
._header
%header
%h1
= current_page.data.title || ''
//.header-sticky= partial 'layouts/aside'

View File

@ -0,0 +1,46 @@
%nav<>
%ul.right<>
-#%li
%a(href='https://hölle.de' title="Facebock")
%i.fab.fa-facebook-square
-#%li
%a(href='https://schnackseln.at' title="Zwitscher")
%i.fab.fa-twitter-square
%li
= link_to 'https://www.youtube.com/channel/UC8xM33hBE4lEmiZl9aTvAbA', title: "Unser Youtube-Channel", hover: 'Youtube', target: :_blank do
%i.fab.faw.fa-youtube
%span.HIDDEN Youtube
%li
= link_to 'mailto:kontakt@hudlergrube.com', title: "Schreiben Sie uns eine Email", hover: 'Mail' do
%i.fas.faw.fa-envelope
%span.HIDDEN Email
%ul.left<>
%li{class: [active_page?("/") && :active_page]}
= link_to '/', title: 'Hudler & Grube' do
%i.fas.faw.fa-home
%span.HIDDEN Hudler &amp; Grube Homepage
%li{class: [active_page?("/events") && :active_page]}
= link_to '/events', title: 'Veranstaltungen', hover: 'Veranstaltungen' do
%i.fa-solid.fa-tw.fa-calendar-alt
%span.HIDDEN Kalender
-#%li{class: [active_page?("/gallery") && :active_page]}
= link_to '/gallery', title: 'Veranstaltungs- & Künstlerphotos', hover: 'Veranstaltungs- & Künstlerphotos' do
%i.fas.faw.fa-camera
%span.HIDDEN Veranstaltungs- &amp; Künstlerphotos
%li{class: [active_page?("/bio") && :active_page]}
= link_to '/bio', title: 'Biographien', hover: 'Biographien' do
%i.fas.faw.fa-id-badge
%span.HIDDEN Biographien
%li{class: [active_page?("/repertoire") && :active_page]}
= link_to '/repertoire', title: 'Repertoire', hover: 'Repertoire' do
%i.fas.faw.fa-folder-open
%span.HIDDEN Repertoire
-#%li
= link_to '/videos', title: 'Musik und Videos' do
%i.fas.fa-film
-#%li
%a(href='/music.html')
-#%i.fas.fa-music
Musik
-#%li= link_to 'Live', '/live.html'
-#%li= link_to 'Festival', '/festival/', title: 'Unser geplantes Festival im Mai'

View File

@ -0,0 +1,5 @@
!!! 5
%html#_{lang: :de, class: current_page.data.style, style: current_page.data[:background_image] ? "--global-background-image: url(#{current_page.data.background_image})" : nil}
= partial 'layouts/head'
%body{class: (current_page.data.type || 'page')}
= yield

View File

@ -0,0 +1,12 @@
= partial 'layouts/base', {} do
= partial 'layouts/header'
= partial 'layouts/aside'
._main
%main
//.border-a
//.border-b
.beginning_content
= yield
.ending_content
//end of default
= partial 'layouts/footer'

View File

@ -0,0 +1,5 @@
= partial 'layouts/default' do
-#%header.post-header
-# %h1.post-title= current_page.data.title
-#%article.post-content= yield
%article= yield

1
source/robots.txt Normal file
View File

@ -0,0 +1 @@
# See http://www.robotstxt.org/robotstxt.html for documentation on how to use the robots.txt file