[O] closing *org-agenda* pops up emacs *calander* buffer?

2018-06-06 Thread Xebar Saram
Hi all

Weird issue. each time i close the *org-agenda* view (using q) i always get
a window with what seems the default emacs calendar (the *calendar*
buffer). I want to go back to the previous buffer i visited before
launching org-agenda.

I cant understand whats causing this. any clues?

this is the buffer that always pops up

https://paste.xinu.at/b9O0/

best

Z


Re: [O] Suggestion: Add zero-width nbsp to emphasis-regexp-components

2018-06-06 Thread Marcin Borkowski


On 2018-06-06, at 14:07, Nicolas Goaziou  wrote:

> This is already the case. 
>
> PRE and POST parts of `org-emphasis-regexp-components' contain
> "[:space:]", which matches zero width space.

Wow, thanks!  That means I really need to upgrade my Org.

Best,

-- 
Marcin Borkowski
http://mbork.pl



[O] Bug: Archiving creates multiple parent tasks in master [9.1.13 (release_9.1.13-787-g13a09b @ c:/D-Drive/bin/org-mode/lisp/)]

2018-06-06 Thread Bernt Hansen


Hi,

Archiving tasks using the master branch with the below configuration
creates duplicate "* Archived Tasks" heading each time you archive in
the test.org_archive file.

The behaviour in the maint branch is correct and files subsequently
archived tasks under the single main heading.

Thanks for org-mode!

Regards,
Bernt

-- test.el -
(setq org-archive-location "%s_archive::* Archived Tasks")

-- test.org 
#+FILETAGS: TEST
#+STARTUP: content

*Keys To Reproduce*

1) Move to next heading
   C-c C-n

2) Move to next heading
   C-c C-n

3) Archive heading
   C-c C-x C-a

4) Archive heading
   C-c C-x C-a

Results in test.org_archive:

maint branch produces (correct)
#+BEGIN_EXAMPLE
* Archived Tasks
** TODO do something
** TODO foo :BAR:
#+END_EXAMPLE

master branch produces (incorrect)
#+BEGIN_EXAMPLE
* Archived Tasks
** TODO do something
* Archived Tasks
** TODO foo :BAR:
#+END_EXAMPLE

* TODO Test Parent  :PRODUCTION:MISC:
  :PROPERTIES:
  :EFFORT:   15:30
  :END:
** TODO do something
   :PROPERTIES:
   :EFFORT:   15
   :END:
   :LOGBOOK:
   CLOCK: [2018-05-12 Sat 00:26]--[2018-05-12 Sat 00:26] =>  0:00
   CLOCK: [2018-05-12 Sat 00:23]--[2018-05-12 Sat 00:23] =>  0:00
   CLOCK: [2018-05-12 Sat 00:22]--[2018-05-12 Sat 00:22] =>  0:00
   CLOCK: [2018-05-12 Sat 00:22]--[2018-05-12 Sat 00:22] =>  0:00
   CLOCK: [2018-05-12 Sat 00:07]--[2018-05-12 Sat 00:08] =>  0:01
   CLOCK: [2018-05-12 Sat 00:00]--[2018-05-12 Sat 00:04] =>  0:04
   :END:
** TODO foo :BAR:
   :PROPERTIES:
   :EFFORT:   00:30
   :END:




Emacs  : GNU Emacs 23.2.1 (i486-pc-linux-gnu, GTK+ Version 2.20.1)
 of 2013-01-08 on murphy, modified by Debian
Package: Org-mode version 8.3.1 (release_8.3.1-54-g102def @ 
/home/bernt/git/org-mode/lisp/)



Re: [O] org-detangle seems broken

2018-06-06 Thread Frederick Giasson
Hi


>
> > block to its tangled source is created, then we could use it with that
> option in `org-babel-detangle` to switch back to the source if it is the
> wish of the user.
>
> It sounds like org-babel-tangle-jump-to-org is what you want.
>

In fact it is its opposite that I need, code block to tangled source file.

Fred

>


Re: [O] org-detangle seems broken

2018-06-06 Thread Grant Rettke
On Wed, Jun 6, 2018 at 7:31 AM, Frederick Giasson  wrote:
> If this is really the behavior, then I think that a new option should be 
> added to it such that we can choose one behavior or the other. If a function 
> that jump from a code
> block to its tangled source is created, then we could use it with that option 
> in `org-babel-detangle` to switch back to the source if it is the wish of the 
> user.

It sounds like org-babel-tangle-jump-to-org is what you want.



[O] org-capture: Avoid inserting a new line when the template is empty

2018-06-06 Thread xristos
Hello,

An example of a capture workflow that I am using all the time
is the following:

("bbp" "Preview book" plain
 (file+function "~/org/books.org.gpg" xristos/org-capture-preview-find-location)
  "" :immediate-finish t :jump-to-captured t :empty-lines 0)

The idea is that the function I provide is fully responsible for cursor 
positioning
and entry manipulation. To that end, I pass an empty template ("") and
set :immediate-finish to t. This has been working fine with an older Org
version but since I recently updated to Org 9.1.13, org-capture-fill-template 
will
insert a new line every single time which is not what I want to happen.

The relevant code is at org-capture.el, line 1843. I think that having a way
to tell Org not to change the user-provided template at all and just use
it verbatim would be useful in the general sense.

For my own needs, I've added an extra property (:verbatim-template) which I
check for inside org-capture-fill-template:

@@ -1840,7 +1840,8 @@ The template may still contain \"%?\" for cursor 
positioning."
   (goto-char (point-max))
   (skip-chars-backward " \t\n")
   (delete-region (point) (point-max))
-  (insert "\n")
+  (unless (org-capture-get :verbatim-template)
+   (insert "\n"))
 
Chris



[O] Babel problem: Output incomplete if it contains # character (only in session)

2018-06-06 Thread Marian Schubert
Hello,

I'm having trouble with babel block like this:

#+BEGIN_SRC shell :results output :session xyz
echo "foo#bar"
#+END_SRC

#+RESULTS:
:
: bar

I expect results to be foo#bar, but it's just bar.
If I remove :session xyz it displays correct value, i.e.:

#+RESULTS:
: foo#bar

Any idea what might be wrong?

Best regards,
Marian


[O] Bug: Python block, print function in session [9.1.1 (9.1.1-6-gd40deb-elpa @ c:/Users/tabaa004/Dropbox/home/.emacs.d/elpa/org-20170925/)]

2018-06-06 Thread Tarjei Bærland
Hi!

The following src block prints correctly if run in non-session mode, it
does not print at all if the :session keyword is set.

#+BEGIN_SRC python :results output org
a, b = 0, 1

while b < 1000:
a, b = b, a + b
print(a, end=" ")
#+END_SRC

#+RESULTS:
#+BEGIN_SRC org
1 1 2 3 5 8 13 21 34 55 89 144 233 377 610 987
#+END_SRC

Is this expected behavior?

Kind regards,
Tarjei Bærland





Emacs  : GNU Emacs 25.0.50.1 (x86_64-w64-mingw32)
 of 2015-07-25 on KAEL
Package: Org mode version 9.1.1 (9.1.1-6-gd40deb-elpa @
c:/Users/tabaa004/Dropbox/home/.emacs.d/elpa/org-20170925/)

current state:
==
(setq
 org-tab-first-hook '(org-babel-hide-result-toggle-maybe
  org-babel-header-arg-expand)
 org-footnote-section "nil"
 org-speed-command-hook '(org-speed-command-activate
  org-babel-speed-command-activate)
 org-agenda-skip-timestamp-if-done t
 org-occur-hook '(org-first-headline-recenter)
 org-src-tab-acts-natively t
 org-metaup-hook '(org-babel-load-in-session-maybe)
 org-html-format-drawer-function #[514 "\207" [] 3 "\n\n(fn NAME CONTENTS)"]
 org-src-window-setup '(current-window)
 org-latex-format-inlinetask-function
'org-latex-format-inlinetask-default-function
 org-confirm-shell-link-function 'yes-or-no-p
 org-image-actual-width nil
 org-ascii-format-inlinetask-function 'org-ascii-format-inlinetask-default
 org-export-with-section-numbers nil
 org-export-with-toc nil
 org-list-allow-alphabetical t
 org-agenda-skip-scheduled-if-done t
 org-agenda-custom-commands '(("h" "Agenda og hjemme"
   ((agenda ""
 ((org-agenda-span 14)
  (org-deadline-warning-days 14)
  (org-agenda-prefix-format "")
  (org-agenda-filter-preset (quote
("-jobb"
 )
)
   )
  ("j" "Jobb i dag og i morra"
   ((agenda ""
 ((org-agenda-span 2)
  (org-agenda-filter-preset (quote
("+jobb")))
  (org-agenda-prefix-format "%t "))
 )
(todo "TODO"
 ((org-agenda-filter-preset (quote
("+jobb")))
  (org-agenda-max-entries 0))
 )
)
   )
  )
 org-latex-format-headline-function
'org-latex-format-headline-default-function
 org-agenda-include-diary t
 org-startup-indented t
 org-after-todo-state-change-hook '(org-clock-out-if-current)
 org-latex-format-drawer-function #[514 "\207" [] 3 "\n\n(fn _ CONTENTS)"]
 org-odt-format-headline-function 'org-odt-format-headline-default-function
 org-capture-mode-hook '(delete-other-windows)
 org-from-is-user-regexp nil
 org-html-postamble nil
 org-src-mode-hook '(org-src-babel-configure-edit-buffer
 org-src-mode-configure-edit-buffer)
 org-tags-column -94
 org-agenda-before-write-hook '(org-agenda-add-entry-text)
 org-babel-pre-tangle-hook '(save-buffer)
 org-html-footnotes-section "\n%s\n\n\n%s\n\n"
 org-trigger-hook '(taba-write-journal-on-todo)
 org-mode-hook '(visual-fill-column-mode visual-line-mode
 #[0 "\300\301\302\303\304$\207"
   [add-hook change-major-mode-hook org-show-block-all
append
local]
   5]
 #[0 "\300\301\302\303\304$\207"
   [add-hook change-major-mode-hook
org-babel-show-result-all
append local]
   5]
 org-babel-result-hide-spec org-babel-hide-all-hashes)
 org-refile-targets '((nil :maxlevel . 2) (org-agenda-files :maxlevel . 2))
 org-export-coding-system 'utf-8
 org-bibtex-headline-format-function #[257 "\300 \236A\207" [:title] 3
"\n\n(fn ENTRY)"]
 org-archive-hook '(org-attach-archive-delete-maybe)
 org-ascii-format-drawer-function #[771 " \207" [] 4 "\n\n(fn NAME CONTENTS
WIDTH)"]
 org-odt-format-inlinetask-function
'org-odt-format-inlinetask-default-function
 org-refile-use-outline-path 'file
 org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers
  org-cycle-show-empty-lines
  org-optimize-window-after-visibility-change)
 org-todo-keywords '((sequence "TODO" "|" "DONE")
 (sequence "." "PLANLAGT" "|" "AVHOLDT")
 (sequence "|" "CANCELED"))
 org-modules '(org-habit org-w3m org-bbdb org-bibtex org-docview org-gnus
   org-info org-irc org-mhe org-rmail)
 org-agenda-window-setup '(current-window)
 org-babel-tangle-lang-exts '(("latex" . "tex") ("D" . "d") 

[O] Bug: org-log-reschedule ignored when calling `org-agenda-do-date-{later, earlier}` [9.1.13 (9.1.13-elpaplus @ ~/.emacs.d/elpa/org-plus-contrib-20180521/)]

2018-06-06 Thread Christian Schwarzgruber


Remember to cover the basics, that is, what you expected to happen and
what in fact did happen.  You don't know how to make a good report?  See

 https://orgmode.org/manual/Feedback.html#Feedback

Your bug report will be posted to the Org mailing list.


I have set `org-log-reschedule` to `'note`. When calling
`org-agenda-do-date-later` or `org-agenda-do-date-earlier` in *Org Agenda*
buffer, `org-log-reschedule` gets ignored.

I would expect that *Org Note* buffer pops-up to insert a note.

Thank you!

Emacs  : GNU Emacs 26.1 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.22.26)
 of 2018-05-21
Package: Org mode version 9.1.13 (9.1.13-elpaplus @ 
~/.emacs.d/elpa/org-plus-contrib-20180521/)



[O] Bug: Table does not align properly [9.1.13 (9.1.13-elpaplus @ /home/diogo/.emacs.d/elpa/org-plus-contrib-20180521/)]

2018-06-06 Thread Diogo Ferrari
Remember to cover the basics, that is, what you expected to happen and
what in fact did happen.  You don't know how to make a good report?  See

 https://orgmode.org/manual/Feedback.html#Feedback

Your bug report will be posted to the Org mailing list.




Emacs  : GNU Emacs 25.2.2 (x86_64-pc-linux-gnu, GTK+ Version 3.22.21)
 of 2017-09-22, modified by Debian
Package: Org mode version 9.1.13 (9.1.13-elpaplus @
/home/diogo/.emacs.d/elpa/org-plus-contrib-20180521/)


-- 
Diogo Ferrari
PhD Candidate
University of Michigan, Ann Arbor
Department of Political Science
E-mail: dferr...@umich.edu
Website: http://dioferrari.wordpress.com/

Open Source! Use R! Use Linux! Use Emacs! Use Python!

"A vida é a arte de tirar conclusões suficientes de dados insuficientes"


Re: [O] Cannot access repository

2018-06-06 Thread Bastien
Hi Robert,

Robert Klein  writes:

> I can confirm, that the gogs service is down.

I restarted gogs, thanks for letting me know.

> Bastien, I'm not sure how you started gogs.  How about starting it
> using a systemd unit?  (Example @
> https://github.com/gogs/gogs/blob/master/scripts/systemd/gogs.service)

The setup is manual for now: I'll send you details in private.

Thanks!

-- 
 Bastien



Re: [O] Cannot access repository

2018-06-06 Thread Robert Klein
Hi,

I can confirm, that the gogs service is down.

Bastien, I'm not sure how you started gogs.  How about starting it
using a systemd unit?  (Example @
https://github.com/gogs/gogs/blob/master/scripts/systemd/gogs.service)

Best regards
Robert


On Wed, 6 Jun 2018 08:48:18 -0400
Charles Millar  wrote:

> I cannot access
> 
> https://code.orgmode.org/bzg/org-mode.git
> 
> requested url returned error 502
> 
> Charlie Millar
> 




[O] table and a if structure

2018-06-06 Thread Uwe Brauer



Hi

I have the following table

| name   | value1 | value2 | result  |
|+++-|
| first  | 4  |  5 | 4.2 |
| second | NP |  5 | 0.8 NP + 1. |
#+TBLFM: $4=if("$2" == "NP",string("NP"),0.8*$2+0.2*$3)

The idea is if the second column has an entry NP then no operation
should be applied. But my table does not work. So it seems that there is
some syntax error.

Thanks

Uwe Brauer 




Re: [O] Suggestion: Add zero-width nbsp to emphasis-regexp-components

2018-06-06 Thread Chris
Hey,

Nicolas Goaziou (m...@nicolasgoaziou.fr) 2018-06-06:
> Marcin Borkowski  writes:
> This is already the case. 
>
> PRE and POST parts of `org-emphasis-regexp-components' contain
> "[:space:]", which matches zero width space.

Odd. I guess my version 9.1.6 is too old to get this change? In that
case, I'm looking forward to upgrade!

Regards,
Chris


signature.asc
Description: PGP signature


[O] Cannot access repository

2018-06-06 Thread Charles Millar

I cannot access

https://code.orgmode.org/bzg/org-mode.git

requested url returned error 502

Charlie Millar



Re: [O] org-detangle seems broken

2018-06-06 Thread Frederick Giasson
Hi Grant,


I think it is expected. The code looks like this:
>
> (when (setq new-body (org-babel-tangle-jump-to-org))
>   (org-babel-update-block-body new-body))
>

Yeah not sure I fully understand that code. Basically it does this for each
code block that needs to be detangled right? I am just not sure why the
focus doesn't return back to the source at the end of the process.


> The first time I detangled I was surprised, too.
>
> But then it hit me: if you are detangling then you probably might want to
> 1. See the updated code
> 2. Commit the updated code
>

Yes, I agree with you. However on a team that work on a LP project,
different people have different preferences and workflows. Personally I
only code in the Org-file, and toggle a code block to its major mode if I
need something provided by the major mode (coding in Clojure). However,
some people prefer see the full namespace (one namespace per Org file)
directly in Cider (the major mode) and detangle from there (this is why I
got interested in detangling).

In their case, having the buffer switching back to the Org file is a bit
irritating, particularly since there is no (yet) any function that let you
switch to the tangle source file of a code block.

If this is really the behavior, then I think that a new option should be
added to it such that we can choose one behavior or the other. If a
function that jump from a code block to its tangled source is created, then
we could use it with that option in `org-babel-detangle` to switch back to
the source if it is the wish of the user.

Thoughts?


Thanks,

Fred


Re: [O] Suggestion: Add zero-width nbsp to emphasis-regexp-components

2018-06-06 Thread Nicolas Goaziou
Hello,

Marcin Borkowski  writes:

> On 2018-06-06, at 09:54, Chris  wrote:
>
>> * Problem
>>
>>   There needs to be a way to coax Org into interpreting something as an
>>   emphasis marker, even if it ordinarily would not look like it (for
>>   example, because it is in the middle of a regular word, when putting
>>   emphasis on only part of a word.)
>>
>> * Suggested Solution
>>
>>   Include the Unicode zero width no-break space character (U+feff) in
>>   both ~pre~ and ~post~ sections of ~org-emphasis-regexp-components~.
>
> +1

This is already the case. 

PRE and POST parts of `org-emphasis-regexp-components' contain
"[:space:]", which matches zero width space.

Regards,

-- 
Nicolas Goaziou



Re: [O] Suggestion: Add zero-width nbsp to emphasis-regexp-components

2018-06-06 Thread Marcin Borkowski


On 2018-06-06, at 09:54, Chris  wrote:

> * Problem
>
>   There needs to be a way to coax Org into interpreting something as an
>   emphasis marker, even if it ordinarily would not look like it (for
>   example, because it is in the middle of a regular word, when putting
>   emphasis on only part of a word.)
>
> * Suggested Solution
>
>   Include the Unicode zero width no-break space character (U+feff) in
>   both ~pre~ and ~post~ sections of ~org-emphasis-regexp-components~.

+1

-- 
Marcin Borkowski
http://mbork.pl



Re: [O] General advice beyond Org

2018-06-06 Thread Marco
Hey fellow orgers,

I started as post-doc almost 10 years ago, I made a point in having
linux on my desktop and only use software I see fit - and know - such
R, and LaTeX to write papers. The occasional word/excel document I
opened with libreoffice/wps office or more frequently remotely on a
windows server / on a virtualbox, same with the occasional
windows-only piece of software I needed to use.
After 8-9 years of mockery, my whole departement is now switching to
LiNuX/LaTeX/python/R/jupyter, with the exception of a few specialized
softwares which are windows-only and will run on selected
machines/servers. Point is, also the secretary has to migrate, she was
the greatest advocate against the change.
No luck yet with emacs + org with my colleagues, but hey, one step at a time ;)
If your research and daily work involves programming/modelling I
actually don't see any point in staying on windows. Unices have LOTS
of advantages. The best general-purpose research tools nowadays are
free/libre software (since 3D FEM was named: openfoam, moose,
opencascade/salome, code_aster just to name a few... ), that is, if
you are developing something and not just running models, their steep
learning curve pays off immediately. If it's just a matter of running
specific models maybe there are other specialized softwares which may
be more efficient (e.g., avizo for 3D microtomography, eclipse /
petrel for geological modelling and reservoir engineering). In the
realm of statistics/machine learning/AI it's all linux-based free
software (think about keras + tensorflow with R and Python, but loads
and loads of other similar stuff out there).
So in my opinion in a research environment there are 2 kinds of
activities: computational/programming stuff, where unix and free
software have a clear advantage both on desktops and of course on HPC
(of course it depends how it looks like in your domain AND in your
research group), and on the other side wiriting documents and
interacting with others (reports, proposals, data exchange, papers).
You should have 100% control of the first category, but still have to
factor in cooperation with colleagues (i.e.: if everyoen is working on
matlab and you are supposed to extend and re-use their developments...
probably you should too. At least try sci-lab and octave); but you can
definitely compromise on the second.
Cheers and good luck,
domanov



[O] Suggestion: Add zero-width nbsp to emphasis-regexp-components

2018-06-06 Thread Chris
Hello!

I'm not an experienced mailing list user, but I will try to be brief.
Please excuse my lack of common courtesy.


* Problem

  There needs to be a way to coax Org into interpreting something as an
  emphasis marker, even if it ordinarily would not look like it (for
  example, because it is in the middle of a regular word, when putting
  emphasis on only part of a word.)

  - Version of Org: 9.1.6
  - Version of Emacs: GNU Emacs 25.3.2 (x86_64-pc-linux-gnu)


* Suggested Solution

  Include the Unicode zero width no-break space character (U+feff) in
  both ~pre~ and ~post~ sections of ~org-emphasis-regexp-components~.

  I currently have trouble accessing code.orgmode.org (502 Bad Gateway),
  but I imagine the solution to look something like

  --- org.el  2018-06-06 09:33:56.602335268 +0200
  +++ org-zwnbsp-emphasis.el  2018-06-06 09:39:37.985958647 +0200
  @@ -4355,7 +4355,7 @@
   ;; set this option proved cumbersome.  See this message/thread:
   ;; http://article.gmane.org/gmane.emacs.orgmode/68681
   (defvar org-emphasis-regexp-components
  -  '("- \t('\"{" "- \t.,:!?;'\")}\\[" " \t\r\n" "." 1)
  +  '("- \ufeff\t('\"{" "- \ufeff\t.,:!?;'\")}\\[" " \t\r\n" "." 1)
 "Components used to build the regular expression for emphasis.
   This is a list with five entries.  Terminology:  In an emphasis string
   like \" *strong word* \", we call the initial space PREMATCH, the final

  This has the added tiny benefit that legacy documents that still use
  U+feff as a byte order mark may be able to get emphasis also on their
  first word... (Not sure if this is a problem, actually, just throwing
  it out there.)


* Discussion

  - Does this even make sense to begin with, or is it just me?

  - Is the zero-width no-break space the most sensible character to do
this with?

I see the zero-width joiner as the alternative – but that appears to
have more legitimate uses inside words, especially in some
non-Western scripts such as Arabic and Indic. I use U+feff mostly
because it is actually sort of a space but not quite.


* Related Reports

  I found an email in the archives which touches on the same point[1],
  but suggests a more radical change.

  [1]: https://lists.gnu.org/archive/html/emacs-orgmode/2017-09/msg00363.html

Regards,
Chris


signature.asc
Description: PGP signature