Re: [PATCH] ob-sql.el: Add support for SAP HANA
Hi, thank you very much for you feedback. Kyle Meyer wrote: >> This patch is large enough that copyright should be assigned to the FSF. >> Assuming you haven't already, are you willing to complete the copyright >> paperwork? I did this before sending the patch. >> It looks like many of the lines are corrupted by additional line breaks, >> so it'd take a lot of manual editing to resolve the issues on my end. I addressed your points and added the patch as an attachment to avoid potential issues. + (mapconcat #'identity + (delq nil + (list (when (and host port) (format "-n %s:%s" host port)) >> Please prefer `and' here and in other spots where the return value is of >> interest. >> (and host port (format ...)) I used `when' for consistency, as all the other methods are using it, but I don't mind changing it to `and'. 0001-ob-sql.el-Add-support-for-SAP-HANA.patch Description: Binary data
Re: [PATCH] ob-sql.el: Add support for SAP HANA
Hi, could someone please let me know if something is missing/incorrect? If everything should be fine, is there anything still required from my side to include this patch? I couldn't find anything else in the contributor guide. Thanks and best regards, Robin On Thu, 4 Feb 2021 at 08:55, Robin Campbell Joy wrote: > * lisp/ob-sql.el (org-babel-execute:sql, org-babel-sql-dbstring-saphana): > Add basic support for SAP HANA to SQL blocks > * testing/lisp/test-ob-sql.el: Basic tests for generated db connection > string > > This change adds basic support for SAP HANA to SQL blocks by > specifying saphana as :engine. > > It also adds a new header arg `dbinstance' in order to specify the SAP > HANA instance to connect to. > > Signed-off-by: Robin Campbell Joy > --- > lisp/ob-sql.el | 25 ++- > testing/lisp/test-ob-sql.el | 382 > 2 files changed, 406 insertions(+), 1 deletion(-) > create mode 100644 testing/lisp/test-ob-sql.el > > diff --git a/lisp/ob-sql.el b/lisp/ob-sql.el > index 902194ae8..5398c85aa 100644 > --- a/lisp/ob-sql.el > +++ b/lisp/ob-sql.el > @@ -40,6 +40,7 @@ > ;; - dbuser > ;; - dbpassword > ;; - dbconnection (to reference connections in sql-connection-alist) > +;; - dbinstance > ;; - database > ;; - colnames (default, nil, means "yes") > ;; - result-params > @@ -58,6 +59,7 @@ > ;; - postgresql (postgres) > ;; - oracle > ;; - vertica > +;; - saphana > ;; > ;; TODO: > ;; > @@ -85,6 +87,7 @@ > (dbport . :any) > (dbuser . :any) > (dbpassword . :any) > +(dbinstance . :any) > (database . :any)) >"SQL-specific header arguments.") > > @@ -174,6 +177,18 @@ SQL Server on Windows and Linux platform." >(when database (format "-d %s" database >" ")) > > +(defun org-babel-sql-dbstring-saphana (host port instance user password > database) > + "Make SAP HANA command line args for database connection. Pass nil to > omit that arg." > + (mapconcat #'identity > + (delq nil > + (list (when (and host port) (format "-n %s:%s" host > port)) > + (when (and host (not port)) (format "-n %s" > host)) > + (when instance (format "-i %d" instance)) > + (when user (format "-u %s" user)) > + (when password (format "-p %s" > (shell-quote-argument password))) > + (when database (format "-d %s" database > + " ")) > + > (defun org-babel-sql-convert-standard-filename (file) >"Convert FILE to OS standard file name. > If in Cygwin environment, uses Cygwin specific function to > @@ -197,6 +212,7 @@ database connections." > (:dbport . sql-port) > (:dbuser . sql-user) > (:dbpassword . sql-password) > + (:dbinstance . sql-dbinstance) > (:database . sql-database))) > (mapped-name (cdr (assq name name-mapping > (cadr (assq mapped-name > @@ -212,6 +228,7 @@ This function is called by > `org-babel-execute-src-block'." > (dbport (org-babel-find-db-connection-param params :dbport)) > (dbuser (org-babel-find-db-connection-param params :dbuser)) > (dbpassword (org-babel-find-db-connection-param params > :dbpassword)) > + (dbinstance (org-babel-find-db-connection-param params > :dbinstance)) > (database (org-babel-find-db-connection-param params :database)) > (engine (cdr (assq :engine params))) > (colnames-p (not (equal "no" (cdr (assq :colnames params) > @@ -276,6 +293,12 @@ footer=off -F \"\t\" %s -f %s -o %s %s" >dbhost dbport dbuser dbpassword database) > (org-babel-process-file-name in-file) > (org-babel-process-file-name out-file))) > +(saphana (format "hdbsql %s -I %s -o %s %s" > + (org-babel-sql-dbstring-saphana > + dbhost dbport dbinstance dbuser dbpassword database) > + (org-babel-process-file-name in-file) > + (org-babel-process-file-name out-file) > + (or cmdline ""))) > (t (user-error "No support for the %s SQL engine" > engine) > (with-temp-file in-file >(insert > @@ -309,7 +332,7 @@ SET COLSEP '|' > (progn (insert-file-contents-literally out-file) (buffer-string)))
[PATCH] ob-sql.el: Add support for SAP HANA
* lisp/ob-sql.el (org-babel-execute:sql, org-babel-sql-dbstring-saphana): Add basic support for SAP HANA to SQL blocks * testing/lisp/test-ob-sql.el: Basic tests for generated db connection string This change adds basic support for SAP HANA to SQL blocks by specifying saphana as :engine. It also adds a new header arg `dbinstance' in order to specify the SAP HANA instance to connect to. Signed-off-by: Robin Campbell Joy --- lisp/ob-sql.el | 25 ++- testing/lisp/test-ob-sql.el | 382 2 files changed, 406 insertions(+), 1 deletion(-) create mode 100644 testing/lisp/test-ob-sql.el diff --git a/lisp/ob-sql.el b/lisp/ob-sql.el index 902194ae8..5398c85aa 100644 --- a/lisp/ob-sql.el +++ b/lisp/ob-sql.el @@ -40,6 +40,7 @@ ;; - dbuser ;; - dbpassword ;; - dbconnection (to reference connections in sql-connection-alist) +;; - dbinstance ;; - database ;; - colnames (default, nil, means "yes") ;; - result-params @@ -58,6 +59,7 @@ ;; - postgresql (postgres) ;; - oracle ;; - vertica +;; - saphana ;; ;; TODO: ;; @@ -85,6 +87,7 @@ (dbport . :any) (dbuser . :any) (dbpassword . :any) +(dbinstance . :any) (database . :any)) "SQL-specific header arguments.") @@ -174,6 +177,18 @@ SQL Server on Windows and Linux platform." (when database (format "-d %s" database " ")) +(defun org-babel-sql-dbstring-saphana (host port instance user password database) + "Make SAP HANA command line args for database connection. Pass nil to omit that arg." + (mapconcat #'identity + (delq nil + (list (when (and host port) (format "-n %s:%s" host port)) + (when (and host (not port)) (format "-n %s" host)) + (when instance (format "-i %d" instance)) + (when user (format "-u %s" user)) + (when password (format "-p %s" (shell-quote-argument password))) + (when database (format "-d %s" database + " ")) + (defun org-babel-sql-convert-standard-filename (file) "Convert FILE to OS standard file name. If in Cygwin environment, uses Cygwin specific function to @@ -197,6 +212,7 @@ database connections." (:dbport . sql-port) (:dbuser . sql-user) (:dbpassword . sql-password) + (:dbinstance . sql-dbinstance) (:database . sql-database))) (mapped-name (cdr (assq name name-mapping (cadr (assq mapped-name @@ -212,6 +228,7 @@ This function is called by `org-babel-execute-src-block'." (dbport (org-babel-find-db-connection-param params :dbport)) (dbuser (org-babel-find-db-connection-param params :dbuser)) (dbpassword (org-babel-find-db-connection-param params :dbpassword)) + (dbinstance (org-babel-find-db-connection-param params :dbinstance)) (database (org-babel-find-db-connection-param params :database)) (engine (cdr (assq :engine params))) (colnames-p (not (equal "no" (cdr (assq :colnames params) @@ -276,6 +293,12 @@ footer=off -F \"\t\" %s -f %s -o %s %s" dbhost dbport dbuser dbpassword database) (org-babel-process-file-name in-file) (org-babel-process-file-name out-file))) +(saphana (format "hdbsql %s -I %s -o %s %s" + (org-babel-sql-dbstring-saphana + dbhost dbport dbinstance dbuser dbpassword database) + (org-babel-process-file-name in-file) + (org-babel-process-file-name out-file) + (or cmdline ""))) (t (user-error "No support for the %s SQL engine" engine) (with-temp-file in-file (insert @@ -309,7 +332,7 @@ SET COLSEP '|' (progn (insert-file-contents-literally out-file) (buffer-string))) (with-temp-buffer (cond - ((memq (intern engine) '(dbi mysql postgresql postgres sqsh vertica)) + ((memq (intern engine) '(dbi mysql postgresql postgres saphana sqsh vertica)) ;; Add header row delimiter after column-names header in first line (cond (colnames-p diff --git a/testing/lisp/test-ob-sql.el b/testing/lisp/test-ob-sql.el new file mode 100644 index 0..51edd2309 --- /dev/null +++ b/testing/lisp/test-ob-sql.el @@ -0,0 +1,382 @@ +;;; test-ob-sql.el --- tests for ob-sql.el + +;; Copyright (C) 2021 Robin Joy + +;; Author: Robin Joy +;; Keywords: lisp + +;; This program is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation, either version 3 of the License, or +;; (at your option)
[PATCH] ob-sql.el: Add support for SAP HANA
* lisp/ob-sql.el (org-babel-execute:sql, org-babel-sql-dbstring-saphana): Add basic support for SAP HANA to SQL blocks * testing/lisp/test-ob-sql.el: Basic tests for generated db connection string This change adds basic support for SAP HANA to SQL blocks by specifying saphana as :engine. It also adds a new header arg `dbinstance' in order to specify the SAP HANA instance to connect to. Signed-off-by: Robin Campbell Joy --- lisp/ob-sql.el | 25 ++- testing/lisp/test-ob-sql.el | 382 2 files changed, 406 insertions(+), 1 deletion(-) create mode 100644 testing/lisp/test-ob-sql.el diff --git a/lisp/ob-sql.el b/lisp/ob-sql.el index 902194ae8..5398c85aa 100644 --- a/lisp/ob-sql.el +++ b/lisp/ob-sql.el @@ -40,6 +40,7 @@ ;; - dbuser ;; - dbpassword ;; - dbconnection (to reference connections in sql-connection-alist) +;; - dbinstance ;; - database ;; - colnames (default, nil, means "yes") ;; - result-params @@ -58,6 +59,7 @@ ;; - postgresql (postgres) ;; - oracle ;; - vertica +;; - saphana ;; ;; TODO: ;; @@ -85,6 +87,7 @@ (dbport . :any) (dbuser . :any) (dbpassword . :any) +(dbinstance . :any) (database . :any)) "SQL-specific header arguments.") @@ -174,6 +177,18 @@ SQL Server on Windows and Linux platform." (when database (format "-d %s" database " ")) +(defun org-babel-sql-dbstring-saphana (host port instance user password database) + "Make SAP HANA command line args for database connection. Pass nil to omit that arg." + (mapconcat #'identity + (delq nil + (list (when (and host port) (format "-n %s:%s" host port)) + (when (and host (not port)) (format "-n %s" host)) + (when instance (format "-i %d" instance)) + (when user (format "-u %s" user)) + (when password (format "-p %s" (shell-quote-argument password))) + (when database (format "-d %s" database + " ")) + (defun org-babel-sql-convert-standard-filename (file) "Convert FILE to OS standard file name. If in Cygwin environment, uses Cygwin specific function to @@ -197,6 +212,7 @@ database connections." (:dbport . sql-port) (:dbuser . sql-user) (:dbpassword . sql-password) + (:dbinstance . sql-dbinstance) (:database . sql-database))) (mapped-name (cdr (assq name name-mapping (cadr (assq mapped-name @@ -212,6 +228,7 @@ This function is called by `org-babel-execute-src-block'." (dbport (org-babel-find-db-connection-param params :dbport)) (dbuser (org-babel-find-db-connection-param params :dbuser)) (dbpassword (org-babel-find-db-connection-param params :dbpassword)) + (dbinstance (org-babel-find-db-connection-param params :dbinstance)) (database (org-babel-find-db-connection-param params :database)) (engine (cdr (assq :engine params))) (colnames-p (not (equal "no" (cdr (assq :colnames params) @@ -276,6 +293,12 @@ footer=off -F \"\t\" %s -f %s -o %s %s" dbhost dbport dbuser dbpassword database) (org-babel-process-file-name in-file) (org-babel-process-file-name out-file))) +(saphana (format "hdbsql %s -I %s -o %s %s" + (org-babel-sql-dbstring-saphana + dbhost dbport dbinstance dbuser dbpassword database) + (org-babel-process-file-name in-file) + (org-babel-process-file-name out-file) + (or cmdline ""))) (t (user-error "No support for the %s SQL engine" engine) (with-temp-file in-file (insert @@ -309,7 +332,7 @@ SET COLSEP '|' (progn (insert-file-contents-literally out-file) (buffer-string))) (with-temp-buffer (cond - ((memq (intern engine) '(dbi mysql postgresql postgres sqsh vertica)) + ((memq (intern engine) '(dbi mysql postgresql postgres saphana sqsh vertica)) ;; Add header row delimiter after column-names header in first line (cond (colnames-p diff --git a/testing/lisp/test-ob-sql.el b/testing/lisp/test-ob-sql.el new file mode 100644 index 0..51edd2309 --- /dev/null +++ b/testing/lisp/test-ob-sql.el @@ -0,0 +1,382 @@ +;;; test-ob-sql.el --- tests for ob-sql.el + +;; Copyright (C) 2021 Robin Joy + +;; Author: Robin Joy +;; Keywords: lisp + +;; This program is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation, either version 3 of the License, or +;; (at your option)
[PATCH] ob-sql.el: Add support for SAP HANA
* lisp/ob-sql.el (org-babel-execute:sql, org-babel-sql-dbstring-saphana): Add basic support for SAP HANA to SQL blocks * testing/lisp/test-ob-sql.el: Basic tests for generated db connection string This change adds basic support for SAP HANA to SQL blocks by specifying saphana as :engine. It also adds a new header arg `dbinstance' in order to specify the SAP HANA instance to connect to. Signed-off-by: Robin Campbell Joy --- lisp/ob-sql.el | 25 ++- testing/lisp/test-ob-sql.el | 382 2 files changed, 406 insertions(+), 1 deletion(-) create mode 100644 testing/lisp/test-ob-sql.el diff --git a/lisp/ob-sql.el b/lisp/ob-sql.el index 902194ae8..5398c85aa 100644 --- a/lisp/ob-sql.el +++ b/lisp/ob-sql.el @@ -40,6 +40,7 @@ ;; - dbuser ;; - dbpassword ;; - dbconnection (to reference connections in sql-connection-alist) +;; - dbinstance ;; - database ;; - colnames (default, nil, means "yes") ;; - result-params @@ -58,6 +59,7 @@ ;; - postgresql (postgres) ;; - oracle ;; - vertica +;; - saphana ;; ;; TODO: ;; @@ -85,6 +87,7 @@ (dbport . :any) (dbuser . :any) (dbpassword . :any) +(dbinstance . :any) (database . :any)) "SQL-specific header arguments.") @@ -174,6 +177,18 @@ SQL Server on Windows and Linux platform." (when database (format "-d %s" database " ")) +(defun org-babel-sql-dbstring-saphana (host port instance user password database) + "Make SAP HANA command line args for database connection. Pass nil to omit that arg." + (mapconcat #'identity + (delq nil + (list (when (and host port) (format "-n %s:%s" host port)) + (when (and host (not port)) (format "-n %s" host)) + (when instance (format "-i %d" instance)) + (when user (format "-u %s" user)) + (when password (format "-p %s" (shell-quote-argument password))) + (when database (format "-d %s" database + " ")) + (defun org-babel-sql-convert-standard-filename (file) "Convert FILE to OS standard file name. If in Cygwin environment, uses Cygwin specific function to @@ -197,6 +212,7 @@ database connections." (:dbport . sql-port) (:dbuser . sql-user) (:dbpassword . sql-password) + (:dbinstance . sql-dbinstance) (:database . sql-database))) (mapped-name (cdr (assq name name-mapping (cadr (assq mapped-name @@ -212,6 +228,7 @@ This function is called by `org-babel-execute-src-block'." (dbport (org-babel-find-db-connection-param params :dbport)) (dbuser (org-babel-find-db-connection-param params :dbuser)) (dbpassword (org-babel-find-db-connection-param params :dbpassword)) + (dbinstance (org-babel-find-db-connection-param params :dbinstance)) (database (org-babel-find-db-connection-param params :database)) (engine (cdr (assq :engine params))) (colnames-p (not (equal "no" (cdr (assq :colnames params) @@ -276,6 +293,12 @@ footer=off -F \"\t\" %s -f %s -o %s %s" dbhost dbport dbuser dbpassword database) (org-babel-process-file-name in-file) (org-babel-process-file-name out-file))) +(saphana (format "hdbsql %s -I %s -o %s %s" + (org-babel-sql-dbstring-saphana + dbhost dbport dbinstance dbuser dbpassword database) + (org-babel-process-file-name in-file) + (org-babel-process-file-name out-file) + (or cmdline ""))) (t (user-error "No support for the %s SQL engine" engine) (with-temp-file in-file (insert @@ -309,7 +332,7 @@ SET COLSEP '|' (progn (insert-file-contents-literally out-file) (buffer-string))) (with-temp-buffer (cond - ((memq (intern engine) '(dbi mysql postgresql postgres sqsh vertica)) + ((memq (intern engine) '(dbi mysql postgresql postgres saphana sqsh vertica)) ;; Add header row delimiter after column-names header in first line (cond (colnames-p diff --git a/testing/lisp/test-ob-sql.el b/testing/lisp/test-ob-sql.el new file mode 100644 index 0..51edd2309 --- /dev/null +++ b/testing/lisp/test-ob-sql.el @@ -0,0 +1,382 @@ +;;; test-ob-sql.el --- tests for ob-sql.el + +;; Copyright (C) 2021 Robin Joy + +;; Author: Robin Joy +;; Keywords: lisp + +;; This program is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation, either version 3 of the License, or +;; (at your option)
Re: [O] org-mode failing on org-mobile-push with error
hi Jeff, I have the same behaviour. did you find any solution. br robin
[O] expand view for all items in sparse tree
hello does anyone know if there is a possibility to expand all items including list items in a sparse tree for a certain tag to export only the visible to eg latex? my steps are: - C-c / :MYTAG now all headlines with the tag are shown. That's fine. But now I can only cycle the visibility of one of the sparse tree's branches and not all of them so I get something like * Item :MYTAG - [X] do this - [ ] do that * Item2 :MYTAG (hidden -[ ] do this as well) <--- but I would like to export this as well... any shortcuts I have missed so far? best regards robin
[Orgmode] bug#7459: 23.2; "Salutation" should not actually be included in bug mails
At Mon, 22 Nov 2010 01:51:08 -0500, Glenn Morris wrote: > Are you asking for the addition of a general, optional feature to > reporter.el, or asking specifically about Org mode? (Presumably the > former else you would have used... M-x org-submit-bug-report.) The former, yes. > Either way, it is a very low priority request. M-x report-emacs-bug > has supposedly had this feature for a long time, yet people often > defeat it somehow (as you did in this report). I didn't intentionally defeat it. I use wanderlust - that's probably why. > It's never seemed very > important. OK, I'll just delete the salutation myself in future. -- Robin ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Bugs in ob-haskell
I've noticed a number of bugs in ob-haskell: 1. The first time I ran my code block, the results were given as something like: Prelude> [[1], [2], [3]] and of course, this isn't an org table, as it should be. I don't think the "Prelude> " should have been there, and I suspect a race condition, because after I immediately did C-c C-c again, the results changed to a table. 2. Looking at ob-haskell.el, it seems like Haskell strings are converted into text by removing leading and trailing double quotes. However, if there are double quote characters inside the string, they will be escaped with a backslash when printed, and they will presumably need to be unescaped. (Haven't tested this though.) 3. Ordinary Haskell lists can't have values of different types inside them, at least not without some sort of wrapper. But if you have a number and a string in your table, ob-haskell will try to make an impossible list with a number and a string in it. My preferred solution to this bug would be to force all list items to strings (at least, if there are any strings at all in the input table or list). 4. What's worse is, if ob-haskell makes an error in setting your input variables, like the error in the previous paragraph, and this is not the first run of that code block and you haven't changed the variable names, the error arising from the "let" command will simply be ignored silently by ob-haskell! The previous value of the variable will be used instead. At least, that is what happens to me. Regards, -- Robin Green ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Re: Bug: Initial C-c ' invocation just starts haskell-mode "normally" [7.3]
At Sat, 20 Nov 2010 13:37:36 +, Robin Green wrote: > I am experimenting with source code blocks, and I tried to use C-c ' to > type in some Haskell code. The first time I tried it, I was asked for a > filename, which was puzzling, because I didn't expect that. OK, I now have a clearer idea of what went wrong. 1. I think it's doing find-file-at-point. 2. This only happens when point is on this line, but NOT at the start of the line: #+begin_src haskell It's not about whether it's the first time you press C-c ', it's about where point is when you press it. 3. If point is anywhere on the closing line of the source block, it works. 4. Ironically, the end of the first line is where the point is placed if you do C-c C-v d at the end of the buffer! So if you do C-c C-v d and then C-c ', as I did, this bug will happen. -- Robin ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Bug: Initial C-c ' invocation just starts haskell-mode "normally" [7.3]
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 http://orgmode.org/manual/Feedback.html#Feedback Your bug report will be posted to the Org-mode mailing list. I am experimenting with source code blocks, and I tried to use C-c ' to type in some Haskell code. The first time I tried it, I was asked for a filename, which was puzzling, because I didn't expect that. I entered "t.hs" and pressed Enter, and that took me to an apparently "normal" haskell-mode buffer, in which C-c ' to finish and C-x C-s to update didn't have any effect on the original org-mode buffer. When I went back to the org-mode buffer and tried again, it basically worked that time as expected (except that I think it should have put a newline before the code in org-mode - but that's a different bug, if it is a bug!) Emacs : GNU Emacs 23.2.1 (i686-pc-linux-gnu, GTK+ Version 2.22.0) of 2010-11-18 on cspcnh.swan.ac.uk Package: Org-mode version 7.3 current state: == (setq org-export-latex-after-initial-vars-hook '(org-beamer-after-initial-vars) org-speed-command-hook '(org-speed-command-default-hook org-babel-speed-command-hook) org-blocker-hook '(org-block-todo-from-checkboxes org-block-todo-from-children-or-siblings-or-parent) org-babel-load-languages '((emacs-lisp . t) (python . t) (sh . t) (dot . t) (sql . t) (haskell . t)) org-metaup-hook '(org-babel-load-in-session-maybe) org-after-todo-state-change-hook '(org-clock-out-if-current) org-babel-tangle-lang-exts '(("haskell" . "hs") ("python" . "py") ("emacs-lisp" . "el")) org-startup-folded 'showeverything org-export-blocks-postblock-hook '(org-exp-res/src-name-cleanup) org-export-latex-format-toc-function 'org-export-latex-format-toc-default org-tab-first-hook '(org-hide-block-toggle-maybe org-src-native-tab-command-maybe org-babel-hide-result-toggle-maybe) org-src-mode-hook '(org-src-babel-configure-edit-buffer org-src-mode-configure-edit-buffer) org-confirm-shell-link-function 'yes-or-no-p org-export-first-hook '(org-beamer-initialize-open-trackers) org-todo-keywords '((sequence "IDEA" "ASSESS" "DEFER" "TODO" "TO_REPORT" "DONE")) org-agenda-before-write-hook '(org-agenda-add-entry-text) org-babel-pre-tangle-hook '(save-buffer) org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers org-cycle-show-empty-lines org-optimize-window-after-visibility-change) org-export-preprocess-before-normalizing-links-hook '(org-remove-file-link-modifiers) org-mode-hook '(#[nil "\300\301\302\303\304$\207" [org-add-hook change-major-mode-hook org-show-block-all append local] 5] #[nil "\300\301\302\303\304$\207" [org-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-ctrl-c-ctrl-c-hook '(org-babel-hash-at-point org-babel-execute-safely-maybe) org-return-follows-link t org-confirm-elisp-link-function 'yes-or-no-p org-export-interblocks '((lob org-babel-exp-lob-one-liners) (src org-babel-exp-inline-src-blocks)) org-enforce-todo-dependencies t org-occur-hook '(org-first-headline-recenter) org-export-preprocess-before-selecting-backend-code-hook '(org-beamer-select-beamer-code) org-export-preprocess-after-include-files-hook '(org-export-blocks-preprocess) org-export-latex-final-hook '(org-beamer-amend-header org-beamer-fix-toc org-beamer-auto-fragile-frames org-beamer-place-default-actions-for-lists) org-enforce-todo-checkbox-dependencies t org-metadown-hook '(org-babel-pop-to-session-maybe) org-export-blocks '((src org-babel-exp-src-blocks nil) (comment org-export-blocks-format-comment t) (ditaa org-export-blocks-format-ditaa nil) (dot org-export-blocks-format-dot nil)) ) ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] Heirarchy and indenting of plain text belonging to headline of same indent
Ah, thanks Stephan. I now see this is a problem with outline.el which orgmode is based on. However, orgmode export does it's own processing, so this would need changing in both places to work properly. So I shall give up and work around it for now. Cheers, Robin On 20/05/10 12:11, Stephan Schmitt wrote: Hi Robin, No, there is no possibility to return to a higher level without a new headline. The concept of book chapters and sections is here more appropriate than code blocks. Although this restricts somewhat the flexibility of the outline structure, it is unlikely to be changed in the future. If you need the embedded /Head 2/ block for a todo task, you can use inline tasks as a workaround (look it up in the manual). There are also some other threads in the mail archive of this list discussing this problem. Hth, Stephan Also sprach Robin Message: Dear list, I'm just getting started with orgmode and it seems to do exactly what I need for outlining except for one thing - text always belongs to the headline immediately above it. I would like text to belong to the headline above it that it is indented to. Sort of like how blocks of code are handled in Python. As an example, given the text (assuming odd levels only) * Head 1 Body 1 *** Head 2 Body 2 More Body 1 Head 1 should fold to: * Head 1 Body 1 *** Head 2... More Body 1 At the moment, head 1 would fold to * Head 1 Body 1 *** Head 2... But more body 1 is missing. Is there any way to get it handled as belonging to * Head 1, not *** Head 2? Alternatively, is there some kind of headline ending command or some way of easily adding one, e.g. * Head 1 Body 1 *** Head 2 Body 2 ***$ More Body 1 Thanks, Robin Message ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Heirarchy and indenting of plain text belonging to headline of same indent
Dear list, I'm just getting started with orgmode and it seems to do exactly what I need for outlining except for one thing - text always belongs to the headline immediately above it. I would like text to belong to the headline above it that it is indented to. Sort of like how blocks of code are handled in Python. As an example, given the text (assuming odd levels only) * Head 1 Body 1 *** Head 2 Body 2 More Body 1 Head 1 should fold to: * Head 1 Body 1 *** Head 2... More Body 1 At the moment, head 1 would fold to * Head 1 Body 1 *** Head 2... But more body 1 is missing. Is there any way to get it handled as belonging to * Head 1, not *** Head 2? Alternatively, is there some kind of headline ending command or some way of easily adding one, e.g. * Head 1 Body 1 *** Head 2 Body 2 ***$ More Body 1 Thanks, Robin Message ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Bug: Column mode breaks beamer export [6.33trans]
After I enable "column view of properties" in the attached file, export to PDF via LaTeX fails with the following error in the minibuffer: org-export-as-latex: Text is read-only: "Type `e' to edit property" Emacs : GNU Emacs 23.1.50.1 (i486-pc-linux-gnu, GTK+ Version 2.18.0) of 2009-09-27 on palmer, modified by Debian Package: Org-mode version 6.33trans current state: == (setq org-export-latex-after-initial-vars-hook '(org-beamer-after-initial-vars) org-agenda-files '("/src/greenrd/org") org-blocker-hook '(org-block-todo-from-checkboxes org-block-todo-from-children-or-siblings-or-parent) org-checklist-export-function 'org-export-as-ascii org-after-todo-state-change-hook '(org-clock-out-if-current org-checklist) org-agenda-todo-ignore-scheduled t org-startup-folded nil org-agenda-sorting-strategy '((agenda time-up priority-down effort-up category-keep) (todo priority-down effort-up category-keep) (tags priority-down effort-up category-keep) (search category-keep)) org-agenda-prefix-format '((agenda . " %-12:c%-12:T%?-12t% s") (timeline . " % s") (todo . " %-12:c") (tags . " %-12:c") (search . " %-12:c")) org-deadline-warning-days 900 org-export-latex-format-toc-function 'org-export-latex-format-toc-default org-agenda-skip-scheduled-if-done t org-export-preprocess-hook '(org-export-blocks-preprocess) org-tab-first-hook '(org-hide-block-toggle-maybe) org-src-mode-hook '(org-src-mode-configure-edit-buffer) org-confirm-shell-link-function 'yes-or-no-p org-export-first-hook '(org-beamer-initialize-open-trackers) org-todo-keywords '((sequence "TODO(t)" "QUESTION(q)" "PLANNING(p)" "PENDING(e)" "STARTED(s)" "FINISHING(f)" "|" "DONE(d)" "OBSOLETE(o)") ) org-agenda-before-write-hook '(org-agenda-add-entry-text) org-default-notes-file "/src/greenrd/org/remember.org" org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers org-cycle-show-empty-lines org-optimize-window-after-visibility-change) org-mode-hook '(#[nil "\300\301\302\303\304$\207" [org-add-hook change-major-mode-hook org-show-block-all append local] 5] ) org-global-properties '(("Effort_ALL" . "0 0:10 0:30 1:00 2:00 3:00 4:00 5:00 6:00 7:00 8:00")) org-return-follows-link t org-confirm-elisp-link-function 'yes-or-no-p org-beamer-environments-extra '(("figure" "F" "\\begin{figure}" "\\end{figure}")) org-agenda-todo-ignore-with-date t org-enforce-todo-dependencies t org-occur-hook '(org-first-headline-recenter) org-priority-start-cycle-with-default nil org-export-preprocess-before-selecting-backend-code-hook '(org-beamer-select-beamer-code) org-agenda-todo-ignore-deadlines t org-modules '(org-bbdb org-bibtex org-gnus org-info org-jsinfo org-irc org-mew org-mhe org-rmail org-vm org-wl org-w3m org-checklist org-interactive-query org-man org-registry) org-remember-templates '(("Web link" 119 "* %u %c \n\n%:region\n" nil "Web links" nil)) org-export-latex-final-hook '(org-beamer-amend-header org-beamer-fix-toc org-beamer-auto-fragile-frames org-beamer-place-default-actions-for-lists) org-enforce-todo-checkbox-dependencies t org-lowest-priority 70 ) #+STARTUP: beamer #+TITLE: Cohere: Towards Web 2.0 Argumentation #+AUTHOR: Simon Buckingham Shum #+LaTeX_CLASS: beamer #+LaTeX_CLASS_OPTIONS: [presentation] #+BEAMER_FRAME_LEVEL: 2 #+BEAMER_HEADER_EXTRA: \usetheme{Szeged}\usecolortheme{wolverine}\institute{Knowledge Media Institute, The Open University, UK} #+COLUMNS: %45ITEM %10BEAMER_env(Env) %10BEAMER_envargs(Env Args) %4BEAMER_col(Col) %8BEAMER_extra(Extra) #+PROPERTY: BEAMER_col_ALL 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0 :ETC * Context ** What is argumentation software? *** *mapping* an argument :BMCOL: :PROPERTIES: :BEAMER_col: 0.5 :BEAMER_envargs: C[T] :END: exposing its structure * typically in graph form *** for the purposes of this talk # I was going to say "typically" here, but I've only read 4-5 papers # in this area, so I can't be sure that it's typical. But that's how # it seems to me. *manual* data entry * not extraction can relate back to sources * links * video timestamps *** :B_figure:BMCOL: :BMCOL:B_figure: :PROPERTIES: :BEAMER_col: 0.5 :BEAMER_env: figure :END: \includegraphics[width=.7\columnwidth]{What_the_Bible_says.jpg} *** optionally *queries* for sub-arguments *multiple* I/O styles * directed graph * textual outline *collaborative editing* ** Why use argumentation software? *** example: climate change debates *** large and complex *** interdisciplinary science politics economics ethics *** timely Co
Re: [Orgmode] Emacs snapshot needed for something?
At Mon, 7 Dec 2009 14:35:41 +0530, Manish wrote: > > http://thread.gmane.org/gmane.emacs.orgmode/16742 Awesome, that was it, thanks! ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] Emacs snapshot needed for something?
At Mon, 7 Dec 2009 14:00:04 +0530, Manish wrote: > > On Mon, Dec 7, 2009 at 5:17 AM, Robin Green wrote: > > Hi all, > > > > I seem to remember Carsten saying that a snapshot version of emacs > > from CVS was recommended for some new org-mode feature, because emacs > > 23.1 is buggy, but now I can't find that email again. Is my memory > > playing tricks on me? > > Is this what you are looking for? > > http://thread.gmane.org/gmane.emacs.orgmode/20274/focus=20299 Actually, no - it was definitely an earlier email. But that's useful - thanks. -- Robin ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Emacs snapshot needed for something?
Hi all, I seem to remember Carsten saying that a snapshot version of emacs from CVS was recommended for some new org-mode feature, because emacs 23.1 is buggy, but now I can't find that email again. Is my memory playing tricks on me? -- Robin ___ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] adding new protocol handler in firefox
At Thu, 19 Nov 2009 21:09:21 +0100, Sebastian Rose wrote: > Well, anyway, editing RDF files by hand is not the way to go. Indeed. This was the method that worked for me (thanks to "goncheff" for discovering it): 1. In about:config, create a boolean key "network.protocol-handler.expose.org-protocol" and set it to False 2. Create a simple web page containing a link to the URL org-protocol://test 3. Open the web page you just created 4. Click on the link 5. Choose emacsclient as the associated application in the dialog box that appears and no other method worked (although I didn't know about the "edit the RDF file" method). It isn't, of course, necessary to create a web page - you can use an existing one with such a link - but it *is* necessary to click on a link in a web page - selecting a bookmarklet no longer works in the latest Firefox release, at least on Ubuntu 9.10 and on Mac OS X, and probably elsewhere too. -- cut here -- I guess I should create a patch to worg to include the above instructions for newer versions of Firefox. Unless people think the RDF editing method is better? > Instead, we should link to descriptions on how install the handlers > system wide. Nice idea, but unfortunately on Linux (as far as I know) there is no standard way to do that. -- Robin ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] Holidays command
At Thu, 15 Oct 2009 05:26:01 -0700 (PDT), Giovanni Ridolfi wrote: > I think you did not activate the calendar-diary integration > as suggested in the manual: > > 10.3.1 The weekly/daily agenda > > (setq org-agenda-include-diary t) > > did you? Fair enough, I didn't. But I think a more user-friendly error message should be shown. It's normal to want to explore a program in this way. -- Robin ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Holidays command
I tried using the H key in the agenda to see what it did, and got this error message: org-agenda-execute-calendar-command: Wrong type argument: commandp, list-calendar-holidays I'm using org-mode 6.31. -- Robin ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] Re: Emacs23 Menus "Org" and "Tbl" empty
At Tue, 06 Oct 2009 17:16:47 +0200, Benjamin Andresen wrote: > Might be a shot in the dark, but: (Only applicable if you use the gtk > version of Emacs) > > gtk 2.18 changed a few things but gtk 2.16 should work from the > get-go. > http://library.gnome.org/devel/gtk/unstable/gtk-migrating-ClientSideWindows.html > > There you can see that you could try exporting GDK_NATIVE_WINDOWS=1 > before running emacs and see if that fixes things. This should work, but it might break apps launched from emacs (e.g. web browsers). Possibly-better solutions include: 1. Build emacs from CVS 2. OR, take the emacs 23.1 source code, apply the patch I posted to the bug report at http://emacsbugs.donarmstrong.com/cgi-bin/bugreport.cgi?bug=4122 and build emacs Again, this is only applicable if you use the GTK version of emacs. -- Robin ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] orgstruct-mode bug: cannot sort region if next line is not a structure element
In orgstruct-mode, if you have these three lines: * TODO in a simulation, it will fail with "Future mempty: it'll never happen, buddy" if there is no ResetCmd :FIXME: * DONE outputs simultaneous with a ResetCmd, *and* the ResetCmds themselves, might be dropped :FIXME: -} and you select the first two lines with the mouse, so that the cursor (point?) is at the start of the third line, and then press C-c ^ to sort them, orgstruct-mode complains that "this key has no function outside structure elements". This is with the org-mode included in emacs 23.1. ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] Including orgstruct-mode files in todo list and agenda
I would like to have files other than .org files, e.g. source code files, with some TODOs in them created by orgstruct-mode, included in todo lists and agendas generated by C-c a. My plan is to create symbolic links in my org directory, with names altered from the original filenames so that they end in .org, pointing to those other files. As the files are plain text and don't contain anything else which could be mistaken for a TODO entry or whatever, I think this should work. Will this work reliably? -- Robin ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
[Orgmode] (no subject)
Is there any equivalent to planner-mode's planner-rank.el for org-mode? I want to automatically compute some sort of combined measure of urgency and importance for each of my TODOs, and rank them according to this measure. (Of course, I could write my own code to do this, and I might do just that if there isn't anything suitable already out there.) -- Robin ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode
Re: [Orgmode] Windows and emacs
The third way, and the way I do it, is to run a Linux inside Windows. I dropped cygwin on my pc at work and use andLinux now (http://andlinux.org), which is running a linux kernel in a Win32 process (as a service in background). X applications are exported to a local W32 XServer. This is much faster than X apps compiled for cygwin. You'll have clipboard sharing between the Linux and W32 windows, too. This article led me to andLinux: www.techanodyne.com/2007/03/forget-vmware-run-colinux.html Robin On Thu, Jan 8, 2009 at 10:41 PM, Raimund Kohl-Füchsle wrote: > Hi guys, > > it may happen that I have to switch to Windows XP and since I have no > idea how XP works (up to this point in time I only ran Linux machines) I > thought to ask since I want to stick with org-mode: How do I get > org-mode and emacs run best with XP? As far as I know there are at > least two ways to get emacs running; one is to simply download emacs, > two is downloading cygwin; if it is cygwin that I have to go with then > which emacs? If I saw it right there are several choices ... ummm ... > any hints on that? > > Thanx in advance > > ray > > > ___ > Emacs-orgmode mailing list > Remember: use `Reply All' to send replies to the list. > Emacs-orgmode@gnu.org > http://lists.gnu.org/mailman/listinfo/emacs-orgmode > ___ Emacs-orgmode mailing list Remember: use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode