Re: [O] agenda buffer: bulk remote editing: whats the use for mark vs mark for bulk?

2015-08-31 Thread Eric Abrahamsen
Xebar Saram  writes:

> thx Eric!
>
> this works well for archiving, though i cant see a delete option in
> that dispatcher

No, I don't think delete is one of the options...

> best
>
> z
>
> On Mon, Aug 31, 2015 at 4:01 PM, Eric Abrahamsen
>  wrote:
>
>
> Xebar Saram  writes:
>
> > hi all
> > after reading the agenda buffer section in the manual i still
> cant
> > make sense of the bulk remote editing commands and specifically
> the
> > mark vs mark for bulk.
> > my use case is simple , i want to mark a bunch of entries like
> in
> > dired and execurte del/archive/change state etc
> >
> > using `m` to mark i can see that the entries are marked but cant
> seem
> > to understand how to then delete/archive these marked file.
> > also what is M-m for if i can mark with `m`?
> >
> > thx so much
> > Z
>
> "m" adds a mark to the heading under point, "M-m" toggles the
> mark. So
> multiple "m"s will always leave the heading marked, while multiple
> "M-m"s will toggle back and forth between marked and unmarked. Hit
> "U"
> to unmark all.
>
> Then hit "B" to get a little dispatcher asking you what to do with
> the
> marked headings.
>
> HTH,
> Eric




Re: [O] Not getting replies from the orgmode list to my e-mail address

2015-08-31 Thread Sebastien Vauban
jorge.alfaro-muri...@yale.edu (Jorge A. Alfaro-Murillo) writes:
> Eric Abrahamsen writes:
>> Jorge A. Alfaro-Murillo writes:
>>> 
>>> I do not subscribe with my email to lists, but using 
>>> news.gwene.org in gnus. There must be a way to check for 
>>> duplicates in two different servers, but so few people reply to 
>>> both the personal email address and the email list that I have 
>>> never found the need to look how to set that up. I just delete 
>>> the email and get slightly annoyed. I also have 
>>> gnus-confirm-mail-reply-to-news set to t not to make the 
>>> mistake of replying instead of following-up to news. 
>> 
>> I'm also reading through the Gnus newsreader. Personally I 
>> appreciate getting replies emailed to me directly, because some 
>> of these groups are high traffic and it can be easy to miss 
>> replies to threads.
>
> This is a cool trick for that:
>
> #+BEGIN_SRC emacs-lisp
>   (add-hook 'message-sent-hook 'gnus-score-followup-thread)
> #+END_SRC

(This is OOT, but) is there a way to only do that for newsgroups items
(that is, not for mails)?

Best regards,
  Seb

-- 
Sebastien Vauban




Re: [O] exporting multiple choice questions to Aiken or GIFT formats?

2015-08-31 Thread Eric S Fraga
On Friday, 28 Aug 2015 at 18:46, Marcin Borkowski wrote:

[...]

> I've never heard of these, but I did a similar thing for HTML+JS and
> LaTeX:
>
> https://github.com/mbork/org-edu-html
> https://github.com/mbork/org-edu-latex
>
> My markup was to use lists with checkboxes, and check the correct
> answer(s).

I like this approach.  Thanks.
And also thanks for the link to your EmacsConf2015 talk.  I hope it went
well!

eric
-- 
: Eric S Fraga (0xFFFCF67D), Emacs 25.0.50.2, Org release_8.3.1-176-g45abec



Re: [O] exporting multiple choice questions to Aiken or GIFT formats?

2015-08-31 Thread Marcin Borkowski

On 2015-08-31, at 17:32, Eric S Fraga  wrote:

> On Friday, 28 Aug 2015 at 18:46, Marcin Borkowski wrote:
>
> [...]
>
>> I've never heard of these, but I did a similar thing for HTML+JS and
>> LaTeX:
>>
>> https://github.com/mbork/org-edu-html
>> https://github.com/mbork/org-edu-latex
>>
>> My markup was to use lists with checkboxes, and check the correct
>> answer(s).
>
> I like this approach.  Thanks.

Glad you liked it!

> And also thanks for the link to your EmacsConf2015 talk.  I hope it went
> well!

You're welcome!  I hope people liked it.  One of the good things that
resulted from it was a short discussion, whose conclusion was an idea
to write a series of blog posts explaining one of the Org exporters in
detail.  (Since I know LaTeX fairly well, and I have studied most of the
LaTeX exporter source code, I decided to use it for that.)  The first
entry is almost ready, I'm going to work on the others soon.  (I'm not
yet sure whether it is a good idea to cover most of the code -- after
all, it is quite extensive -- but we'll just see.)

> eric

Best,

-- 
Marcin Borkowski
http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski
Faculty of Mathematics and Computer Science
Adam Mickiewicz University



Re: [O] Worg isn't publishing

2015-08-31 Thread Nicolas Goaziou
Hello,

Robert Klein  writes:


FYI  may be
related.


Regards,

-- 
Nicolas Goaziou



[O] [bug?] cannot open babel window on read-only file

2015-08-31 Thread Rasmus
Hi,

Is it a feature that I cannot open the babel window of a source block X in
file Y.org when Y is read only?  Shouldn't X rather be opened in a read
only window in the correct mode?

Thanks,
Rasmus

-- 
What will be next?




Re: [O] agenda buffer: bulk remote editing: whats the use for mark vs mark for bulk?

2015-08-31 Thread Xebar Saram
thx Eric!

this works well for archiving, though i cant see a delete option in that
dispatcher

best

z

On Mon, Aug 31, 2015 at 4:01 PM, Eric Abrahamsen 
wrote:

> Xebar Saram  writes:
>
> > hi all
> > after reading the agenda buffer section in the manual i still cant
> > make sense of the bulk remote editing commands and specifically the
> > mark vs mark for bulk.
> > my use case is simple , i want to mark a bunch of entries like in
> > dired and execurte del/archive/change state etc
> >
> > using `m` to mark i can see that the entries are marked but cant seem
> > to understand how to then delete/archive these marked file.
> > also what is M-m for if i can mark with `m`?
> >
> > thx so much
> > Z
>
> "m" adds a mark to the heading under point, "M-m" toggles the mark. So
> multiple "m"s will always leave the heading marked, while multiple
> "M-m"s will toggle back and forth between marked and unmarked. Hit "U"
> to unmark all.
>
> Then hit "B" to get a little dispatcher asking you what to do with the
> marked headings.
>
> HTH,
> Eric
>
>
>


Re: [O] in agenda buffer, can i add a note/todo when point is on a specific date?

2015-08-31 Thread Xebar Saram
perfect

thx!

z

On Mon, Aug 31, 2015 at 3:56 PM, Eric Abrahamsen 
wrote:

> Xebar Saram  writes:
>
> > A silly question :)
> >
> > when im in the agenda view (buffer, ie C-c a a) i have the week by
> > day. i can move from day to day with up/down etc. can i somehow issue
> > a "make todo/note" command while point is on a specific day? this is
> > to mimic the classic calendars way of adding an appointment
> >
> > hope this makes any sense :)
> >
> > best
> >
> > Z
>
> Hit "k" while point is on your target date. It will start the capture
> process, and any capture template that has a timestamp in it will get
> the timestamp set to the date under point by default. Give it a shot!
>
> Eric
>
>
>


[O] Preface, user's guide, cataloging key?

2015-08-31 Thread Lawrence Bottorff
I'm currently using :LOGBOOK: at the very top of my org file to make a sort
of daily pre-work tweet. That is, right under my top-level star-1 header.
I'd also like a key or metadata or user's guide up at the top, too. For
example, I have borrowed my Wordpress categories as my main header
sections, but they're rather cryptic [DirLog LostWorlds SciTech TechCiv],
so I'd like to have a small metadata place for explaining them at the top
as well. Sure, I could just list each category out at the second level, and
then have a :PROPERTIES: drawer right under each, but like I say, I'd like
some preliminary metadata about the whole page up at the top -- not unlike
a book with its cataloging metadata, preface, front matter, etc. Does
anyone have a nice, elegant, best practices way of doing this? I guess this
would work:

* ME
  - metadata stuff . . .
  - more stuff
+ nested more stuff

** DirLog

   . . .

but this seems awkward. Any suggestions? In general, I see tons of
technical explanation about org-mode, but its layout and best-practices
seem to still be rather anything goes, Wild West.

LB


Re: [O] Worg isn't publishing

2015-08-31 Thread Robert Klein
Hello,

Nicolas Goaziou  wrote:

> Hello,
> 
> Robert Klein  writes:
> 
> 
> FYI  may be
> related.
> 


Yes, something like that.  What actually happens is, the
org-mode repository clone for worg publications is also used to create
the daily snapshots for download.  So once daily the repository
switches to the master branch and back.  When switching back to maint
there were autoloads created, but the remnants of the master branch not
cleaned.

I added a 'make cleanall' after checking out maint (just as there
already was for checking out the master branch).

When I'm more familiar with the different scripts, cronjobs etc. on the
org-mode server I'll think about using different org-mode clones.

Best regards
Robert






Re: [O] porting guide from old to new beamer export?

2015-08-31 Thread Marko Schütz-Schmuck
Suvayu Ali  writes:

> 
> On Sun, Aug 30, 2015 at 07:02:51PM -0400, Marko Schütz Schmuck wrote:
> > Dear All,
> > 
> > I have again tried (unsuccessfully in the time I was able to spend on
> > this) to switch to a newer version of org (tried ELPA as well as
> > 8.2.4). The obstacle is always the beamer export. I have consulted the
> > documentation online, but by following the instructions there the
> > generated LaTeX does not use the frame environment at all. I did set
> > H:1, but no frames...
> 
> Which documentation did you look at?  The manual is very complete, and
> if you want something more along the lines of a tutorial, see the
> articles listed on this page:
> 
>   http://orgmode.org/worg/exporters/beamer/index.html
> 
> If you have specific questions, please feel free to ask.

Thanks for the link. I had used all of the documentation that are referenced
on that page.

I have uploaded a typical file with slides to http://pastebin.com/L2ss0hXG
and http://pastebin.com/D61eSkDq.

When I publish this to PDF with the new exporter the LaTeX file that is
generated does not use any frames http://pastebin.com/8jN6XeuE

Best regards

Marko

Re: [O] org-collector unable to handle macros

2015-08-31 Thread Mark Edgington
Charles Millar  verizon.net> writes:

> This may be related to the problem or is the same that I reported in 
> April and May and again earlier this month when Bastien's requested 
> details in his August 4th message.

Have you (or anyone else) been able to reproduce the problem given the
example which I provided?  Is this indeed a bug, or am I misunderstanding
something?








Re: [O] porting guide from old to new beamer export?

2015-08-31 Thread Suvayu Ali
On Mon, Aug 31, 2015 at 05:23:52PM +, Marko Schütz-Schmuck wrote:
> 
> Thanks for the link. I had used all of the documentation that are referenced
> on that page.
> 
> I have uploaded a typical file with slides to http://pastebin.com/L2ss0hXG
> and http://pastebin.com/D61eSkDq.
> 
> When I publish this to PDF with the new exporter the LaTeX file that is
> generated does not use any frames http://pastebin.com/8jN6XeuE

I think you are doing one of two things wrong.  Either your
org-latex-classes is incorrectly setup, or you are simply exporting to
latex instead of beamer (C-c C-e l b).  E.g. I get the following as the
first frame:

  \begin{frame}[label={sec:orgheadline1}]{linear search}
   %% stuff
  \end{frame}

My org-latex-classes has an entry like this:

 ("beamer" "\\documentclass[presentation]{beamer}"
  ("\\section{%s}" . "\\section*{%s}")
  ("\\subsection{%s}" . "\\subsection*{%s}")
  ("\\subsubsection{%s}" . "\\subsubsection*{%s}"))

Does yours?

-- 
Suvayu

Open source is the future. It sets us free.



Re: [O] using dates as property?

2015-08-31 Thread Samuel Wales
i always put inactive timestamps in headlines, and sort both the
outline and agenda using them.  for example:

* CONVERSATION [2015-08-31 Mon 14:41] john
* CONVERSATION [2015-09-01 Tue 15:02] rms

or newest first.  they are visible and binary-searchable.
works perfectly for me.



Re: [O] using dates as property?

2015-08-31 Thread Samuel Wales
hi john,

documented for myself only:

(defun alpha-org-timestamp-score ( sg)
  "Return unix minutes as a floating point number.

;;;for 0..1
;;;Beware adding this to a much larger number (around 100); you will
;;;lose resolution.  Multiply first by a number with a lot of
;;;zeroes.  Then add to a number with a lot of zeroes.

Seems to be unix time as 1970 (or a few hours off, possibly
depending on time zone) epoch.

This is for sorting conversations, which have an inactive
timestamp near the beginning of a header, and for all tasks.

===

There is no way to get Org to return the first ts of any type.

/fixme/ request a timestamp-any property.  this gets you the
first timestamp no matter whether it is active and no matter
where it is.

This checks closed first.  So the bug is if there is a ts in the
headline, closed will take precedence if it exists.

Still, this approach works OK; think of the time as always being
the time of closing for a doneish, else first ts.  That is OK.

So not making the request now.

/Does not yet consider active timestamps/."
  ;;
  ;;make sure these work on any other processor or os
  ;;
  ;;(/ (org-time-string-to-seconds "1900-12-31 00:00") 60.0) nan
  ;;(/ (org-time-string-to-seconds "1901-12-31 00:00") 60.0) -35766300.0
  ;;(/ (org-time-string-to-seconds "1934-12-31 00:00") 60.0) -18409980.0
  ;;(/ (org-time-string-to-seconds "1960-12-31 00:00") 60.0) -4734300.0
  ;;(/ (org-time-string-to-seconds "1969-12-31 00:00") 60.0) -1020.0
  ;;(/ (org-time-string-to-seconds "1970-01-01 00:00") 60.0) 420.0
  ;;(/ (org-time-string-to-seconds "1980-01-01 00:00") 60.0) 5259300.0
  ;;(/ (org-time-string-to-seconds "1990-01-01 00:00") 60.0) 10519620.0
  ;;(/ (org-time-string-to-seconds "2010-01-01 00:00") 60.0) 21038820.0
  ;;(/ (org-time-string-to-seconds "2038-01-01 00:00") 60.0) 35765700.0
  ;;(/ (org-time-string-to-seconds "2138-01-01 00:00") 60.0) nan
  ;;if you do seconds instead of minutes, it changes magnitude
  ;;seems ok to multiply by 1e7 or so
  ;;(+ 1.0 (* 10519620.0 1e8)) 10519621.0 :)
  ;;(+ 1.0 (* 10519620.0 1e9)) 1.051962e+16 :(
  ;;(= (+ 1.0 (* 10519620.0 1e9)) (* 10519620.0 1e9)) t :(
  ;;(/ (org-time-string-to-seconds "1990-01-01 00:00") 60.0) 10,519,620.0
  (let ((ts (or
 ;;this fixes either a doc bug or a real bug, not
 ;;sure which
 ;;
 ;;maybe a doc bug.  all timestamps are separate?
 ;;then fixme if there is ever another inactive
 ;;timestamp type, you have to add it here.
 ;;
 ;;if so, likewise fixme you have to add all 3 active
 ;;timestamp types and any future ones.
 (alpha-org-entry-get "CLOSED" sg)
 (alpha-org-entry-get "TIMESTAMP_IA" sg
(aif ts
 (/ (org-time-string-to-seconds it)
60.0)
  0.0)))

On 8/31/15, Samuel Wales  wrote:
> i always put inactive timestamps in headlines, and sort both the
> outline and agenda using them.  for example:
>
> * CONVERSATION [2015-08-31 Mon 14:41] john
> * CONVERSATION [2015-09-01 Tue 15:02] rms
>
> or newest first.  they are visible and binary-searchable.
> works perfectly for me.
>


-- 
The Kafka Pandemic: http://thekafkapandemic.blogspot.com

Ramsay's disease DOES progress.  MANY people have died from it.  And
ANYBODY can get it.

Denmark: free Karina Hansen NOW.



Re: [O] using dates as property?

2015-08-31 Thread Samuel Wales
and here is my get function, likewise documented only for me and
written a long time ago but works well for me:

(defun alpha-org-entry-get (property  sg inherit)
  "Return the value of PROPERTY, whether you are in the outline
or the agenda, by calling `org-entry-get'.

SG \(string given\) is the agenda header string to use \(provided
by user-defined agenda sorting\) or nil.  If it is nil and you
are in the outline, use the current headline directly.  If it is
nil and you are in the agenda, use the current headline by going
to the outline.

INHERIT is the inherit argument for `org-entry-get'.

There are a few questions about Org properties:

  1) What does it mean to get alltags without inheritance or tags
 with inheritance?  I guess org-entry-get was originally
 meant for properties, not tags, so you don't use inherit?
  2) How do you get the first timestamp in an entry?  There seems
 to be no way without specifying the type of timestamp.

According to the manual at the time of this writing, possible
properties include these.

 TODO The TODO keyword of the entry.
 TAGS The tags defined directly in the headline.
 ALLTAGS  All tags, including inherited ones.
 CATEGORY The category of an entry.
 PRIORITY The priority of the entry, a string with a single letter.
 DEADLINE The deadline time string, without the angular brackets.
 SCHEDULEDThe scheduling timestamp, without the angular brackets.
 CLOSED   When was this entry closed?
 TIMESTAMPThe first keyword-less timestamp in the entry.
   - this works even in the headline
 TIMESTAMP_IA The first inactive timestamp in the entry.
   - this works even in the headline
   - it does not seem to report CLOSED ts -- use CLOSED
 CLOCKSUM The sum of CLOCK intervals in the subtree.  org-clock-sum
  must be run first to compute the values.
 ITEM The content of the entry.

For anything else, you can use marker-buffer to get to the
outline and do manual parsing or use some other function.  Or
possibly modify org-entry-get to understand it and send a patch
to the org mailing list, along with an update of this docstring.

The idea is to use this as a single way to get most metadata no
matter where you are.
"
  ;;=doubtful do we want the literal-nil argument so that we can
  ;;ret "nil" as string?  check elsewhere here for nil vs. string
  ;;for todo kw or whatever.  we only need it if it helps with
  ;;consistency.  not important and prob useless for this
  ;;purpose.  (other ways of getting todo kw will not obey it so
  ;;it might not help.)
  ;;
  ;; fixme org-cached-entry-get
  (org-entry-get
   (ecase major-mode
 ((org-agenda-mode)
;;;
;;; will this work faster?  or is this for something other than
;;; agenda?
;;;
;;; my guess is it is just for doing things not getting things
;;;
;;; (org-with-point-at (org-get-at-bol 'org-hd-marker)
;;; ;; do here what you need to do at the location of the entry
;;; )

  ;; sg is provided by programmatic agenda use in sorting.
  ;;
  ;; should also be provided in sorting filter.
  ;;
  ;; is the buffer substring only needed for outline?  could
  ;; we get property from the agenda for sorting to avoid the
  ;; buffer substring?
  ;;
  ;; fixme for speed maybe we can get from the agenda buffer
  ;; if sg is not provided.  fixme check if sg is provided.
  ;; however, if we use
  ;; org-agenda-before-sorting-filter-function, it is
  ;; provided i guess.
  (let* ((s (or sg (buffer-substring (point-at-bol)
 (point-at-eol
 ;; get marker from sg or string
 ;;
 ;; what is the difference between these? supposedly
 ;; hd-marker is not always there.
 (m (or (get-text-property 1 'org-marker s)
(get-text-property 1 'org-hd-marker s
;;do this to get to the org outline buffer from the
;;agenda buffer if you need other data that org-entry-get
;;cannot extract
;;
;;(b (and m (marker-buffer m
;;;(if b
;;;(with-current-buffer b
;;;  (goto-char m)
m))
 ((org-mode) (point)))
   property
   inherit))



[O] gnuplot: plotting students' progress of grades

2015-08-31 Thread Tobias Frischholz
Hi List,

I have a table in org which looks like this (student’s grades):

|---++++++++++++++-|
|   | Schüler| 1-fach | 1-fach | 1-fach | 1-fach | 2-fach | 2-fach | 2-fach 
| 2-fach | 4-fach | 4-fach | 4-fach | 4-fach | Endnote |
|---++++++++++++++-|
| # | Wurm, Hans |  4 |  3 |  2 |  3 |  3 ||  3 
|  1 |  3 ||  3 |  5 |3.18 |
| # | Igel, Sepp |  1 |  2 |  3 |  3 |||
|  3 |  2 ||  3 |  6 |3.28 |
|---++++++++++++++-|
| # | \o |   2.50 |   2.50 |   2.50 |   3.00 |   3.00 |   0.00 |   3.00 
|   2.00 |   2.50 |   0.00 |   3.00 |   5.50 |3.23 |
|---++++++++++++++|

I would like to use gnuplot to show me a line graph of each student’s single 
grades in order to resemble their progress during the school year.
Can this be achieved with it?

Best regards,
Tobias Frischholz

PGP PUBLIC KEY: http://pgp.mit.edu/pks/lookup?search=0xCD463AC1=index



signature.asc
Description: Message signed with OpenPGP using GPGMail


Re: [O] org-collector unable to handle macros

2015-08-31 Thread Nicolas Goaziou
Hello,

Mark Edgington  writes:

> Charles Millar  verizon.net> writes:
>
>> This may be related to the problem or is the same that I reported in 
>> April and May and again earlier this month when Bastien's requested 
>> details in his August 4th message.
>
> Have you (or anyone else) been able to reproduce the problem given the
> example which I provided?  Is this indeed a bug, or am I misunderstanding
> something?

  :INCLASS:  ABC {{{c(stuff)}}} DEF

looks incorrect. Macros are not expanded in node properties (with an
exception for :EXPORT_SOMETHING: when #+SOMETHING is parsed).


Regards,

-- 
Nicolas Goaziou



Re: [O] org-collector unable to handle macros

2015-08-31 Thread Mark Edgington
On Aug 31, 2015 6:43 PM, "Nicolas Goaziou"  wrote:
>
> Hello,
>
> Mark Edgington  writes:
>
> > Charles Millar  verizon.net> writes:
> >
> >> This may be related to the problem or is the same that I reported in
> >> April and May and again earlier this month when Bastien's requested
> >> details in his August 4th message.
> >
> > Have you (or anyone else) been able to reproduce the problem given the
> > example which I provided?  Is this indeed a bug, or am I
misunderstanding
> > something?
>
>   :INCLASS:  ABC {{{c(stuff)}}} DEF
>
> looks incorrect. Macros are not expanded in node properties (with an
> exception for :EXPORT_SOMETHING: when #+SOMETHING is parsed).

It is not intended to be expanded when generating the table, but the table
should have the macro in it, so that it gets expanded when the table is
exported.


Re: [O] [bug?] cannot open babel window on read-only file

2015-08-31 Thread Nicolas Goaziou
Hello,

Rasmus  writes:

> Is it a feature that I cannot open the babel window of a source block X in
> file Y.org when Y is read only?

"Opening the babel window" is called remote editing. There is no editing
in a read-only buffer. Behaviour is correct, IMO.

> Shouldn't X rather be opened in a read only window in the correct
> mode?

That is a possibility, but there's some work involved in "org-src.el".


Regards,

-- 
Nicolas Goaziou



Re: [O] org-collector unable to handle macros

2015-08-31 Thread Nicolas Goaziou
Mark Edgington  writes:

> On Aug 31, 2015 6:43 PM, "Nicolas Goaziou"  wrote:
>>
>> Hello,
>>
>> Mark Edgington  writes:
>>
>> > Charles Millar  verizon.net> writes:
>> >
>> >> This may be related to the problem or is the same that I reported in
>> >> April and May and again earlier this month when Bastien's requested
>> >> details in his August 4th message.
>> >
>> > Have you (or anyone else) been able to reproduce the problem given the
>> > example which I provided?  Is this indeed a bug, or am I
> misunderstanding
>> > something?
>>
>>   :INCLASS:  ABC {{{c(stuff)}}} DEF
>>
>> looks incorrect. Macros are not expanded in node properties (with an
>> exception for :EXPORT_SOMETHING: when #+SOMETHING is parsed).
>
> It is not intended to be expanded when generating the table, but the table
> should have the macro in it, so that it gets expanded when the table is
> exported.

OK. Then another problem:

  :ID: sched_table

ID properties are meant to be set with `org-id'. What about using
CUSTOM_ID instead?


Regards,



Re: [O] org-collector unable to handle macros

2015-08-31 Thread Mark Edgington
> >>
> >>   :INCLASS:  ABC {{{c(stuff)}}} DEF
> >>
> >> looks incorrect. Macros are not expanded in node properties (with an
> >> exception for :EXPORT_SOMETHING: when #+SOMETHING is parsed).
> >
> > It is not intended to be expanded when generating the table, but the
table
> > should have the macro in it, so that it gets expanded when the table is
> > exported.
>
> OK. Then another problem:
>
>   :ID: sched_table
>
> ID properties are meant to be set with `org-id'. What about using
> CUSTOM_ID instead?

When using CUSTOM_ID, I get the following message (and the table generation
fails):

condition-case: (error Cannot find entry with :ID: sched_table)

Is this not the case for you?  I have enabled org-collector via M-x
customize-variable  org-modules.


Re: [O] porting guide from old to new beamer export?

2015-08-31 Thread Marko Schütz-Schmuck
Suvayu Ali  writes:

> 
> On Mon, Aug 31, 2015 at 05:23:52PM +, Marko Schütz-Schmuck wrote:
> > 
> > Thanks for the link. I had used all of the documentation that are referenced
> > on that page.
> > 
> > I have uploaded a typical file with slides to http://pastebin.com/L2ss0hXG
> > and http://pastebin.com/D61eSkDq.
> > 
> > When I publish this to PDF with the new exporter the LaTeX file that is
> > generated does not use any frames http://pastebin.com/8jN6XeuE
> 
> I think you are doing one of two things wrong.  Either your
> org-latex-classes is incorrectly setup, or you are simply exporting to
> latex instead of beamer (C-c C-e l b).  E.g. I get the following as the
> first frame:

Thanks, that helps a lot!

I did not have an option to export to beamer. I wasn't aware that I had to
require ox-beamer explicitly.

Now I notice that the new exporter makes frame titles like this

\begin{frame}[label=sec-8]{proving \hoareTriple{V}\{\(\textmath{merge}\)\}\{P\}}

where the old one generated this

\begin{frame}
\frametitle{proving \hoareTriple{V}{\(\textmath{merge}\)}{P}}
\label{sec-8}

The new exporter escaped some { and } that should not be escaped.

Would you also have a hint to solve that?

Thanks,

Marko

>   \begin{frame}[label={sec:orgheadline1}]{linear search}
>%% stuff
>   \end{frame}
> 
> My org-latex-classes has an entry like this:
> 
>  ("beamer" "\\documentclass[presentation]{beamer}"
>   ("\\section{%s}" . "\\section*{%s}")
>   ("\\subsection{%s}" . "\\subsection*{%s}")
>   ("\\subsubsection{%s}" . "\\subsubsection*{%s}"))
> 
> Does yours?
> 




Re: [O] Need help with HTML export custom postamble

2015-08-31 Thread David A. Gershman
So I finally was able to test out the C-c C-c.  It did ask me if I
wanted to apply and I said yes.  When I exported the file, my postamble
(as specified in the variable) was /not/ shown...it was still the default.

Strangely, when I did C-c C-c, Emacs came back with this:

> The local variables list in syllabus.org
> contains values that may not be safe (*).
> Do you want to apply it?  You can type
> y  -- to apply the local variables list.
> n  -- to ignore the local varialbes list.
> !  --  to apply.
>
>* org-html-postamble : t
>* org-export-hml-postamble-format : "Hello World"
Notice the *'*'* warning not to be safe.  But the source .org file is
with '#' as it should be (seen further below).

Thoughts?


On 08/26/2015 11:19 PM, Thomas S. Dye wrote:
>> Finally, I tried "Local variables"?  Never did this before but attempted
>> it and put:
>>
>>> # Local Variables:
>>> # org-html-postamble: t
>>> # org-export-html-postamble-format: "Hello World"
>>> # End:
>> in my .org file and still no luck.
> After you add this to the .org file, you need to refresh the setup.  I
> do this by moving cursor to the top of the file (with all of the #+
> lines) and pressing C-c C-c.  You should get a message asking if it is
> OK to set local variables.  Pressing y should set org-html-postamble and
> org-export-html-postamble-format for that buffer.
>
> hth,
> Tom
>



Re: [O] Need help with HTML export custom postamble

2015-08-31 Thread Thomas S . Dye
Aloha David,

David A. Gershman  writes:

> So I finally was able to test out the C-c C-c.  It did ask me if I
> wanted to apply and I said yes.  When I exported the file, my postamble
> (as specified in the variable) was /not/ shown...it was still the default.
>
> Strangely, when I did C-c C-c, Emacs came back with this:
>
>> The local variables list in syllabus.org
>> contains values that may not be safe (*).
>> Do you want to apply it?  You can type
>> y  -- to apply the local variables list.
>> n  -- to ignore the local varialbes list.
>> !  --  to apply.
>>
>>* org-html-postamble : t
>>* org-export-hml-postamble-format : "Hello World"
> Notice the *'*'* warning not to be safe.  But the source .org file is
> with '#' as it should be (seen further below).
>
> Thoughts?

Yes, Emacs asks about safe local variables.  I read about this once in
the Emacs manual and concluded that my use cases were all safe, so I
just type "y".  I suspect you're in the same boat, but you might want to
read the relevant section of the Emacs manual to be certain.

I just noticed that you're setting org-export-hml-postamble-format, but
you probably want html instead of hml.

hth,
Tom

-- 
Thomas S. Dye
http://www.tsdye.com



Re: [O] Need help with HTML export custom postamble

2015-08-31 Thread David A. Gershman


On 08/31/2015 05:38 PM, Thomas S. Dye wrote:
> Aloha David,
>
> David A. Gershman  writes:
>
>> So I finally was able to test out the C-c C-c.  It did ask me if I
>> wanted to apply and I said yes.  When I exported the file, my postamble
>> (as specified in the variable) was /not/ shown...it was still the default.
>>
>> Strangely, when I did C-c C-c, Emacs came back with this:
>>
>>> The local variables list in syllabus.org
>>> contains values that may not be safe (*).
>>> Do you want to apply it?  You can type
>>> y  -- to apply the local variables list.
>>> n  -- to ignore the local varialbes list.
>>> !  --  to apply.
>>>
>>>* org-html-postamble : t
>>>* org-export-hml-postamble-format : "Hello World"
>> Notice the *'*'* warning not to be safe.  But the source .org file is
>> with '#' as it should be (seen further below).
>>
>> Thoughts?
> Yes, Emacs asks about safe local variables.  I read about this once in
> the Emacs manual and concluded that my use cases were all safe, so I
> just type "y".  I suspect you're in the same boat, but you might want to
> read the relevant section of the Emacs manual to be certain.
I, too, typed 'y' with no luck; and yeah, my use cases are safe as well.
>
> I just noticed that you're setting org-export-hml-postamble-format, but
> you probably want html instead of hml.
>
> hth,
> Tom
>
Sorry, that must have been a typo when transposing it into email (Emacs
didn't let me highlight to copy the text while the question was in the
buffer).   The actual .org file /is/ 'html'.

So by typing 'y', I'd expect to see "Hello World" in my
postamble...correct?  My seeing the default is still an error then.

Just to make sure all is understood, here is the entire .org file
(content shortened):

> # Last Updated: "2015-08-31 17:44:42"
> #+OPTIONS: html-link-use-abs-url:nil
> #+OPTIONS: html-preamble:t html-scripts:nil html-style:t
> #+OPTIONS: html5-fancy:nil toc:nil num:nil
> #+HTML_DOCTYPE: xhtml-strict
> #+HTML_CONTAINER: div
> #+HTML_HEAD:
> #+HTML_HEAD_EXTRA:
> #+AUTHOR: D. Gershman
> #+CREATOR: http://www.gnu.org/software/emacs/;>Emacs
> 24.4.1 (http://orgmode.org;>Org mode 8.3.1)
> #+TITLE: CS 380 Syllabus
> #+LANGUAGE: en
>
>
> * David A. Gershman, CISSP
>   Office hours here
>
> * Course Description
>   Network architectures and standards. Layers and protocols. Circuit
>   switching, packet switching and routing. Client-server
>   concepts. Network security. Web computing. Privacy, intellectual
>   property rights and acceptable use. 4
>   lectures/problem-solving. Prerequisites: CS 241 and CS 264 with
>   grades of C or better, or consent of instructor.   
>
>
> # Local Variables:
> # org-html-postamble: t
> # org-export-html-postamble-format: "Hello World"
> # End:
Either typing C-c C-c, or just opening the file will ask me about the
variables.  I answer 'y', but still get the default postamble.

Thanks.



[O] [PATCH] org-mime: make plain/text mime export a choice

2015-08-31 Thread Jon Miller
Update to how org-mime constructs emails for the plain/text section of the
mime email. I've found that using the 'ascii exporter produces a saner
plain/text section than using the 'org exporter. Added a new custom variable
to control which exporter is used. and changed the default behavior to use
'ascii. Below is my git formatted patch.

-- 
Jon Miller


>From 7dca81cc20b81ac36b7580efa756b66e7f8b1705 Mon Sep 17 00:00:00 2001
From: Jon Miller 
Date: Mon, 31 Aug 2015 17:32:53 -0700
Subject: [PATCH] org-mime: make plain/text mime export a choice

* org-mime (org-mime-htmlize, org-mime-compose): Introduce a new
  customize variable `org-mime-plain-text-export-format' to control how
  the plain/text portion of the mime formatted email is exported.
  Defaults to 'ascii over previous hard coded 'org choice.

The 'ascii export does a better job in formatting your email in the
plain/text portion of the mime encoded message than to org
format.  Making this configurable and changing the default to ascii.

TINYCHANGE
---
 contrib/lisp/org-mime.el | 10 --
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/contrib/lisp/org-mime.el b/contrib/lisp/org-mime.el
index 197c712..10a56eb 100644
--- a/contrib/lisp/org-mime.el
+++ b/contrib/lisp/org-mime.el
@@ -70,6 +70,12 @@
   :group 'org-mime
   :type 'string)
 
+(defcustom org-mime-plain-text-export-format 'ascii
+  "Which format to export to when filling the text/plain mime
+  section"
+  :group 'org-mime
+  :type '(choice 'org 'ascii))
+
 (defcustom org-mime-library 'mml
   "Library to use for marking up MIME elements."
   :group 'org-mime
@@ -214,7 +220,7 @@ export that region, otherwise export the entire body."
   (buffer-substring html-start html-end)))
  (tmp-file (make-temp-name (expand-file-name
"mail" temporary-file-directory)))
- (body (org-export-string-as raw-body 'org t))
+ (body (org-export-string-as raw-body 
org-mime-plain-text-export-format t))
  ;; because we probably don't want to export a huge style file
  (org-export-htmlize-output-type 'inline-css)
  ;; makes the replies with ">"s look nicer
@@ -324,7 +330,7 @@ export that region, otherwise export the entire body."
 (org-export-string-as
  (org-babel-trim
   (funcall bhook body (if (eq fmt 'html) 'org 'ascii)))
- (if (eq fmt 'html) 'org 'ascii) t)
+ org-mime-plain-text-export-format t)
 html)
(mapconcat 'identity images "\n")))
 
-- 
2.4.3



[O] students, classes, assignments...

2015-08-31 Thread scrawler
Hey guys,

What's an efficient way to keep track of students, classes, and assignments?
I'm using org now, but I don't want to admit how badly I'm abusing it to make 
my *cough* system work.

How about something like this: a file per student with Classwork, Homework, and 
Assessment headings, maybe checkboxes to indicate completion; A date-tree in a 
file with the Homework and due dates--something along those lines.

Any ideas would be appreciated. I know a bunch of you are teachers...


-- 
signature drinking: "glugluglug"
:-)



Re: [O] Need help with HTML export custom postamble

2015-08-31 Thread Thomas S . Dye

David A. Gershman  writes:

>> # Local Variables:
>> # org-html-postamble: t
>> # org-export-html-postamble-format: "Hello World"
>> # End:
> Either typing C-c C-c, or just opening the file will ask me about the
> variables.  I answer 'y', but still get the default postamble.

Are you using an old Org mode, pre 8.0?  I believe that's when the old
org-export-* variables lost the "export" part.

At any rate, the problem appears to be that org-html-postamble-format
(in Org mode > 8.0) is an association list, not a string.

This works for me using a recent Org mode:

# Local Variables:
# org-html-postamble: t
# eval: (add-to-list 'org-html-postamble-format (quote ("en" "Hello World")))
# End:

At least, I get the cons cell added to the association list, and the
change is local to the buffer.  I didn't try the export part.

hth,
Tom

-- 
Thomas S. Dye
http://www.tsdye.com



Re: [O] Need help with HTML export custom postamble [SOLVED]

2015-08-31 Thread David A. Gershman
*argh*  I remember that variation of postamble in my readings...didn't
think to try it.  Thank you!!!

I attempted the export as well and it worked as expected.  I appreciate
your patience!

FWIW, yes, I'm on the latest Org (8.3.1) and Emacs 24.4.1 (Debian Jessie).

On 08/31/2015 06:36 PM, Thomas S. Dye wrote:
> David A. Gershman  writes:
>
>>> # Local Variables:
>>> # org-html-postamble: t
>>> # org-export-html-postamble-format: "Hello World"
>>> # End:
>> Either typing C-c C-c, or just opening the file will ask me about the
>> variables.  I answer 'y', but still get the default postamble.
> Are you using an old Org mode, pre 8.0?  I believe that's when the old
> org-export-* variables lost the "export" part.
>
> At any rate, the problem appears to be that org-html-postamble-format
> (in Org mode > 8.0) is an association list, not a string.
>
> This works for me using a recent Org mode:
>
> # Local Variables:
> # org-html-postamble: t
> # eval: (add-to-list 'org-html-postamble-format (quote ("en" "Hello World")))
> # End:
>
> At least, I get the cons cell added to the association list, and the
> change is local to the buffer.  I didn't try the export part.
>
> hth,
> Tom
>




Re: [O] porting guide from old to new beamer export?

2015-08-31 Thread Loris Bennett
Joseph Vidal-Rosset  writes:

> Is it possible to get something like the CambridgeUS colortheme via
> the org-export of beamer? I do not succeed to do it, it is always the
> same theme.
>
> Best wishes
>
> Jo. 

#+BEAMER_THEME: CambridgeUS

If that doesn't work, you should post a minimal working example which
illustrates the problem.

Cheers,

Loris

-- 
This signature is currently under construction.




Re: [O] porting guide from old to new beamer export?

2015-08-31 Thread Joseph Vidal-Rosset
Is it possible to get something like the CambridgeUS colortheme via the
org-export of beamer? I do not succeed to do it, it is always the same
theme.

Best wishes

Jo.

2015-08-31 2:03 GMT+02:00 Suvayu Ali :

> On Sun, Aug 30, 2015 at 07:02:51PM -0400, Marko Schütz Schmuck wrote:
> > Dear All,
> >
> > I have again tried (unsuccessfully in the time I was able to spend on
> > this) to switch to a newer version of org (tried ELPA as well as
> > 8.2.4). The obstacle is always the beamer export. I have consulted the
> > documentation online, but by following the instructions there the
> > generated LaTeX does not use the frame environment at all. I did set
> > H:1, but no frames...
>
> Which documentation did you look at?  The manual is very complete, and
> if you want something more along the lines of a tutorial, see the
> articles listed on this page:
>
>   http://orgmode.org/worg/exporters/beamer/index.html
>
> If you have specific questions, please feel free to ask.
>
> Hope this helps,
>
> --
> Suvayu
>
> Open source is the future. It sets us free.
>
>


[O] Exporting an org-file to multiple html pages

2015-08-31 Thread Jarmo Hurri

Greetings.

I am writing a relatively extensive document in org, and I am currently
trying to figure out how to split the exported html into multiple html
pages.

Is publishing along the lines of this tutorial still the best way to do
it?

http://orgmode.org/worg/org-tutorials/org-publish-html-tutorial.html

In other words, do I need to split one org file into multiple org files
and then build the links between them manually? That is, is there no way
to automatically have top level "chapters" split into pages with links
between chapters?

Thanks!

Jarmo




Re: [O] Exporting an org-file to multiple html pages

2015-08-31 Thread Marcin Borkowski

On 2015-08-31, at 12:16, Jarmo Hurri  wrote:

> Greetings.
>
> I am writing a relatively extensive document in org, and I am currently
> trying to figure out how to split the exported html into multiple html
> pages.
>
> Is publishing along the lines of this tutorial still the best way to do
> it?
>
> http://orgmode.org/worg/org-tutorials/org-publish-html-tutorial.html
>
> In other words, do I need to split one org file into multiple org files
> and then build the links between them manually? That is, is there no way
> to automatically have top level "chapters" split into pages with links
> between chapters?

Does this help?

https://github.com/mbork/org-one-to-many

Its purpose is to split an Org file into many pieces (either giving
a level, or marking the headlines to be split with a :split: tag),
modifying internal links so that they still point to the same places
(even though in different files).  Then you can export these files
individually to HTML.

I think splitting the Org file is a better idea than splitting the
produced HTML file: it seems both easier and maybe more versatile (you
are not restricted to HTML then).

Notice that if you have some configs (like #+OPTIONS etc.), it might be
a good idea to move them to a separate heading marked with :config: and
:noexport: tags.

The entry point is the =org-one-to-many= function.

It currently lacks proper documentation, but see its docstring for some
help.  Also, feel free to ask me.

Currently, the .el file lacks a proper header, too - I'll add it later
(maybe even today).

> Thanks!
>
> Jarmo

Hth,

-- 
Marcin Borkowski
http://octd.wmi.amu.edu.pl/en/Marcin_Borkowski
Faculty of Mathematics and Computer Science
Adam Mickiewicz University



[O] using dates as property?

2015-08-31 Thread John Kitchin
Hi,

I am making a historical list of seminar speakers in an org-file. I am
trying to figure out the best way to store the dates so I can do
something later like find speakers from 2010, or to sort the speakers by
date etc...

Here is an example of my current thoughts. My questions are:

1. are org-timestamps the right approach?
2. are they better in the headline (where they are more easily read) or
as a property?
3. In either case, is there an easy way to search/sort them?

**  Some Person
   :PROPERTIES:
   :FIRSTNAME: Some
   :LASTNAME: Person
   :EMAIL:some.per...@someplace.edu
   :URL:  http://some.place.edu/some-person
   :END:
*** [2010-02-02 Tue] Title
:PROPERTIES:
:DATE: [2010-02-02 Tue]
:END:
*** [2015-09-01 Tue] Title...
:PROPERTIES:
:DATE: [2015-09-01 Tue]
:END:

Thanks!

--
Professor John Kitchin
Doherty Hall A207F
Department of Chemical Engineering
Carnegie Mellon University
Pittsburgh, PA 15213
412-268-7803
@johnkitchin
http://kitchingroup.cheme.cmu.edu



Re: [O] porting guide from old to new beamer export?

2015-08-31 Thread Suvayu Ali
On Mon, Aug 31, 2015 at 10:32:35AM +0200, Loris Bennett wrote:
> Joseph Vidal-Rosset  writes:
> 
> > Is it possible to get something like the CambridgeUS colortheme via
> > the org-export of beamer? I do not succeed to do it, it is always the
> > same theme.
> >
> > Best wishes
> >
> > Jo. 
> 
> #+BEAMER_THEME: CambridgeUS
> 
> If that doesn't work, you should post a minimal working example which
> illustrates the problem.

Most of the standard stuff is quite extensively documented.  E.g. see
these:

- Manual: (info "(org) Beamer specific export settings")
  
http://orgmode.org/manual/Beamer-specific-export-settings.html#Beamer-specific-export-settings
- Worg: http://orgmode.org/worg/exporters/beamer/ox-beamer.html#config

Cheers,

-- 
Suvayu

Open source is the future. It sets us free.



Re: [O] [bug] org-cycle changed behavior in orgstruct-mode

2015-08-31 Thread Rasmus
Hi,

>> But are the slowdowns associated with outline.el functions anything that
>> will realistically be felt in normal usage?
>
> They are noticeable under certain circumstances. I implemented
> `org-show-children' because `show-children' was /reported/ as slow.

OK.

> Generally speaking, outline doesn't cope well with dense sub-trees. As
> an example, consider `org-forward-heading-same-level'. Using outline, we
> need to move to next headline, check its level, compare with original,
> rinse and repeat, possibly many times, until we find a match. However,
> we could simply do
>
>   (re-search-forward some-appropriate-regexp nil t)
>
> and be done with it since we can turn level into a regexp.

Indeed.  That seems like a better implementation in any case.

>> IMO the biggest advantage of orgstruct is that it has more sensible
>> keybindings than outline.  Of course it's also nice with lists and tables
>> (assuming they are not in orgstruct++; don't remember)...
>
> Table is orgtbl-mode, not orgstruct-mode. 
>
> List handling is a real concern however, because we cannot use the
> parser (there is no context to know about) but still have to analyze
> lists.

In an ideal world it should also "ignore" comment-start in the sense that
I it should help me with lists after, e.g. ";;".  I wonder if any of
Thorsten's packages on this already solved this issue.

>> Adding advice to orgstruct, which is a mess anyway, won't make it any
>> worse than it is...
>
> Agreed.

OK, so I'll experiment with an "old advice" around orgstruct.

BTW: We have 20 defadvice in lisp/.  That seems like enough reason (to me)
to bump Org 9 to 24.4.

Rasmus

-- 
And when I’m finished thinking, I have to die a lot




[O] [PATCH 2/3] org-datetree.el: Add support for ISO week trees.

2015-08-31 Thread Rüdiger Sonderfeld
* lisp/org-datetree.el (org-datetree-find-iso-date-create): New function.
(org-datetree--find-create): Support fixed text for insert.
(org-datetree-insert-line): Support fixed text for insert.
* testing/lisp/test-org-datetree.el (test-org-datetree/find-iso-date-create):
New test.

ISO week trees order dates by week and not by month.
---
 lisp/org-datetree.el  | 64 ++-
 testing/lisp/test-org-datetree.el | 92 +++
 2 files changed, 145 insertions(+), 11 deletions(-)

diff --git a/lisp/org-datetree.el b/lisp/org-datetree.el
index 3620bbd..a5a542e 100644
--- a/lisp/org-datetree.el
+++ b/lisp/org-datetree.el
@@ -74,8 +74,48 @@ (defun org-datetree-find-date-create (date  
keep-restriction)
   (org-datetree--find-create "^\\*+[ \t]+%d-%02d-\\([0123][0-9]\\) \\w+$"
 year month day
 
-(defun org-datetree--find-create (regex year  month day)
-  "Find the datetree matched by REGEX for YEAR, MONTH, or DAY."
+;;;###autoload
+(defun org-datetree-find-iso-week-create (date  keep-restriction)
+  "Find or create an ISO week entry for DATE.
+Compared to `org-datetree-find-date-create' this function creates
+entries ordered by week instead of months.
+If KEEP-RESTRICTION is non-nil, do not widen the buffer.  When it
+is nil, the buffer will be widened to make sure an existing date
+tree can be found."
+  (org-set-local 'org-datetree-base-level 1)
+  (or keep-restriction (widen))
+  (save-restriction
+(let ((prop (org-find-property "DATE_WEEK_TREE")))
+  (when prop
+   (goto-char prop)
+   (org-set-local 'org-datetree-base-level
+  (org-get-valid-level (org-current-level) 1))
+   (org-narrow-to-subtree)))
+(goto-char (point-min))
+(require 'cal-iso)
+(let* ((year (calendar-extract-year date))
+  (month (calendar-extract-month date))
+  (day (calendar-extract-day date))
+  (time (encode-time 0 0 0 day month year))
+  (iso-date (calendar-iso-from-absolute
+ (calendar-absolute-from-gregorian date)))
+  (weekyear (nth 2 iso-date))
+  (week (car iso-date))
+  (weekday (cadr iso-date)))
+  ;; ISO 8601 week format is %G-W%V(-%u)
+  (org-datetree--find-create "^\\*+[ 
\t]+\\([12][0-9]\\{3\\}\\)\\(\\s-*?\\([ \t]:[[:alnum:]:_@#%%]+:\\)?\\s-*$\\)"
+weekyear nil nil
+(format-time-string "%G" time))
+  (org-datetree--find-create "^\\*+[ \t]+%d-W\\([0-5][0-9]\\)$"
+weekyear week nil
+(format-time-string "%G-W%V" time))
+  ;; For the actual day we use the regular date instead of ISO week.
+  (org-datetree--find-create "^\\*+[ \t]+%d-%02d-\\([0123][0-9]\\) \\w+$"
+year month day
+
+(defun org-datetree--find-create (regex year  month day insert)
+  "Find the datetree matched by REGEX for YEAR, MONTH, or DAY.
+If INSERT is non-nil insert the text if not found."
   (let ((re (format regex year month day))
match)
 (goto-char (point-min))
@@ -86,25 +126,27 @@ (defun org-datetree--find-create (regex year  
month day)
  ((not match)
   (goto-char (point-max))
   (unless (bolp) (newline))
-  (org-datetree-insert-line year month day))
+  (org-datetree-insert-line year month day insert))
  ((= (string-to-number (match-string 1)) (or day month year))
   (goto-char (point-at-bol)))
  (t
   (beginning-of-line 1)
-  (org-datetree-insert-line year month day)
+  (org-datetree-insert-line year month day insert)
 
-(defun org-datetree-insert-line (year  month day)
+(defun org-datetree-insert-line (year  month day text)
   (delete-region (save-excursion (skip-chars-backward " \t\n") (point)) 
(point))
   (insert "\n" (make-string org-datetree-base-level ?*) " \n")
   (backward-char)
   (when month (org-do-demote))
   (when day (org-do-demote))
-  (insert (format "%d" year))
-  (when month
-(insert
- (if day
-(format-time-string "-%m-%d %A" (encode-time 0 0 0 day month year))
-   (format-time-string "-%m %B" (encode-time 0 0 0 1 month year)
+  (if text
+  (insert text)
+(insert (format "%d" year))
+(when month
+  (insert
+   (if day
+  (format-time-string "-%m-%d %A" (encode-time 0 0 0 day month year))
+(format-time-string "-%m %B" (encode-time 0 0 0 1 month year))
   (when (and day org-datetree-add-timestamp)
 (save-excursion
   (insert "\n")
diff --git a/testing/lisp/test-org-datetree.el 
b/testing/lisp/test-org-datetree.el
index 0135ab9..9b839ca 100644
--- a/testing/lisp/test-org-datetree.el
+++ b/testing/lisp/test-org-datetree.el
@@ -113,5 +113,97 @@ (ert-deftest test-org-datetree/find-date-create ()
(org-datetree-find-date-create '(3 29 2012)))
   (buffer-substring (point) 

[O] [PATCH 1/3] org-datetree.el: Code cleanup.

2015-08-31 Thread Rüdiger Sonderfeld
* lisp/org-datetree.el (org-datetree--find-create): New function.
(org-datetree-find-year-create, org-datetree-find-month-create,
org-datetree-find-day-create): Removed functions
(org-datetree-find-date-create): Use `org-datetree--find-create' instead
of removed functions.  Use calendar extract functions.
(org-datetree-insert-line): Do more formatting in `format-time-string'
since we call it anyway
* testing/lisp/test-org-datetree.el (test-org-datetree/find-date-create):
  Test if new entries are put at the right place.
---
 lisp/org-datetree.el  | 77 +--
 testing/lisp/test-org-datetree.el |  9 +
 2 files changed, 27 insertions(+), 59 deletions(-)

diff --git a/lisp/org-datetree.el b/lisp/org-datetree.el
index a97a9d0..3620bbd 100644
--- a/lisp/org-datetree.el
+++ b/lisp/org-datetree.el
@@ -64,67 +64,30 @@ (defun org-datetree-find-date-create (date  
keep-restriction)
   (org-get-valid-level (org-current-level) 1))
(org-narrow-to-subtree)))
 (goto-char (point-min))
-(let ((year (nth 2 date))
- (month (car date))
- (day (nth 1 date)))
-  (org-datetree-find-year-create year)
-  (org-datetree-find-month-create year month)
-  (org-datetree-find-day-create year month day
-
-(defun org-datetree-find-year-create (year)
-  "Find the YEAR datetree or create it."
-  (let ((re "^\\*+[ \t]+\\([12][0-9]\\{3\\}\\)\\(\\s-*?\\([ 
\t]:[[:alnum:]:_@#%]+:\\)?\\s-*$\\)")
+(let ((year (calendar-extract-year date))
+ (month (calendar-extract-month date))
+ (day (calendar-extract-day date)))
+  (org-datetree--find-create "^\\*+[ 
\t]+\\([12][0-9]\\{3\\}\\)\\(\\s-*?\\([ \t]:[[:alnum:]:_@#%%]+:\\)?\\s-*$\\)"
+year)
+  (org-datetree--find-create "^\\*+[ \t]+%d-\\([01][0-9]\\) \\w+$"
+year month)
+  (org-datetree--find-create "^\\*+[ \t]+%d-%02d-\\([0123][0-9]\\) \\w+$"
+year month day
+
+(defun org-datetree--find-create (regex year  month day)
+  "Find the datetree matched by REGEX for YEAR, MONTH, or DAY."
+  (let ((re (format regex year month day))
match)
 (goto-char (point-min))
 (while (and (setq match (re-search-forward re nil t))
(goto-char (match-beginning 1))
-   (< (string-to-number (match-string 1)) year)))
+   (< (string-to-number (match-string 1)) (or day month year
 (cond
  ((not match)
   (goto-char (point-max))
-  (or (bolp) (newline))
-  (org-datetree-insert-line year))
- ((= (string-to-number (match-string 1)) year)
-  (goto-char (point-at-bol)))
- (t
-  (beginning-of-line 1)
-  (org-datetree-insert-line year)
-
-(defun org-datetree-find-month-create (year month)
-  "Find the datetree for YEAR and MONTH or create it."
-  (org-narrow-to-subtree)
-  (let ((re (format "^\\*+[ \t]+%d-\\([01][0-9]\\) \\w+$" year))
-   match)
-(goto-char (point-min))
-(while (and (setq match (re-search-forward re nil t))
-   (goto-char (match-beginning 1))
-   (< (string-to-number (match-string 1)) month)))
-(cond
- ((not match)
-  (goto-char (point-max))
-  (or (bolp) (newline))
-  (org-datetree-insert-line year month))
- ((= (string-to-number (match-string 1)) month)
-  (goto-char (point-at-bol)))
- (t
-  (beginning-of-line 1)
-  (org-datetree-insert-line year month)
-
-(defun org-datetree-find-day-create (year month day)
-  "Find the datetree for YEAR, MONTH and DAY or create it."
-  (org-narrow-to-subtree)
-  (let ((re (format "^\\*+[ \t]+%d-%02d-\\([0123][0-9]\\) \\w+$" year month))
-   match)
-(goto-char (point-min))
-(while (and (setq match (re-search-forward re nil t))
-   (goto-char (match-beginning 1))
-   (< (string-to-number (match-string 1)) day)))
-(cond
- ((not match)
-  (goto-char (point-max))
-  (or (bolp) (newline))
+  (unless (bolp) (newline))
   (org-datetree-insert-line year month day))
- ((= (string-to-number (match-string 1)) day)
+ ((= (string-to-number (match-string 1)) (or day month year))
   (goto-char (point-at-bol)))
  (t
   (beginning-of-line 1)
@@ -139,13 +102,9 @@ (defun org-datetree-insert-line (year  month day)
   (insert (format "%d" year))
   (when month
 (insert
- (format "-%02d" month)
  (if day
-(format "-%02d %s"
-day
-(format-time-string "%A" (encode-time 0 0 0 day month year)))
-   (format " %s"
-  (format-time-string "%B" (encode-time 0 0 0 1 month year))
+(format-time-string "-%m-%d %A" (encode-time 0 0 0 day month year))
+   (format-time-string "-%m %B" (encode-time 0 0 0 1 month year)
   (when (and day org-datetree-add-timestamp)
 (save-excursion
   (insert "\n")
diff --git 

[O] can't assign to hline relative reference

2015-08-31 Thread Luke Swart
Hello,

There seems to be an error when using hline-relative references in an
org-mode table’s formula. For example, I have the following org-mode table:

#+BEGIN: columnview :hlines 1 :id global
| /Project/  | Mon | Tue | Wed |  Thu | Fri |  Sat | Sun | /Total/ |
|+-+-+-+--+-+--+-+-|
| AnotherProduct | | | |  | | 2.50 | | |
| Prototype  | | | | 3.50 | |  | | |
|+-+-+-+--+-+--+-+-|
| /Daily/| | | |  | |  | | |
#+TBLFM: @I$9..@II$9=vsum($2..$8);%.2f;::@II$2..@III$9='(format
"%3.2f" (apply '+ '(@I..@II)));N;

and I get the error can't assign to hline relative reference when I run M-x
org-table-recalculate. I looked over the org-mode references documentation
 and the gmane.org forums
, but I did not find
any reasons as to why the hline relative references could not be assigned.

This issue is related to the timesheet package on MELPA. I have filed an
issue here: https://github.com/tmarble/timesheet.el/issues/3 but hopefully
I have found the underlying problem, and hopefully it is reasonably fixable.

Here is some relevant info:

   -

   Org-mode version 8.3.1 (8.3.1-87-g4ef2c0-elpa @
   /home/luke/.emacs.d/elpa/org-20150824/)
   -

   emacs-version: 24.5.1
   -

   ArchLinux OS: Linux 4.1.6-1-ARCH #1 SMP PREEMPT Mon Aug 17 08:52:28 CEST
   2015 x86_64 GNU/Linux

This is a copy of my question posted here:
http://emacs.stackexchange.com/questions/15185/cant-assign-to-hline-relative-reference

Any suggestions or guidance would be appreciated. I am happy to clarify
anything as well.

Thanks,
Luke
​


[O] [PATCH 0/3] Add ISO week trees.

2015-08-31 Thread Rüdiger Sonderfeld
This series of patches adds support for ISO week trees to org-datetree
and org-capture.  Unlike regular date trees the tree is ordered by
week instead of month.

For example:

* 2015
** 2015-W35
*** 2015-08-30 Sunday
 Foo
 Bar
** 2015-W36
*** 2015-08-31 Monday
 Fou
*** 2015-09-01 Tuesday
 Baz

I find this more useful to order my work log than a month based tree.

Rüdiger Sonderfeld (3):
  org-datetree.el: Code cleanup.
  org-datetree.el: Add support for ISO week trees.
  org-capture.el: Add support for week trees.

 doc/org.texi  |   7 +++
 lisp/org-capture.el   |  26 ++--
 lisp/org-datetree.el  | 129 +++---
 testing/lisp/test-org-datetree.el | 101 +
 4 files changed, 194 insertions(+), 69 deletions(-)

-- 
2.5.1




[O] [PATCH 3/3] org-capture.el: Add support for week trees.

2015-08-31 Thread Rüdiger Sonderfeld
* lisp/org-capture.el (org-capture-templates): Add
  file+weektree(+prompt) options.
  (org-capture-set-target-location): Add support for week trees.
* doc/org.texi (Template elements): Document file+weektree(+prompt)
  options.
---
 doc/org.texi|  7 +++
 lisp/org-capture.el | 26 +-
 2 files changed, 28 insertions(+), 5 deletions(-)

diff --git a/doc/org.texi b/doc/org.texi
index ed808be..d894f91 100644
--- a/doc/org.texi
+++ b/doc/org.texi
@@ -7187,6 +7187,13 @@
 @item (file+datetree+prompt "path/to/file")
 Will create a heading in a date tree, but will prompt for the date.
 
+@item (file+weektree "path/to/file")
+Will create a heading in a week tree for today's date.  Week trees are sorted
+by week and not by month unlike datetrees.
+
+@item (file+weektree+prompt "path/to/file")
+Will create a heading in a week tree, but will prompt for the date.
+
 @item (file+function "path/to/file" function-finding-location)
 A function to find the right location in the file.
 
diff --git a/lisp/org-capture.el b/lisp/org-capture.el
index 93a7f2a..320954e 100644
--- a/lisp/org-capture.el
+++ b/lisp/org-capture.el
@@ -149,6 +149,12 @@ (defcustom org-capture-templates nil
  (file+datetree+prompt \"path/to/file\")
  Will create a heading in a date tree, prompts for date
 
+ (file+weektree \"path/to/file\")
+ Will create a heading in a week tree for today's date
+
+ (file+weektree+prompt \"path/to/file\")
+ Will create a heading in a week tree, prompts for date
+
  (file+function \"path/to/file\" function-finding-location)
  A function to find the right location in the file
 
@@ -321,6 +327,12 @@ (defcustom org-capture-templates nil
  (list :tag "File & Date tree, prompt for date"
(const :format "" file+datetree+prompt)
(file :tag "  File"))
+ (list :tag "File & Week tree"
+   (const :format "" file+weektree)
+   (file :tag "  File"))
+ (list :tag "File & Week tree, prompt for date"
+   (const :format "" file+weektree+prompt)
+   (file :tag "  File"))
  (list :tag "File & function"
(const :format "" file+function)
(file :tag "  File")
@@ -895,21 +907,25 @@ (defun org-capture-set-target-location ( target)
  (setq target-entry-p (and (derived-mode-p 'org-mode) 
(org-at-heading-p
  (error "No match for target regexp in file %s" (nth 1 target
 
-   ((memq (car target) '(file+datetree file+datetree+prompt))
+   ((memq (car target) '(file+datetree file+datetree+prompt file+weektree 
file+weektree+prompt))
(require 'org-datetree)
(set-buffer (org-capture-target-buffer (nth 1 target)))
(org-capture-put-target-region-and-position)
(widen)
-   ;; Make a date tree entry, with the current date (or yesterday,
-   ;; if we are extending dates for a couple of hours)
-   (org-datetree-find-date-create
+   ;; Make a date/week tree entry, with the current date (or
+   ;; yesterday, if we are extending dates for a couple of hours)
+   (funcall
+(cond
+ ((memq (car target) '(file+weektree file+weektree+prompt))
+  #'org-datetree-find-iso-week-create)
+ (t #'org-datetree-find-date-create))
 (calendar-gregorian-from-absolute
  (cond
   (org-overriding-default-time
;; use the overriding default time
(time-to-days org-overriding-default-time))
 
-  ((eq (car target) 'file+datetree+prompt)
+  ((memq (car target) '(file+datetree+prompt file+weektree+prompt))
;; prompt for date
(let ((prompt-time (org-read-date
nil t nil "Date for tree entry:"
-- 
2.5.1




Re: [O] in agenda buffer, can i add a note/todo when point is on a specific date?

2015-08-31 Thread Eric Abrahamsen
Xebar Saram  writes:

> A silly question :)
>
> when im in the agenda view (buffer, ie C-c a a) i have the week by
> day. i can move from day to day with up/down etc. can i somehow issue
> a "make todo/note" command while point is on a specific day? this is
> to mimic the classic calendars way of adding an appointment
>
> hope this makes any sense :)
>
> best
>
> Z 

Hit "k" while point is on your target date. It will start the capture
process, and any capture template that has a timestamp in it will get
the timestamp set to the date under point by default. Give it a shot!

Eric




Re: [O] Worg isn't publishing

2015-08-31 Thread Robert Klein
Hi,

Sebastien Vauban  wrote:

> Robert Klein  writes:
> > Thomas S. Dye  wrote:
> >> Robert Klein  writes:
> >>> Kyle Meyer  wrote:
>  Thomas S. Dye  writes:
>  >
>  > Worg hasn't published for several days.
>  >
>  > All the best,
>  > Tom
>  
>  I pushed to Worg last night and noticed that it did not update.
>  I recorded the message below but hadn't got around to emailing
>  the list.
> >>>
> >>> I saw two updates on worg from yesterday, so probably everything
> >>> is Ok again.
> >> 
> >> I'm not seeing my changes to
> >> http://orgmode.org/worg/org-contrib/babel/languages.html
> >
> > I fixed the build.  Your changes now show up.
> 
> Could you tell us what had to be fixed, so that we can lear as well?
> Thanks!

Basically I ran the following five commands on the org-mode server:

cd ~emacs/git/org-mode
sudo -u emacs make clean
sudo -u emacs make

cd ~worg/worg.git/hooks/
sudo -u worg ./post-update


However, I saw the invalid function 41 again, so I still have to dig
deeper.  I know one script that causes this already.  Probably I can
tell more later, today.


Best regards
Robert


> 
> Best regards,
>   Seb
> 




Re: [O] Worg isn't publishing

2015-08-31 Thread Sebastien Vauban
Robert Klein  writes:
> Thomas S. Dye  wrote:
>> Robert Klein  writes:
>>> Kyle Meyer  wrote:
 Thomas S. Dye  writes:
 >
 > Worg hasn't published for several days.
 >
 > All the best,
 > Tom
 
 I pushed to Worg last night and noticed that it did not update.  I
 recorded the message below but hadn't got around to emailing the
 list.
>>>
>>> I saw two updates on worg from yesterday, so probably everything is
>>> Ok again.
>> 
>> I'm not seeing my changes to
>> http://orgmode.org/worg/org-contrib/babel/languages.html
>
> I fixed the build.  Your changes now show up.

Could you tell us what had to be fixed, so that we can lear as well?
Thanks!

Best regards,
  Seb

-- 
Sebastien Vauban




[O] agenda buffer: bulk remote editing: whats the use for mark vs mark for bulk?

2015-08-31 Thread Xebar Saram
hi all
after reading the agenda buffer section in the manual i still cant make
sense of the bulk remote editing commands and specifically the mark vs mark
for bulk.
my use case is simple , i want to mark a bunch of entries like in dired and
execurte del/archive/change state etc

using `m` to mark i can see that the entries are marked but cant seem to
understand how to then delete/archive these marked file.
also what is M-m for if i can mark with `m`?

thx so much

Z


[O] in agenda buffer, can i add a note/todo when point is on a specific date?

2015-08-31 Thread Xebar Saram
A silly question :)

when im in the agenda view (buffer, ie C-c a a) i have the week by day. i
can move from day to day with up/down etc. can i somehow issue a "make
todo/note" command while point is on a specific day? this is to mimic the
classic calendars way of adding an appointment

hope this makes any sense :)

best

Z


Re: [O] agenda buffer: bulk remote editing: whats the use for mark vs mark for bulk?

2015-08-31 Thread Eric Abrahamsen
Xebar Saram  writes:

> hi all
> after reading the agenda buffer section in the manual i still cant
> make sense of the bulk remote editing commands and specifically the
> mark vs mark for bulk.
> my use case is simple , i want to mark a bunch of entries like in
> dired and execurte del/archive/change state etc
>
> using `m` to mark i can see that the entries are marked but cant seem
> to understand how to then delete/archive these marked file.
> also what is M-m for if i can mark with `m`?
>
> thx so much
> Z

"m" adds a mark to the heading under point, "M-m" toggles the mark. So
multiple "m"s will always leave the heading marked, while multiple
"M-m"s will toggle back and forth between marked and unmarked. Hit "U"
to unmark all.

Then hit "B" to get a little dispatcher asking you what to do with the
marked headings.

HTH,
Eric