1
0
Fork 0
mirror of https://github.com/fmap/muflax65ngodyewp.onion synced 2024-06-18 09:16:48 +02:00

check for unresolved links in published articles

This commit is contained in:
muflax 2012-04-16 15:45:42 +02:00
parent 409a5ed33a
commit 0cb2970d5b
3 changed files with 16 additions and 1 deletions

1
Rules
View file

@ -83,6 +83,7 @@ compile '*' do
when "mkd" # normal pages
filter :erb
filter :kramdown, :toc_levels => [1,2]
filter :markdown_link_check unless @item.draft?
filter :colorize_syntax, :default_colorizer => :pygmentize
when "org" # org-mode pages
filter :org

View file

@ -198,7 +198,7 @@ Thus ends the thought experiment. And here is the question: which of these world
Yet if we believed the asymmetry, then there would be a clear winner - namely *Absencia*! In Absencia, there was a potential for great harm. Had the pie maker not noticed the wrong pot, then the customer's day would've been ruined. But fortunately, this harm was avoided and so, says the asymmetry, an additional good was produced for the customer. Ergo, Absencia is the best.
If we look at it from the perspective of [Astronomical Waste][#waste], then the absence of benefits, even when there is no existing person being deprived, is still bad. Proponents of this view look at the universe and are disappointed by all the matter that *isn't* used for making people happy (or making happy people). It follows then, if the absence of pleasure causes a harm, then *Lossa* is clearly worse than Defaultia! After all, Lossa almost included a super-pie and super-happy customer, but then didn't after all.
If we look at it from the perspective of [Astronomical Waste](#waste), then the absence of benefits, even when there is no existing person being deprived, is still bad. Proponents of this view look at the universe and are disappointed by all the matter that *isn't* used for making people happy (or making happy people). It follows then, if the absence of pleasure causes a harm, then *Lossa* is clearly worse than Defaultia! After all, Lossa almost included a super-pie and super-happy customer, but then didn't after all.
In a third approach, we could ask Hardcore Consequentialist Robot 9000 what it thinks about these worlds. It would correctly reason that the pie makers initial choice of ingredients was truly random and that the resulting pie was already determined before picking anything. The pie maker will always end up using the intended ingredient and the same pie will be made. Thus, the state of the world is always the same, and as paths to a state don't matter to HCR 9000, all worlds are exactly equal in value. (This scenario is particularly frustrating for HCR 9000's evil archenemy Doctor Deontology. Paths matter, he says, but only random chance was involved this time, so he still has to choose. But how?)

View file

@ -0,0 +1,14 @@
class MarkdownLinkCheck < Nanoc::Filter
identifier :markdown_link_check
def run(content, params={})
content.each_line do |line|
if line =~ /\[.+?\]\[.*?\]/
puts "#{@item.identifier} -> #{line}"
raise "Unresolved link!"
end
end
end
end