Re: [O] Automatic mtime and ctime on all or select group of trees?

2017-09-06 Thread Adam Porter
Jorge Morais Neto  writes:

> Thank you for the tip.  But instead of adding precisely what you
> suggested, I have added “:group 'org-expiry”.  The warning is gone and
> the option does show up when I invoke customize-group and type
> “org-expiry”.  I have run some other minimal tests and it seems to be
> working.

Muito bem feito!  :)




Re: [O] org-agenda-current-time-string partly fontified with emphasis

2017-09-06 Thread Samuel Wales
On 9/6/17, Samuel Wales  wrote:
> in the new release, org-agenda-current-time-string is partly fontified
> if it contains emphasis like "=== test ===".  my guess is best to not
> fontify as it is not possible to
> fix unless you turn it off for the entire buffer.

the above is correct, but the cause is possibly related to the fact
that there is an emphasis change from 9.0.

before, "===" in the outline would not be fontified.  now it is.

can this be turned off?  i use "===" specifically in the outline and
would prefer it in a default font, while preserving =this emphasis=.



[O] attachments in html export

2017-09-06 Thread kevinbanjo
is there an easy way to auto-generate a link to the attachments when
exporting org html?


Re: [O] [PATCH] org-agenda: Add 'none setting for org-agenda-overriding-header

2017-09-06 Thread Adam Porter
By the way, one of its features is that, when a test doesn't pass, it
shows a line-by-line diff of the agenda buffer compared with the saved
result.  It's saved me a lot of time when debugging test failures, as
otherwise I'd have to visually compare a large agenda buffer.  :)




Re: [O] How to use the list search?

2017-09-06 Thread Adam Porter
Nick Dokos  writes:

> Ah, Gmane, Gmane - wherefore art thou, Gmane?

Indeed.  In the meantime, this might also be useful, as it has a decent
UI.  I haven't tested its searching extensively, but it seems to give
more useful results than the lists.gnu.org server. 

https://www.mail-archive.com/emacs-orgmode@gnu.org/




Re: [O] [PATCH] org-agenda: Add 'none setting for org-agenda-overriding-header

2017-09-06 Thread Adam Porter
Nicolas Goaziou  writes:

> If you feel like it, some tests in "test-org-agenda.el" would be nice,
> too.

Hi Nicolas,

I looked at that file and I see that it's pretty basic.  I recently put
together a sort of testing framework for org-super-agenda that makes it
pretty easy to develop and run consistent tests on agendas:

https://github.com/alphapapa/org-super-agenda/blob/master/test/test.el

Would you be interested in a patch that adds something like that to Org?
It would make it easy to test specific agenda features, and I guess it
might help with your agenda rewrite.  :)




Re: [O] Table (used a "spreadsheet") org-sbe issues when the value is a string

2017-09-06 Thread Alex Bennée

Nicolas Goaziou  writes:

> Hello,
>
> Alex Bennée  writes:
>
>> So calling scramble-string works as expected...
>>
>> #+tblname: reversed-strings
>> | abcde   | #ERROR |
>>
>> | flibble | #ERROR |
>> | dibble  | #ERROR |
>> | xyzzy   | #ERROR |
>> | another | #ERROR |
>>
>> #+TBLFM: $2='(org-sbe scramble-string (str $$1))
>
> I cannot reproduce it. I get:

Hmm it turns out this interferes:

;; See 
http://emacs.stackexchange.com/questions/499/finding-and-executing-org-babel-snippets-programatically
(defun my-babel-hashed-confirm (lang body)
  "Check against known hashes before prompting for confirmation.
See `org-confirm-babel-evaluate'."
  (let ((check (list lang (md5 body
;; If not hashed, prompt
(if (not (member check my-org-babel-hashes))
;; Ask if you want to hash
(if (yes-or-no-p "Store hash for block? ")
;; Hash is added, proceed with evaluation
(progn
  (add-to-list 'my-org-babel-hashes check)
  'nil)
  ;; Return 't to prompt for evaluation
  't)
  (message "Valid hash auto-confirmed")
  'nil)))

(setq org-confirm-babel-evaluate 'my-babel-hashed-confirm)

Resetting to org-confirm-babel-evaluate to nil and it works.

>
> #+name: reversed-strings
> | abcde   | edcba   |
> | flibble | elbbilf |
> | dibble  | elbbid  |
> | xyzzy   | yzzyx   |
> | another | rehtona |
> #+TBLFM: $2='(org-sbe scramble-string (str $$1))
>
>> Even calling org-sbe directly from a source block:
>>
>> #+name: call-scramble-string-via-sbe
>> #+begin_src emacs-lisp :var val="thing"
>>
>> (org-sbe scramble-string (str val))
>> #+end_src
>
> AFAIK, `org-sbe' is limited to tables.

I was trying to replicate the way TBLFM compiles the macro.

>
> Regards,


--
Alex Bennée



[O] org-agenda-current-time-string partly fontified with emphasis

2017-09-06 Thread Samuel Wales
in the new release, org-agenda-current-time-string is partly fontified
if it contains emphasis like "=== test ===".  my guess is best to not
fontify as it is not possible to
fix unless you turn it off for the entire buffer.

-- 
The Kafka Pandemic: 

The disease DOES progress. MANY people have died from it. And ANYBODY
can get it at any time.

"You’ve really gotta quit this and get moving, because this is murder
by neglect." ---
.



Re: [O] Release 9.1

2017-09-06 Thread Samuel Wales
Congratulations and thanks

-- 
The Kafka Pandemic: 

The disease DOES progress. MANY people have died from it. And ANYBODY
can get it at any time.

"You’ve really gotta quit this and get moving, because this is murder
by neglect." ---
.



Re: [O] setting local variables

2017-09-06 Thread Eric Abrahamsen
Nicolas Goaziou  writes:

> Eric Abrahamsen  writes:
>
>> I think I ran into trouble just doing a simple `org-store-link' from an
>> Info file, then `org-insert-link' in the Org mode manual.
>>
>> That produced:
>>
>> [[info:org#Installation][info:org#Installation]] -->
>> @ref{Installation,@ref{Installation,,,org,},,org,} -->
>> *note *note (org)Installation::: (org)Installation.
>
> This bug was fixed months ago, when we removed support for nested links.

Bah, sorry. I'm on org-plus-contrib.

>> Why not just change the behavior of `org-export-headline-levels' for
>> texinfo output? We can already make plain lists, it doesn't seem useful
>> to me to also turn minor headings into lists. Since texinfo has the
>> concept of pages, why not just inline headings below H: level?
>
> We can certainly do that, but that doesn't solve the real problem. Such
> headings could be generated at any level. Conversely, you may want to
> have a deeper level in some section, so H:4 would be mandatory.
>
> Maybe UNNUMBERED property could imply a "not in TOC" clause in every
> back-end (I assume this is difficult to implement for LaTeX, though). In
> that case, UNNUMBERED would be a generic answer the problem.
>
> Or UNNUMBERED could imply "not in TOC" in "ox-texinfo.el", but that's
> less good, IMO.

Right, the headline-levels approach is not very graceful. I like
using UNNUMBERED, that seems conceptually correct.

>>> IMO, advanced marking is not needed, at least out of the box. For
>>> example, @kbd{M-@key{TAB}} in Texinfo is morally equivalent to
>>> ~M-~ in Org, as long as the document targets info.
>>
>> Morally equivalent in that they're typeset the same, right?
>
> Correct.
>
>> I decided to embrace texinfo pedantry and make a kbd macro :)
>
> I think it really matters if you're going to use the Texinfo file to
> produce other formats than "info" (e.g., you're writing a GNU manual).
> If that's only for the "info" part, ~M-~ is infinitely more
> readable.

I don't think anything needs to be done here, it's just a matter of what
authors want.

>> I'd be happy to provide a patch, and I think we should mention
>> `org-texinfo-text-markup-alist', as well. Then we can say "here's how
>> Org's basic markup elements are translated, here's a defcustom you can
>> play with, and failing that you can also make a macro".
>
> Sounds good.
>
>> To be honest I don't know how the markup alist is supposed to work,
>> though. If I mark up a phrase /like so/, shouldn't that count as
>> "italic", and get transformed into @emph{like so}?
>
> It should, and it does.
>
>> Right now it goes through unchanged into the Info file, which doesn't
>> seem right, since the Texinfo manual seems to indicate that _this_ is
>> the proper way to do emphasis.
>
> I cannot reproduce the problem.

I'll assume it's something version related, or local.

>> The other thing I'd like to expand is the "Plain lists in Texinfo
>> export" section. First of all, it's about definition lists, not plain
>> lists, which I found confusing. Also, I think it just needs to have more
>> basic information in it, unless you already know texinfo well, it's hard
>> to know what it's telling you.
>
> Agreed.

Great, I'll do this in the next couple of days.

Thanks,
Eric




Re: [O] Release 9.1

2017-09-06 Thread Eduardo Mercovich

Hello Bastien.


Org-mode 9.1 is out!
http://orgmode.org/Changes.html


Congratulations and thanks a lot to you and everyone involved in 
Orgmode, for such marvelous work. :)



--
eduardo mercovich

Donde se cruzan tus talentos 
con las necesidades del mundo, 
ahí está tu vocación. 
(Anónimo)




Re: [O] setting local variables

2017-09-06 Thread Nicolas Goaziou
Eric Abrahamsen  writes:

> I think I ran into trouble just doing a simple `org-store-link' from an
> Info file, then `org-insert-link' in the Org mode manual.
>
> That produced:
>
> [[info:org#Installation][info:org#Installation]] -->
> @ref{Installation,@ref{Installation,,,org,},,org,} -->
> *note *note (org)Installation::: (org)Installation.

This bug was fixed months ago, when we removed support for nested links.

> Why not just change the behavior of `org-export-headline-levels' for
> texinfo output? We can already make plain lists, it doesn't seem useful
> to me to also turn minor headings into lists. Since texinfo has the
> concept of pages, why not just inline headings below H: level?

We can certainly do that, but that doesn't solve the real problem. Such
headings could be generated at any level. Conversely, you may want to
have a deeper level in some section, so H:4 would be mandatory.

Maybe UNNUMBERED property could imply a "not in TOC" clause in every
back-end (I assume this is difficult to implement for LaTeX, though). In
that case, UNNUMBERED would be a generic answer the problem.

Or UNNUMBERED could imply "not in TOC" in "ox-texinfo.el", but that's
less good, IMO.

>> IMO, advanced marking is not needed, at least out of the box. For
>> example, @kbd{M-@key{TAB}} in Texinfo is morally equivalent to
>> ~M-~ in Org, as long as the document targets info.
>
> Morally equivalent in that they're typeset the same, right?

Correct.

> I decided to embrace texinfo pedantry and make a kbd macro :)

I think it really matters if you're going to use the Texinfo file to
produce other formats than "info" (e.g., you're writing a GNU manual).
If that's only for the "info" part, ~M-~ is infinitely more
readable.

> I'd be happy to provide a patch, and I think we should mention
> `org-texinfo-text-markup-alist', as well. Then we can say "here's how
> Org's basic markup elements are translated, here's a defcustom you can
> play with, and failing that you can also make a macro".

Sounds good.

> To be honest I don't know how the markup alist is supposed to work,
> though. If I mark up a phrase /like so/, shouldn't that count as
> "italic", and get transformed into @emph{like so}?

It should, and it does.

> Right now it goes through unchanged into the Info file, which doesn't
> seem right, since the Texinfo manual seems to indicate that _this_ is
> the proper way to do emphasis.

I cannot reproduce the problem.

> The other thing I'd like to expand is the "Plain lists in Texinfo
> export" section. First of all, it's about definition lists, not plain
> lists, which I found confusing. Also, I think it just needs to have more
> basic information in it, unless you already know texinfo well, it's hard
> to know what it's telling you.

Agreed.

Regards,



Re: [O] setting local variables

2017-09-06 Thread Eric Abrahamsen
Nicolas Goaziou  writes:

> Rasmus  writes:
>
>> I could not get it to work.  I tried stuff like "[[(org) Tables]]",
>> "[[*(org) Tables]]" and , [[texinfo:(org) tables]].
>
> You are talking about a special case for cross-referencing (which could
> include internal reference, URL referencess). This is the job of
> "org-info.el":
>
>   [[info:org#tables]]

I think I ran into trouble just doing a simple `org-store-link' from an
Info file, then `org-insert-link' in the Org mode manual.

That produced:

[[info:org#Installation][info:org#Installation]] -->
@ref{Installation,@ref{Installation,,,org,},,org,} -->
*note *note (org)Installation::: (org)Installation.

Of course, I should have edited the description part of the link:

[[info:org#Installation][Installation]] -->
@ref{Installation,Installation,,org,} -->
*note Installation(org).

Much better.

I did once manage to produce a link that didn't follow to its
destination, I think just using org-store|insert-link, but of course now
can't reproduce.

Anyway, I don't know if the above is actually a bug or not.

[...]

>> That is why I asked for a reference as I do not remember having seen such
>> a layout in an info page.  If we know of an example, it might not be hard
>> to implement.
>
> The problem is not implementing it, really. It is about finding a way to
> integrate it with Org syntax.
>
> "org.texi" uses a lot of "@subheading" and related. See for example
>
>   (info "(org) Installation")
>
> "Using Emacs packaging system", "Downloading Org as an archive" and
> "Using Org's git repository" are three examples of such layout.

Why not just change the behavior of `org-export-headline-levels' for
texinfo output? We can already make plain lists, it doesn't seem useful
to me to also turn minor headings into lists. Since texinfo has the
concept of pages, why not just inline headings below H: level?

[...]

> The manual is not targeted to Texinfo experts. The difference between
> @ref arguments are subtle. At this point, I suggest to generate some
> template with Org and tweak the result.

I agree that Org doesn't need to support all the subtleties, but I did
find the out-of-the-box `org-store|insert-link' pretty confusing.

[...]

> IMO, advanced marking is not needed, at least out of the box. For
> example, @kbd{M-@key{TAB}} in Texinfo is morally equivalent to
> ~M-~ in Org, as long as the document targets info.

Morally equivalent in that they're typeset the same, right? I decided to
embrace texinfo pedantry and make a kbd macro :)

> Patch welcome!
>
> Also, two emphasis markers are unused in "ox-texinfo.el": _..._ and
> +...+. Another solution would be to use them for Texinfo special markup.
> However, it feels awkward to provide this by default.

I'd be happy to provide a patch, and I think we should mention
`org-texinfo-text-markup-alist', as well. Then we can say "here's how
Org's basic markup elements are translated, here's a defcustom you can
play with, and failing that you can also make a macro".

To be honest I don't know how the markup alist is supposed to work,
though. If I mark up a phrase /like so/, shouldn't that count as
"italic", and get transformed into @emph{like so}? Right now it goes
through unchanged into the Info file, which doesn't seem right, since
the Texinfo manual seems to indicate that _this_ is the proper way to do
emphasis.

The other thing I'd like to expand is the "Plain lists in Texinfo
export" section. First of all, it's about definition lists, not plain
lists, which I found confusing. Also, I think it just needs to have more
basic information in it, unless you already know texinfo well, it's hard
to know what it's telling you.

Eric




Re: [O] org-agenda-skip-function does not find inherited tags

2017-09-06 Thread Nicolas Goaziou
Hello,

Adrian Bradd  writes:

> I have the following custom agenda command:
>
> (setq org-agenda-custom-commands
>   '(("ww" "Work 2 day view"
>  ((agenda ""
>((org-agenda-files '("~/tmp/tmp.org"))
> (org-agenda-skip-function '(org-agenda-skip-entry-if 'notregexp
> ":@work:"))
> (org-agenda-start-on-weekday nil)
> (org-agenda-span 2)
> (org-agenda-overriding-header "\n2 day work
> view\n-\n")))
>
> Given the sample file below:
>
> * Top heading with tags
> :@work:admin:
> ** Next heading (inherited tags)
>SCHEDULED: <2017-09-04 Mon>
> ** Next heading (explicit tags)
> :@work:admin:
>SCHEDULED: <2017-09-04 Mon>
>
> The agenda will only display headings that have the tag explicitly defined.
> In this case, "Next heading (explicit tags)".
>
> Is there a way I can convince the agenda to honour inherited tags in this
> case?

You write a more appropriate function and use it as
`org-agenda-skip-function'. It could re-use the following snippet:

  (not (member "@work" (org-split-string (org-entry-get (point) "ALLTAGS"


Regards,

-- 
Nicolas Goaziou



Re: [O] Release 9.1

2017-09-06 Thread Kyle Meyer
Rasmus  writes:

> Bastien  writes:
>
>> Org-mode 9.1 is out!
>>
>> http://orgmode.org/Changes.html
>
> Great news!
>
> Thank you Nicolas, Kyle, Marco, Bastien, Kaushal, Achim and other code-
> and mailing list contributors.
>
> Rasmus

Great.  Rasmus, I've pushed the updated emacs-sync branch, so you should
be set to sync whenever you have the time.  Thank you!

-- 
Kyle



Re: [O] Table (used a "spreadsheet") org-sbe issues when the value is a string

2017-09-06 Thread Nicolas Goaziou
Hello,

Alex Bennée  writes:

> So calling scramble-string works as expected...
>
> #+tblname: reversed-strings
> | abcde   | #ERROR |
>
> | flibble | #ERROR |
> | dibble  | #ERROR |
> | xyzzy   | #ERROR |
> | another | #ERROR |
>
> #+TBLFM: $2='(org-sbe scramble-string (str $$1))

I cannot reproduce it. I get:

#+name: reversed-strings
| abcde   | edcba   |
| flibble | elbbilf |
| dibble  | elbbid  |
| xyzzy   | yzzyx   |
| another | rehtona |
#+TBLFM: $2='(org-sbe scramble-string (str $$1))

> Even calling org-sbe directly from a source block:
>
> #+name: call-scramble-string-via-sbe
> #+begin_src emacs-lisp :var val="thing"
>
> (org-sbe scramble-string (str val))
> #+end_src

AFAIK, `org-sbe' is limited to tables.

Regards,

-- 
Nicolas Goaziou



Re: [O] Agenda broken after update to 9.1

2017-09-06 Thread Nicolas Goaziou
Hello,

"Loris Bennett"  writes:

> I have just updated to 9.1 from whatever version was current on ELPA
> last week.  When I noe try to generate the agenda I get the following
> error:
>
>   Press key for agenda command:
>   org-agenda-list: Wrong type argument: listp, #("" 0 16 
> (org-heading t))

See ORG-NEWS > Incompatible changes > Change order of items in 
~org-agenda-time-grid~

Regards,

-- 
Nicolas Goaziou



Re: [O] Table (used a "spreadsheet") org-sbe issues when the value is a string

2017-09-06 Thread Alex Bennée

Nicolas Goaziou  writes:

> Hello,
>
> Frederick Giasson  writes:
>
>> Now, if I put a string in the format column, I al getting the following:
>>
>> 
>>
>> #+NAME: average-dataset-size
>> #+BEGIN_SRC clojure :var f="turtle" :exports none :results value
>> (identity f) #+END_SRC
>>
>> #+RESULTS: average-dataset-size
>> : turtle
>>
>>
>> | Format | Sizes distribution in MB | Average size in MB |
>> |+--+|
>> | turtle |  | #ERROR |
>> #+TBLFM: $3='(org-sbe "average-dataset-size" (f $1))
>>
>> 
>
> According to `org-sbe' docstring, it should be
>
>   #+TBLFM: $3='(org-sbe "average-dataset-size" (f $$1))
>
> Documentation could be drastically improved in that area, the manual is
> not even talking about `org-sbe'.

Even this doesn't seem to work. In my case:

#+name: scramble-string
#+begin_src emacs-lisp :var str="abcde"
  (apply #'string
 (reverse
  (string-to-list str)))
#+end_src

#+RESULTS: scramble-string
: edcba

So far so good

#+call: scramble-string(str="whatever-foo")

#+RESULTS:
: oof-revetahw

So calling scramble-string works as expected...

#+tblname: reversed-strings
| abcde   | #ERROR |
| flibble | #ERROR |
| dibble  | #ERROR |
| xyzzy   | #ERROR |
| another | #ERROR |
#+TBLFM: $2='(org-sbe scramble-string (str $$1))

Hmm no dice... the debugger lists:

Substitution history of formula
Orig:   '(org-sbe scramble-string (str $$1))
$xyz->  '(org-sbe scramble-string (str $$1))
@r$c->  '(org-sbe scramble-string (str $$1))
$1->'(org-sbe scramble-string (str $"abcde"))
Result: #ERROR
Format: NONE
Final:  #ERROR

Even calling org-sbe directly from a source block:

#+name: call-scramble-string-via-sbe
#+begin_src emacs-lisp :var val="thing"
(org-sbe scramble-string (str val))
#+end_src

So is this just broken untested functionality or are there any working
examples from which we could reverse engineer the proper docstring?

--
Alex Bennée



Re: [O] Agenda broken after update to 9.1

2017-09-06 Thread Loris Bennett
"Loris Bennett"  writes:

> Hi,
>
> I have just updated to 9.1 from whatever version was current on ELPA
> last week.  When I noe try to generate the agenda I get the following
> error:
>
>   Press key for agenda command:
>   org-agenda-list: Wrong type argument: listp, #("" 0 16 
> (org-heading t))
>
> Any ideas what the problem might be?

The culprit seems to be this:

  * Repeating Event
<2016-02-17 Wed 11:00-12:30 +1w>

If I remove the '+1w' then the error goes away.  If I then change the
date today:

  * Repeating Event
<2017-09-06 Wed 11:00>

I get the error again.  If I change the date to yesterday:

  * Repeating Event
<2017-09-05 Tue 11:00>

the error goes away.

Cheers,

Loris

-- 
This signature is currently under construction.




[O] Agenda broken after update to 9.1

2017-09-06 Thread Loris Bennett
Hi,

I have just updated to 9.1 from whatever version was current on ELPA
last week.  When I noe try to generate the agenda I get the following
error:

  Press key for agenda command:
  org-agenda-list: Wrong type argument: listp, #("" 0 16 
(org-heading t))

Any ideas what the problem might be?

Cheers,

Loris

-- 
This signature is currently under construction.




Re: [O] Release 9.1

2017-09-06 Thread Jonas Bernoulli
> Org-mode 9.1 is out!
Congratulations!



Re: [O] [RFC] Shrink columns dynamically

2017-09-06 Thread Nicolas Goaziou
Nicolas Goaziou  writes:

> I made some final changes to "hide-table-column" branch:
>
>   - Now C-u C-c TAB shrink columns with a width cookie and expands the
> others;
>
>   - When point is before the first column or after the last one, C-c TAB
> asks for columns ranges;
>
>   - I added documentation.
>
> If there is no objection or major bug (including usability ones), I will
> merge this branch into master in a couple of days.

Merged.

Regards,



Re: [O] setting local variables

2017-09-06 Thread Nicolas Goaziou
Rasmus  writes:

> I could not get it to work.  I tried stuff like "[[(org) Tables]]",
> "[[*(org) Tables]]" and , [[texinfo:(org) tables]].

You are talking about a special case for cross-referencing (which could
include internal reference, URL referencess). This is the job of
"org-info.el":

  [[info:org#tables]]

> It is always unresolved.  I couldn’t think of any other way of referencing
> an external manual, even skimming ox-texinfo.el, so it is not
> straightforward to me.

See 

  [[info:org#External links]]

oops, I mean 

  (info "(org) External links")

;)

> That is why I asked for a reference as I do not remember having seen such
> a layout in an info page.  If we know of an example, it might not be hard
> to implement.

The problem is not implementing it, really. It is about finding a way to
integrate it with Org syntax.

"org.texi" uses a lot of "@subheading" and related. See for example

  (info "(org) Installation")

"Using Emacs packaging system", "Downloading Org as an archive" and
"Using Org's git repository" are three examples of such layout.

>> What it sophisticated referencing? "ox-texinfo" supports internal and
>> external links without specific syntax. @pxref and @xref is just
>> syntactic sugar over @ref.
>>
>> "ox-texinfo.el" supports @email, @ref and @uref.
>
> I don’t know as I am not a texinfo expert, but in the texinfo manual they
> tell you to be vary of @ref.  It is probably a bit over the top.
>
> The @ref command can tempt writers to express themselves in a manner
> that is suitable for a printed manual but looks awkward in the Info
> format. Bear in mind that your audience could be using both the
> printed and the Info format. For example:
>
> Sea surges are described in @ref{Hurricanes}.
>
> looks ok in the printed output:
>
> Sea surges are described in Section 6.7 [Hurricanes], page 72. 
>
> but is awkward to read in Info, “note” being a verb:
>
> Sea surges are described in *note Hurricanes::.

In Org, just write

  For sea surges, see [[*Hurricanes]]

E.g., insert the "see" manually.

> Also, does Org support all four @ref arguments?  In either case, these are
> questions that I find reasonable and cannot find the answer to in the
> manual.

The manual is not targeted to Texinfo experts. The difference between
@ref arguments are subtle. At this point, I suggest to generate some
template with Org and tweak the result.

BTW, Org supports @ref with 1 argument and with arguments 1 and 3. There
is no way in Org to distinguish between online label and printed label.
The fourth and fifth arguments are not supported either, for the same
reason. You need to insert raw Texinfo code to achieve this.

> I guess the idea of Texinfo is produce info, html, and paper manuals
> consistently, though.  I personally agree, but just look at the Org manual
> and the fuss about @code vs @samp (which, I believe, are also displayed in
> the same way).

@code and @samp are not a problem, being respectively ~...~ and =...=.

> Texinfo is proudly pedantic. People exporting to Texinfo might care
> about @kbd{} vs @code{} and explaining how to get such fine-grained
> control would be a fine thing to document in the manual IMO.

Patch welcome!

Also, two emphasis markers are unused in "ox-texinfo.el": _..._ and
+...+. Another solution would be to use them for Texinfo special markup.
However, it feels awkward to provide this by default.

Regards,



Re: [O] setting local variables

2017-09-06 Thread Rasmus
Hi,

Nicolas Goaziou  writes:

> Rasmus  writes:
>
>> Eric Abrahamsen  writes:
>>
>>> The only real problem I encountered was that links to external Info
>>> manuals did not export correctly, and couldn't be followed. I gave up on
>>> learning the exact syntax of texinfo's @[px]ref commands because it was
>>> dinnertime, but I can figure out what went wrong and maybe provide a
>>> patch.
>>
>> I am not sure either.  I couldn’t get cross-referencing working.
>>
>> 
>> http://www.gnu.org/software/texinfo/manual/texinfo/texinfo.html#Cross-References
>>
>> The texinfo part of the Org manual could use a section on
>> cross-referencing
>
> IIRC, cross-referencing is straightforward. It should just work.

I could not get it to work.  I tried stuff like "[[(org) Tables]]",
"[[*(org) Tables]]" and , [[texinfo:(org) tables]].

It is always unresolved.  I couldn’t think of any other way of referencing
an external manual, even skimming ox-texinfo.el, so it is not
straightforward to me.

>>> The other thing I'd like to know is how to "inline" sections (ie output
>>> several sections on a single page), but still have links to those
>>> sections work correctly.
>>
>> Are you talking about info pages now?  Because in pdf and html it’s not an
>> issue as far as I’m aware.
>
> The OP is probably talking about @heading and al. 
>
> There is actually no way to specify such a "nodeless" heading (more
> exactly, an unnumbered heading that doesn't appear in the table of
> contents), because I couldn't find any appealing syntax (i.e., not too
> low level, and, if possible, generic enough).
>
> I agree this is the last major issue in this export back-end.

That is why I asked for a reference as I do not remember having seen such
a layout in an info page.  If we know of an example, it might not be hard
to implement.

> What it sophisticated referencing? "ox-texinfo" supports internal and
> external links without specific syntax. @pxref and @xref is just
> syntactic sugar over @ref.
>
> "ox-texinfo.el" supports @email, @ref and @uref.

I don’t know as I am not a texinfo expert, but in the texinfo manual they
tell you to be vary of @ref.  It is probably a bit over the top.

The @ref command can tempt writers to express themselves in a manner
that is suitable for a printed manual but looks awkward in the Info
format. Bear in mind that your audience could be using both the
printed and the Info format. For example:

Sea surges are described in @ref{Hurricanes}.

looks ok in the printed output:

Sea surges are described in Section 6.7 [Hurricanes], page 72. 

but is awkward to read in Info, “note” being a verb:

Sea surges are described in *note Hurricanes::.

Also, does Org support all four @ref arguments?  In either case, these are
questions that I find reasonable and cannot find the answer to in the
manual.

>> Another area that seems slightly lacking is support for all markings, so
>> perhaps there could be a section on accessing your favorite via
>> ‘org-texinfo-text-markup-alist’ (if ‘org-texinfo--text-markup’ supports
>> it) and the rest via macros, if necessary.
>>
>> 
>> http://www.gnu.org/software/texinfo/manual/texinfo/texinfo.html#Marking-Text
>
> IMO, advanced marking is not needed, at least out of the box. For
> example, @kbd{M-@key{TAB}} in Texinfo is morally equivalent to ~M-~
> in Org, as long as the document targets info.
  

I guess the idea of Texinfo is produce info, html, and paper manuals
consistently, though.  I personally agree, but just look at the Org manual
and the fuss about @code vs @samp (which, I believe, are also displayed in
the same way).  Texinfo is proudly pedantic.  People exporting to Texinfo
might care about @kbd{} vs @code{} and explaining how to get such
fine-grained control would be a fine thing to document in the manual IMO.

Rasmus

-- 
Hooray!




Re: [O] [PATCH] Update statistic cookies when archiving

2017-09-06 Thread Nicolas Goaziou
Hello,

Jay Kamat  writes:

> Done.

Applied. Thank you!
>
> I'm not sure if I did the tests 'correctly' though. I placed them in
> test-org-element.el since there was a little bit of archive based
> testing there, is there a better place to put them? I couldn't find any
> file for org-archive testing. Maybe I'll write some more archive tests
> later...

I created test-org-archive.el on your behalf.

Regards,

-- 
Nicolas Goaziou0x80A93738



Re: [O] [PATCH] Fix table variable with commas in ob-sqlite

2017-09-06 Thread Nicolas Goaziou
Hello,

Eduardo Bellani  writes:

> ob-sqlite.el: Enable table with fields containing commas to be used as
> arguments to sqlite source blocks
>
> * lisp/ob-sqlite.el: Stop interfering with the 'orgtbl-to-csv' default
>   formatting.
>
> * testing/lisp/test-ob-sqlite.el:: Adds a test using a table with
>   commas in the content of any of its fields as an argument for a
>   sqlite source block. Use the 'org-test-with-temp-text' pattern.
>
>
> The problem here was that ob-sqlite was providing a format to the
> 'orgtbl-to-csv' that actually overwrote the default format in that
> function, and in the case where there were commas in the content of the
> table, broke the table as argument mechanism.

Applied. Thank you.

Regards,

-- 
Nicolas Goaziou



Re: [O] [PATCH] org-agenda: Add 'none setting for org-agenda-overriding-header

2017-09-06 Thread Nicolas Goaziou
Hello,

Adam Porter  writes:

> Here is another patch series with the requested changes.

Applied. Thank you!

If you feel like it, some tests in "test-org-agenda.el" would be nice,
too.

Regards,

-- 
Nicolas Goaziou



Re: [O] link recognition in orgmode

2017-09-06 Thread Nicolas Goaziou
Hello,

John Kitchin  writes:

> The reason this came up is related to restructured text in a src block
> docstring. For example, using
> http://sphinxcontrib-bibtex.readthedocs.io/en/latest/usage.html#roles-and-directives,
> one can write: "See :cite:`1987:nelson` for an introduction to
> non-standard analysis." and the cite: appears to be recognized as part
> of a link with `1987:nelson` as the path. In this case I would not
> expect that to be interpreted as a link. The backticks in the path are
> a little problematic for org-ref since they are not part of the actual
> key.

In this particular case, this is a problem of the fontification engine.
It shouldn't fontify Org elements in a src block, or any other verbatim
context. More precisely, `org-activate-links' does not check if match is
within such a context.

Ideally, fontification should use the parser, which doesn't fail in this
case. This is on my long TODO list; unfortunately, it has no NEXT
keyword yet.

Regards,

-- 
Nicolas Goaziou



Re: [O] setting local variables

2017-09-06 Thread Nicolas Goaziou
Hello,

Rasmus  writes:

> Eric Abrahamsen  writes:
>
>> The only real problem I encountered was that links to external Info
>> manuals did not export correctly, and couldn't be followed. I gave up on
>> learning the exact syntax of texinfo's @[px]ref commands because it was
>> dinnertime, but I can figure out what went wrong and maybe provide a
>> patch.
>
> I am not sure either.  I couldn’t get cross-referencing working.
>
> 
> http://www.gnu.org/software/texinfo/manual/texinfo/texinfo.html#Cross-References
>
> The texinfo part of the Org manual could use a section on
> cross-referencing

IIRC, cross-referencing is straightforward. It should just work.

>> The other thing I'd like to know is how to "inline" sections (ie output
>> several sections on a single page), but still have links to those
>> sections work correctly.
>
> Are you talking about info pages now?  Because in pdf and html it’s not an
> issue as far as I’m aware.

The OP is probably talking about @heading and al. 

There is actually no way to specify such a "nodeless" heading (more
exactly, an unnumbered heading that doesn't appear in the table of
contents), because I couldn't find any appealing syntax (i.e., not too
low level, and, if possible, generic enough).

I agree this is the last major issue in this export back-end.

> I would agree, but perhaps I’m biased since I don’t have much of a working
> knowledge of texinfo other than enough to add sections to an existing
> manual.
>
> You could look at the texinfo manual and see if we are missing something
>
> http://www.gnu.org/software/texinfo/manual/texinfo/texinfo.html
>
> On the top of my head it would be good to have a cross-referencing
> section, though I think that there may not be support for too
> sophisticated referencing, at least judging from ‘org-texinfo--@ref’.

What it sophisticated referencing? "ox-texinfo" supports internal and
external links without specific syntax. @pxref and @xref is just
syntactic sugar over @ref.

"ox-texinfo.el" supports @email, @ref and @uref.

> Another area that seems slightly lacking is support for all markings, so
> perhaps there could be a section on accessing your favorite via
> ‘org-texinfo-text-markup-alist’ (if ‘org-texinfo--text-markup’ supports
> it) and the rest via macros, if necessary.
>
> 
> http://www.gnu.org/software/texinfo/manual/texinfo/texinfo.html#Marking-Text

IMO, advanced marking is not needed, at least out of the box. For
example, @kbd{M-@key{TAB}} in Texinfo is morally equivalent to ~M-~
in Org, as long as the document targets info.

If you absolutely need @kbd, you can use a macro.

Regards,

-- 
Nicolas Goaziou



Re: [O] Release 9.1

2017-09-06 Thread Rasmus
Bastien  writes:

> Org-mode 9.1 is out!
>
> http://orgmode.org/Changes.html

Great news!

Thank you Nicolas, Kyle, Marco, Bastien, Kaushal, Achim and other code-
and mailing list contributors.

Rasmus

-- 
Summon the Mothership!




Re: [O] setting local variables

2017-09-06 Thread Rasmus
Eric Abrahamsen  writes:

> The only real problem I encountered was that links to external Info
> manuals did not export correctly, and couldn't be followed. I gave up on
> learning the exact syntax of texinfo's @[px]ref commands because it was
> dinnertime, but I can figure out what went wrong and maybe provide a
> patch.

I am not sure either.  I couldn’t get cross-referencing working.


http://www.gnu.org/software/texinfo/manual/texinfo/texinfo.html#Cross-References

The texinfo part of the Org manual could use a section on
cross-referencing

> The other thing I'd like to know is how to "inline" sections (ie output
> several sections on a single page), but still have links to those
> sections work correctly.

Are you talking about info pages now?  Because in pdf and html it’s not an
issue as far as I’m aware.

> That problem and most others could probably be "solved" by expanding the
> docs. For instance, regarding the sectioning problem, "12.14.6 Headings
> and sectioning structure" in the Org manual says:
>
>   If an Org headline’s level has no associated Texinfo structuring
>   command, or is below a certain threshold (*note Export settings), then
>   the Texinfo export back-end makes it into a list item.
>
> Why a list item? Plenty of Info manuals have multiple sub-headings on a
> single page, how do we do that?

Could you provide an example?  I have mostly seen numbered sections
without subtitles

NN.mm title

text

menu

> In general, I think the texinfo part of the Org manual could benefit
> from some beefing up, and I'd be happy to provide suggestions.

I would agree, but perhaps I’m biased since I don’t have much of a working
knowledge of texinfo other than enough to add sections to an existing
manual.

You could look at the texinfo manual and see if we are missing something

http://www.gnu.org/software/texinfo/manual/texinfo/texinfo.html

On the top of my head it would be good to have a cross-referencing
section, though I think that there may not be support for too
sophisticated referencing, at least judging from ‘org-texinfo--@ref’.

Another area that seems slightly lacking is support for all markings, so
perhaps there could be a section on accessing your favorite via
‘org-texinfo-text-markup-alist’ (if ‘org-texinfo--text-markup’ supports
it) and the rest via macros, if necessary.

http://www.gnu.org/software/texinfo/manual/texinfo/texinfo.html#Marking-Text

Thanks,
Rasmus

-- 
There are known knowns; there are things we know that we know




[O] Release 9.1

2017-09-06 Thread Bastien
Hi all,

Org-mode 9.1 is out!

http://orgmode.org/Changes.html

Enjoy,

-- 
 Bastien




Re: [O] directory from which attachments are taken

2017-09-06 Thread Rasmus
kevinbanjo  writes:

> I'm downloading files into my "~/Downloads" directory and attaching them to
> an org file in "~/Private/org" and every time it tries to look in the
> latter for the attachment and I have to navigate back to the former.  Is
> there a setting where I can direct it where to initially look for the files
> to attach or a setting where it will just keep the last place I attached a
> file and just use that as the initial value?

You could probably do something like this, though I haven’t tested it
extensively.

(defun rasmus/org-attach (orig-fun  args)
  "Change dir of the shell to buffer's `default-directory'."
  (let ((default-directory "~/Downloads"))
(apply orig-fun args)))

(advice-add #'org-attach :around #'rasmus/org-attach)


-- 
Sådan en god dansk lagereddike kan man slet ikke bruge mere