Class: Evertils::Controller::Generate
- Defined in:
- lib/evertils/controllers/generate.rb
Constant Summary
Constants inherited from Base
Base::OK, Base::QUIT, Base::QUIT_SOFT
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
-
#daily ⇒ Object
generate daily notes.
-
#monthly ⇒ Object
generate monthly notes.
-
#morning ⇒ Object
creates the notes required to start the day - priority queue - daily - weekly (if today is Monday and there isn’t a weekly log already) - monthly (if today is the 1st and there isn’t a monthly log already).
-
#mts(arg) ⇒ Object
generate monthly task summary templates.
-
#pq ⇒ Object
generate priority queue notes.
-
#weekly ⇒ Object
generate weekly notes.
Methods inherited from Base
#can_exec?, #exec, #initialize, #post_exec, #pre_exec, #sample
Constructor Details
This class inherits a constructor from Evertils::Controller::Base
Instance Method Details
#daily ⇒ Object
generate daily notes
11 12 13 14 |
# File 'lib/evertils/controllers/generate.rb', line 11 def daily note = Type::Daily.new(@config) note.create if note.should_create? end |
#monthly ⇒ Object
generate monthly notes
24 25 26 27 28 |
# File 'lib/evertils/controllers/generate.rb', line 24 def monthly note = Type::Monthly.new(@config) note.create if note.should_create? note.add_weekly_note_link end |
#morning ⇒ Object
creates the notes required to start the day
- priority queue
- daily
- weekly (if today is Monday and there isn't a weekly log already)
- monthly (if today is the 1st and there isn't a monthly log already)
49 50 51 52 53 54 |
# File 'lib/evertils/controllers/generate.rb', line 49 def morning pq daily weekly monthly end |
#mts(arg) ⇒ Object
generate monthly task summary templates
31 32 33 34 35 36 |
# File 'lib/evertils/controllers/generate.rb', line 31 def mts(arg) Notify.error('Name argument is required', {}) if arg.nil? note = Type::MonthlyTaskSummary.new(@config, arg[1]) note.create if note.should_create? end |
#pq ⇒ Object
generate priority queue notes
39 40 41 42 |
# File 'lib/evertils/controllers/generate.rb', line 39 def pq note = Type::PriorityQueue.new(@config) note.create if note.should_create? end |