#!/usr/bin/perl -w # Strip all comments and whitespaces. # # This is used to verify if entry.rb and spoiler.rb are equivalent. use strict; my $text = ""; while( <> ) { chomp; next if /^\s*$/; next if /^\s*#/; s/\s//g; $text .= $_; } print $text, "\n";