Re: [O] Header/preface definitions in ox-taskjuggler?

2014-11-04 Thread John Hendy
On Sun, Nov 2, 2014 at 4:09 PM, John Hendy  wrote:
> Edit: sorry about the premature send. Bad accidental tab + enter from
> gmail! Here's the intended email:
> ===
>
> I note that the defaults for a taskjuggler export in Org are as
> follows, with taskjuggler syntax and related org variable definitions
> listed.

[snip]

> In any case, this is the one that's goofing me up. The first task gets
> the following lines prepended to it:
>
> task task1 "task1" {
>   purge allocate
>   allocate 
> ...
> }
>

This is defined in org.git/contrib/ox-taskjuggler.el:

#+begin_src

  ;; If no resource is allocated among tasks, allocate one to
  ;; the first task.
  (unless (org-element-map main-tasks 'headline
(lambda (task) (org-element-property :ALLOCATE task))
info t)
(org-element-put-property
 (car main-tasks) :ALLOCATE
 (or (org-taskjuggler-get-id (car main-resources) info)
 (user-login-name
  (mapconcat
   (lambda (task) (org-taskjuggler--build-task task info))
   main-tasks ""))

#+end_src

Any reason we need to force an allocated resource to the first task?
>From my experience, taskjuggler fails in the following scenarios:
- You use the =effort= attribute and don't assign a resource (effort
is based on available manpower and thus requires a defined resource
with some set availability/output defined)
- You assign a resource but *don't* use =effort= or =length=, which
are allocation-using vs. =duration=, which is not.

In my case, I tend *not* to use =effort= since I'm simply planning out
processes for myself and thus just use =duration=. I've had to create
a dummy first headline to get the allocation so that my actual task
tree doesn't fail due to not using =effort=/=length=. Either that or I
have to edit the generated .tjp file and remove the lines:

#+begin_src
purge allocate
allocate username
#+end_src

Could this be updated to check for both no resources *and* the use of
=effort= to specify a task attribute? If it doesn't have both, there's
no effect in the output of allocating a resource.


Best regards,
John


> If one doesn't use the effort attribute (but duration or length
> instead), you get a warning regarding resources having been requested
> but none being assigned (because effort is the only time-related
> attribute that calls for a person to translate effort into calendar
> length). Is there a reason ox-taskjuggler defaults to
> creating/assigning resources?
>
>
> John



Re: [O] Header/preface definitions in ox-taskjuggler?

2014-11-02 Thread John Hendy
Edit: sorry about the premature send. Bad accidental tab + enter from
gmail! Here's the intended email:
===

I note that the defaults for a taskjuggler export in Org are as
follows, with taskjuggler syntax and related org variable definitions
listed.

Project tj syntax: project []  []  [{
 }]

Org defaults:
- id: nil
- name: name of heading tagged with org-taskjuggler-project-tag
- version: org-taskjugler-default-project-version
- interval2: SCHEDULED:  + org-default-project-duration

For some reason the default global properties are defined as:

shift s40 "Part time shift" {
  workinghours wed, thu, fri off
}

I'm interpreting this to mean W-F are "off days"? If that's the
correct interpretation per the syntax, I don't understand why this
would be the default definition. Then again, perhaps it's just a
definition and you have to apply it to a task to use it?
- http://www.taskjuggler.org/tj3/manual/workinghours.shift.html

In any case, this is the one that's goofing me up. The first task gets
the following lines prepended to it:

task task1 "task1" {
  purge allocate
  allocate 
...
}

If one doesn't use the effort attribute (but duration or length
instead), you get a warning regarding resources having been requested
but none being assigned (because effort is the only time-related
attribute that calls for a person to translate effort into calendar
length). Is there a reason ox-taskjuggler defaults to
creating/assigning resources?


John



[O] Header/preface definitions in ox-taskjuggler?

2014-11-02 Thread John Hendy
I note that the defaults for a taskjuggler export in Org are as
follows, with taskjuggler syntax and related org variable definitions
listed.

Project tj syntax: project []  []  [{
 }]

Org defaults:
- id: nil
- name: name of heading tagged with org-taskjuggler-project-tag
- version: org-taskjugler-default-project-version
- interval2: SCHEDULED:  + org-default-project-duration

For some reason the default global properties are defined as:

shift s40 "Part time shift" {
  workinghours wed, thu, fri off
}

I'm interpreting this to mean W-F are "off days"? If that's the
correct interpretation per the syntax, I don't understand why this
would be the default definition. Then again, perhaps it's just a
definition and you have to apply it to a task to use it?
- http://www.taskjuggler.org/tj3/manual/workinghours.shift.html

In any case, this is the one that's goofing me up. The first task gets
the following lines prepended to it:

task task1 "task1" {
  purge allocate