summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorJonas <dr@jones.dk>2013-06-01 14:18:26 +0200
committerJonas <dr@jones.dk>2013-06-01 14:18:26 +0200
commit0deb7d99990c26d02cfe093a7a7fe009e88ebd96 (patch)
tree411e5c13ff4d4d317a7629266e3ecea0d1733240 /bin
parentf8d53f5ffb5e51f9d6e9156d43491ea5c8ac9039 (diff)
Use URIs for some categories, and add new category "non-grocery store".
Diffstat (limited to 'bin')
-rwxr-xr-xbin/rdf2hours14
1 files changed, 8 insertions, 6 deletions
diff --git a/bin/rdf2hours b/bin/rdf2hours
index f40c921..766ab52 100755
--- a/bin/rdf2hours
+++ b/bin/rdf2hours
@@ -34,8 +34,9 @@ use HTML::HTML5::Writer;
# TODO: add override options --theme and (multivalued) --category
my @category = <<LIST =~ m/(\S.*\S)/g;
- restaurant
- groceries
+ <http://schema.org/FoodEstablishment>
+ <http://schema.org/GroceryStore>
+ non-grocery store
attraction
transport
public service
@@ -278,10 +279,11 @@ sub daterangedescribe {
sub categorydescribe {
my $cat = shift;
- $cat =~ s/restaurant/spisesteder/;
- $cat =~ s/groceries/dagligvarer/;
- $cat =~ s/attraction/attraktioner og museer/;
- $cat =~ s/public service/offentlige services/;
+ $cat =~ s!<http://schema.org/FoodEstablishment>!spisesteder!;
+ $cat =~ s!<http://schema.org/GroceryStore>!dagligvarebutikker!;
+ $cat =~ s!non-grocery store!øvrige butikker!;
+ $cat =~ s!attraction!attraktioner og museer!;
+ $cat =~ s!public service!offentlige services!;
return ucfirst($cat);
}