Skip to content
Browse files

fix permalinks

  • Loading branch information...
1 parent e1b5f11 commit 41890aa6528eded49a1fc8e1e2f092f77b8639ab @pepijndevos committed Jun 16, 2011
Showing with 5 additions and 1 deletion.
  1. +5 −1 lib/jekyll/migrators/posterous.rb
View
6 lib/jekyll/migrators/posterous.rb
@@ -52,13 +52,17 @@ def download_image(u)
tags = post.tags.map do |t|
t['name']
end
+
+ perm = URI::parse(post.full_url)
+
# Get the relevant fields as a hash, delete empty fields and convert
# to YAML for the header
data = {
+ 'permalink' => perm.path + "/index.html",
'layout' => 'post',
'title' => post.title.to_s,
'published' => published,
- 'tags' => tags,
+ 'categories' => tags,
}.delete_if { |k,v| v.nil? || v == ''}.to_yaml
content = post.body_html

0 comments on commit 41890aa

Please sign in to comment.
Something went wrong with that request. Please try again.