[O] crypt and sync

2014-09-05 Thread Hannes Schulz
Dear list,

In my org-files I use org-crypt to encrypt subtrees via GPG. That seemed to
work fine for some time, but lastly (in connection with org-mobile or
org-caldav) the entries get a property drawer with a unique ID.  This seems
to lead org-crypt to think the entry is not encrypted.  Thus, when saving,
it encrypts the property drawer /and/ the encrypted text.  If I now want to
open the encrypted subtree, I have to decrypt quite a few times, each time
just removing the property drawer with the ID.

Did any of you observe this before?

Shouldn't org-crypt disregard property drawers?

cheers,

-Hannes


[O] minted/lstlistings code block export when using :flags

2013-04-11 Thread Hannes Schulz
Dear list,

I have some trouble with my C++ code blocks, and exporting them to LaTeX.
My version is current git HEAD.

There are two issues:

1) LaTeX Export: For some reason, the babel language name gets parts of the
compiler :flags mixed in, resulting in bad LaTeX code such as this:

\begin{minted}[]{cpp-L/usr/local/cuda/lib}   % -- HERE
#include iostream
int main(int argc, char** argv){
 std::cout  Hello World  std::endl;
}
\end{minted}

This behavior is the same for lstlistings and minted type, but (obviously)
does not affect verbatim.

2) Not sure if anyone else has this issue, but for linking a c++ file with
g++, I need to specify the linker libraries AFTER the cpp file I'm trying
to compile. For me, this could be resolved by switching the order of the
arguments to (format...) in ob-C.el. Is there any reason why the order is
as it is?

A minimal example is included below.

yours,

  Hannes



 snip ===
#+TITLE: Test
#+LaTeX_HEADER: \usepackage{minted}
#+LaTeX_HEADER: \usemintedstyle{borland}
#+latex_header: \usepackage{color}
#+latex_header: \renewcommand{\maketitle}{}
#+LANGUAGE:  en
#+OPTIONS:   H:3 num:nil toc:nil \n:nil @:t ::t |:t ^:t -:t f:t *:t :t
#+OPTIONS:   TeX:t LaTeX:t skip:nil d:nil todo:t pri:nil tags:not-in-toc
#+INFOJS_OPT: view:nil toc:nil ltoc:t mouse:underline buttons:0 path:
http://orgmode.org/org-info.js
#+LaTeX_CLASS: article
#+LaTeX_CLASS_OPTIONS: [english,final]
#+begin_src emacs-lisp :exports none :results silent
  ; work with minted
  (setq org-latex-listings 'minted)
#+end_src

* Test

#+begin_src cpp :exports code :flags -L/usr/lib -lcblas
  #include iostream

  int main(int argc, char** argv){
   std::cout  Hello World  std::endl;
  }
#+end_src

#+RESULTS:
: Hello World
 snap ===


Re: [O] Bug report: agenda column mode failure

2012-08-31 Thread Hannes Schulz
Hi Bastien,

 On 31.08.2012, at 08:05, Bastien wrote:
  This should be fixed now.  Thanks to you and Jacob for
  reporting this!
 
 Seems to work for me.

works for me too, thanks for fixing this so quickly!

A quick question: After playing with minimal configs, I now need to start emacs 
with 

$ emacs -l ~/.emacs.d/init.el

it seems to have forgotten that it should load init.el automatically. 
Any hint how I can fix this and avoid it next time?

cheers,

 Hannes



[O] Bug report: agenda column mode failure

2012-08-30 Thread Hannes Schulz
Hi everyone,

when I put my agenda in column mode, I would like to change
efforts and the like. 

When I do some action it instantly drops out of column mode.

I'm using  org-mode from git 7.9 (release_7.9-163-gdfe33f).

The same phenomenon occurs with a minimal config:


% - minimal-org.el -
(setq debug-on-error t
debug-on-signal nil
debug-on-quit nil)
(add-to-list 'load-path ~/checkout/git/org-mode/lisp)
(require 'org-install)

% - minimal.org -
#+PROPERTY: Effort_ALL 0 0:10 0:30 1:00 2:00 3:00 4:00 5:00 6:00 7:00
#+COLUMNS: %40ITEM(Task) %17Effort(Estimated Effort){:} %CLOCKSUM
* Heading
** TODO Task 1
   SCHEDULED: 2012-08-30 Do
** date
   2012-08-30 Do

%end

I run like this:

$ emacs -Q -l minimal-org.el minimal.org

then I add minimal.org to the agenda files, create the agenda, put it in column
mode, and use shift-right in the effort column.

This yields the following backtrace:

Debugger entered--Lisp error: (error Marker does not point anywhere)
  goto-char(#marker in no buffer)
  (save-excursion (goto-char beg) (setq end (condition-case nil ... ...)) 
(goto-char end) (while (re-search-backward re beg t) (setq sumpos ... 
last-level ... level ... val ... valflag ...) (cond ... ... ...)))
  (let* ((re org-outline-regexp-bol) (lmax 30) (lvals ...) (lflag ...) (level 
0) (ass ...) (format ...) (printf ...) (fun ...) (calc ...) (beg 
org-columns-top-level-marker) (inminlevel org-inlinetask-min-level) (last-level 
org-inlinetask-min-level) val valflag flag end sumpos sum-alist sum str str1 
useval) (save-excursion (goto-char beg) (setq end ...) (goto-char end) (while 
... ... ...)))
  org-columns-compute(Effort)
  (cond ((equal ... CLOCKSUM) (org-clock-sum)) ((equal ... CLOCKSUM_T) 
(org-clock-sum-today)) ((and ... ... ...) (org-columns-compute ...)))
  (while (setq fm (pop fmt)) (cond (... ...) (... ...) (... ...)))
  (save-restriction (widen) (org-unmodified (remove-text-properties ... ... 
...)) (goto-char (point-min)) (org-columns-get-format-and-top-level) (while 
(setq fm ...) (cond ... ... ...)))
  (save-excursion (save-restriction (widen) (org-unmodified ...) (goto-char 
...) (org-columns-get-format-and-top-level) (while ... ...)))
  (save-current-buffer (set-buffer (or ... b)) (save-excursion 
(save-restriction ... ... ... ... ...)))
  (with-current-buffer (or (buffer-base-buffer b) b) (save-excursion 
(save-restriction ... ... ... ... ...)))
  (while (setq f (pop files)) (setq b (find-buffer-visiting f)) 
(with-current-buffer (or ... b) (save-excursion ...)))
  (let ((files org-agenda-contributing-files) (org-columns-begin-marker ...) 
(org-columns-top-level-marker ...) f fm a b) (while (setq f ...) (setq b ...) 
(with-current-buffer ... ...)))
  org-agenda-colview-compute(((ITEM Task 40 nil nil nil + nil) (Effort 
Estimated Effort 17 : add_times nil + nil) (CLOCKSUM CLOCKSUM nil nil 
nil nil + nil)))
  (progn (org-agenda-colview-compute org-columns-current-fmt-compiled))
  (if org-agenda-columns-compute-summary-properties (progn 
(org-agenda-colview-compute org-columns-current-fmt-compiled)))
  (when org-agenda-columns-compute-summary-properties 
(org-agenda-colview-compute org-columns-current-fmt-compiled))
  (let ((org-columns-time ...) cache maxwidths m p a d fmt) (cond (... ... ...) 
(... ...) (... ...) (... ... ...)) (setq fmt (or fmt 
org-columns-default-format)) (org-set-local (quote org-columns-current-fmt) 
fmt) (org-columns-compile-format fmt) (when 
org-agenda-columns-compute-summary-properties (org-agenda-colview-compute 
org-columns-current-fmt-compiled)) (save-excursion (goto-char ...) (while ... 
... ...) (when cache ... ... ... ... ... ...)))
  org-agenda-columns()
  call-interactively(org-agenda-columns nil nil)

cheers,

-Hannes