ddfreyne on 4.12.1
Always write stack trace backwa… Merge branch 'stack-trace-alway… Expand paths in a more backward… and 5 more (compare)
ddfreyne on 4.12.0
ddfreyne on main
Always write stack trace backwa… Merge branch 'stack-trace-alway… Expand paths in a more backward… and 5 more (compare)
ddfreyne on 4.12.1
ddfreyne on bundler
ddfreyne on main
Bump kramdown from 2.3.0 to 2.3… Merge pull request #254 from na… (compare)
ddfreyne on main
Upgrade Rubocop (compare)
dependabot[bot] on bundler
Bump kramdown from 2.3.0 to 2.3… (compare)
ddfreyne on main
Expand paths in filesystem data… Merge branch 'expand-dirs-in-fi… Add universal license at root (compare)
#!/bin/sh
set -e
hr() {
printf "%.0s—" $(seq 1 80)
printf '\n'
}
bundle config set --local deployment true
bundle config set --local path .bundle
bundle config set --local without development
if ! bundle check 2>/dev/null; then
hr
printf "Installing gems...\n"
bundle install
printf 'done.\n'
hr
fi
exec bundle exec nanoc "$@"
/home/vagrant/.bundle/ruby/2.7.0/gems/nanoc-cli-4.11.16/lib/nanoc/cli/commands/show-plugins.rb:17: warning: already initialized constant Nanoc::CLI::Commands::ShowPlugins::PLUGIN_CLASS_ORDER
/home/vagrant/.bundle/ruby/2.7.0/gems/nanoc-cli-4.11.16/lib/nanoc/cli/commands/show-plugins.rb:17: warning: previous definition of PLUGIN_CLASS_ORDER was here
/home/vagrant/.bundle/ruby/2.7.0/gems/nanoc-cli-4.11.16/lib/nanoc/cli/commands/show-plugins.rb:22: warning: already initialized constant Nanoc::CLI::Commands::ShowPlugins::PLUGIN_CLASSES
/home/vagrant/.bundle/ruby/2.7.0/gems/nanoc-cli-4.11.16/lib/nanoc/cli/commands/show-plugins.rb:22: warning: previous definition of PLUGIN_CLASSES was here
/home/vagrant/.bundle/ruby/2.7.0/gems/nanoc-cli-4.11.16/lib/nanoc/cli/commands/view.rb:19: warning: already initialized constant Nanoc::CLI::Commands::View::DEFAULT_HANDLER_NAME
/home/vagrant/.bundle/ruby/2.7.0/gems/nanoc-cli-4.11.16/lib/nanoc/cli/commands/view.rb:19: warning: previous definition of DEFAULT_HANDLER_NAME was here
nanoc live
from within the container is not really bearable
3000
from host to guest guest
$ bundle exec nanoc view
$ bundle exec nanoc view -o 0.0.0.0
nanoc view
?
Cannot download livereload.js
#<Thread:0x00007f98a1d07280 /usr/local/lib/ruby/gems/2.7.0/gems/guard-livereload-2.5.2/lib/guard/livereload/reactor.rb:11 run> terminated with exception (report_on_exception is true):
/usr/local/lib/ruby/gems/2.7.0/gems/eventmachine-1.2.7/lib/eventmachine.rb:531:in `start_tcp_server'14:17:51 - INFO - Guard is now watching at '/Users/greedo/Projects/myscript_sdk/doc'
: no acceptor (port is in use or requires root privileges) (RuntimeError)
from /usr/local/lib/ruby/gems/2.7.0/gems/eventmachine-1.2.7/lib/eventmachine.rb:531:in `start_server'
from /usr/local/lib/ruby/gems/2.7.0/gems/guard-livereload-2.5.2/lib/guard/livereload/reactor.rb:51:in `block in _start_reactor'
from /usr/local/lib/ruby/gems/2.7.0/gems/eventmachine-1.2.7/lib/eventmachine.rb:171:in `run'
from /usr/local/lib/ruby/gems/2.7.0/gems/guard-livereload-2.5.2/lib/guard/livereload/reactor.rb:50:in `_start_reactor'
from /usr/local/lib/ruby/gems/2.7.0/gems/guard-livereload-2.5.2/lib/guard/livereload/reactor.rb:11:in `block in initialize'
bundle exec nanoc live -L -V
nanoc live -L
if I have guard live reload
Magick::ImageMagickError: unable to open image `/vagrant/output/images/convert-batch.png': No such file or directory @ error/blob.c/OpenBlob/2874
Current item: /tools/inktool/overview.md (:default representation)
0. _factory/lib/images.rb:43:in `ping'
1. _factory/lib/images.rb:43:in `image'
2. item /tools/inktool/overview.md (rep default):185:in `get_binding'
output/
before it has arrived
output/
before launching compilation of item A. Is it what Nanoc is currently doing?
nanoc live
(the one that is provided by guard-nanoc) is a thin wrapper around both
what it the 'trick' in the blogging extension, why the question if items are frozen, and if, the data gets assigned to a variable just to return that
blk = -> { @items.select { |item| item[:kind] == 'article' } }
if @items.frozen?
@article_items ||= blk.call
else
blk.call
end
I can understsand that there might be some caching wanted, and that the result is returned if it exists
or does this something different?
but why the items.frozen question ? if this is not the case there is no caching, when is which branch relevant?
So, if you have one blog index page that depends on all individual articles, you could do e.g.
@items.find_all('/articles/*').each(&:path)
to force a dependency onto all those pages
A question to this ... what does it mean.. :-) , what does .each(&:path)
actually call on the item?
my ruby is not that strong, and from the doc I see there is a path property, but I am unsure how that relates, but I am very interested in understanding .