Re: [O] Marking/highlighting text temporarily

2015-05-03 Thread Eric Abrahamsen
Rasmus  writes:

> Hi,
>
> Eric Abrahamsen  writes:
>
>> We're just talking about annotations-plus-metadata here, right? Not
>> actual in-text TODOs?
>
> I don't know.
>
>> From what I can tell, rasmus seems to be proposing an in-text TODO,
>
> I mainly extrapolated from your example.  Further, I extrapolated from the
> notion of org-inlinetasks.el.  Since we have one we should try to minimize
> the distance whilst still keeping syntax as simple as possible,
> e.g. [comment:] or [TODO-TAG:] (I don't know what the "@" operator meant
> in your previous example).
>
>> I've definitely wanted some sort of a track changes equivalent in Org,
>> but we'd want to be careful about this.
>
> Isn't this the job of VC?  I'm not sure how we can concisely represent all
> the needed metadata?  Something like
>
>  [comment: txt :annotation annot :author a :date d :other-properties p]
>
> is not "accessible" for non-Emacs users of the Org format.
>
>> 1. Annotations attached to arbitrary text in the buffer. The buffer text
>>should be visible, the annotation data invisible (basically the way
>>links work right now).
>
> This is a fortification/overlay issue.  And I disagree strongly on having
> invisible parts.
>
>> 2. Plain annotation: just a chunk of free-form paragraph text that is
>>attached to the buffer text.
>
> What do you concretely have in mind here?  Can't this be done with an
> inlinetask at the beginning of the file?  Or a noexport heading?
>
>> 3. Replacement text: an alternate version of the buffer text; this could
>>be the basis of track changes stuff.
>
> Is this not the job of VC?
>
>> 4. Timestamps
>
> This seems like the job of e.g. vc-annotate.el, no?
>
>> 7. "Author" metadata would probably be unnecessary with full access to
>>the export channels, but it might still be desirable.
>
> What John was talking about was for collaboration.  When you export John's
> notes on your machine how can it know it's from John if not set
> explicitly?  In any case, I think it could be too verbose.  Sidenote: In
> collaborated papers I simply use prefix "R:" and "K:" in inlinetasks.
>
>> That's all I can think of, just trying to get the ball rolling. I don't
>> have any opinions about actual syntax, though something with curly
>> braces might be nice.
>
> Nothing with curly braces is nice :)
>
> I think I have something much less ambitious in mind, as I'm perfectly
> happy with only spanning a subset of org-inlinetasks.el.  Disregarding
> date and generalizing replacement text to "annotation", which could be set
> to "replace" with a keyword, you could perhaps have something like one of
> these:
>
>
> [comment/Property:annotation; text]
> [comment/TODO-TAG@author: annotation; text]
> [comment/Property: annotation]
>
> [TODO-TAG/Property@Author: annotation; text]
> [comment/Property: annotation]
>
> - Of course the / and @ operators are optional.
> - I'm not sure what "Property" would be.
> - Author could also be @work as in your previous example.
> - Perhaps calculating TODO-TAGS on a document basis is a can of worms.
> - I would be happier with having text before annotation, but that makes it
>   weird when you have no text attached (for inline tasks not associated to
>   a piece of text).

Hmm, it looks like we've maybe got too many ideas bouncing around at the
same time. I would love to have "more inline" inlinetodos -- ie,
full-citizen TODOs that are attached to a run of buffer text, not
headlines themselves. Call them in-text todos, maybe. I would also love
to have collaborative editing in Org, and I agree that something based
on VC would be most ideal (word-mode diffs could solve many of the
problems there).

Those two things seem pretty separate, though, and to be honest either
one is way more than I can handle on my own. Tying in-text TODOs into
the whole Agenda process seems like an awful lot of work. Also, I've
never so much as glanced at the VC code. What seems most likely is I'll
first fill out org-annotate and put it in Elpa, and then maybe we can
have a slower conversation about what other directions to go in.
Org-annotate will probably just stay what it is (it's very simple, and
does what it says on the tin), but maybe we'll get a clearer sense of
the various things people want, and it can be superseded at some point.

On the VC side, how hard would it be to make a pseudo VC backend where,
if you have an org file called some_file.org (for example), the backend
looked for files in the same directory called some_file.org.XYZ.patch,
and "applied" those patch files in a visible way to the Org file when
you viewed it? With the whole apply/reject thing built in?

Anyway... small, realistic steps seem like the best approach.

Eric




Re: [O] Display Agenda in Reverse Order

2015-05-03 Thread Kenneth Jacker
  smt> Take a look at
  smt>
  smt>org-agenda-sorting-strategy
  smt>
  smt> It should help you out.

It did ... thanks for the info!

For others who might want to do the same or something similar,
I'll show what I did to change the "sorting order" ...


I changed the value of "org-agenda-sorting-strategy" from this:

   ((agenda habit-down time-up priority-down category-keep)
(todo priority-down category-keep)
(tags priority-down category-keep)
(search category-keep))
   
to this:

   ((agenda habit-down time-up scheduled-down priority-down category-keep)
(todo priority-down category-keep)
(tags priority-down category-keep)
(search category-keep))
   
Inserting "scheduled-down" did "the trick!


Thanks again,

  -Kenneth




Re: [O] org-attach + git annex not working

2015-05-03 Thread John Wiegley
> Erik Hetzner  writes:

> I don’t know if the behavior of vc-git-root has changed, but I don’t see
> anything in the emacs git log for vc/vc-git.el and it seems to have the same
> behavior in 24 & 25.

I hadn't noticed it breaking, but is it possible to make your change a bit
more defensive?  I.e., make sure the string ends in .git if it doesn't
already, rather than always appending .git?

John



Re: [O] Resolving conflicts with ediff and folding

2015-05-03 Thread iemacs
I have the following lisp code can do the trick:

(add-hook 'ediff-quit-hook
  (lambda ()
(cond ((eq major-mode 'org-mode)
   (visible-mode 0)
--
Tian Qiu

On Tue, Apr 28, 2015 at 5:43 PM Sebastien Vauban 
wrote:

> J. David Boyd wrote:
> > "Charles C. Berry"  writes:
> >> On Tue, 21 Apr 2015, Suvayu Ali wrote:
> >>>
> >>> Something that has been bugging me for many years now, everytime
> >>> I resolve conflicts in Org files with ediff, it's a pain.  All the
> >>> buffers keep folding the outlines, hiding the conflicts.  I keep
> >>> going to the buffers manually (which can be somewhat of a pain in
> >>> a text terminal), and unfolding them manually.  But of course the
> >>> PROPERTY drawers, LOGBOOKs, and other DRAWERs are still folded!
> >>>
> >>> And then after I have jumped through hoops, and resolved the
> >>> conflicts, I realise I could have just switched to text-mode before
> >>> invoking ediff!
> >>>
> >>> Is there a way where I don't have to remember to switch the major
> >>> mode before invoking ediff[1]?  Or maybe an ediff experience where
> >>> the buffers are forced to unhide text.  I guess it should be
> >>> possible to just temporarily remove all overlays or invisible
> >>> properties.
> >>>
> >>> Any thoughts, ideas?
> >>
> >> Did you see this thread:
> >> http://lists.gnu.org/archive/html/emacs-orgmode/2013-04/msg00400.html
> >> ??
> >
> > That't what I was going to say.  I added that to my setup long ago,
> > and it has been working fine since then.  I don't ediff all that
> > often, but when I do it certainly helps.
>
> The only (tiny) problem is that the `truncate-lines' and `visible-mode'
> settings stay in the buffer after the Ediff session -- while one would
> love to get back to the original settings of the buffer.c
>
> Best regards,
>   Seb
>
> --
> Sebastien Vauban
>
>