lib/amiba/page.rb in amiba-0.0.2 vs lib/amiba/page.rb in amiba-0.0.3

- old
+ new

@@ -1,6 +1,7 @@ require 'amiba/source' +require 'etc' module Amiba module Page # Thor task to create a new page. It checks for the existance of a page already existing @@ -15,9 +16,10 @@ class_option :layout, :default =>"default" class_option :title, :required => true class_option :description, :required => true class_option :category, :default => "plain" class_option :state, :default => "draft" + class_option :author, :default => Etc.getpwnam(ENV["USER"])["gecos"].split(",")[0] def init_source @source = Amiba::Source::Page.new(name, format, options, Templates.send(format.to_sym)) end