Re: [O] Deactivate babel source block
Eric Schulte writes: > You want to set the :eval and :tangle header arguments, this can be done > with `org-babel-insert-header-arg' bound to "C-c C-v j". I've just > updated this function so that it now takes two optional arguments > specifying the header argument and value. > > So your function could now be something like the following. > > (defun my-org-babel-deactivate () > (interactive) > (org-babel-insert-header-arg "eval" "never") > (org-babel-insert-header-arg "tangle" "no")) Correct me if I am wrong, but I seem to remember that source blocks under a commented heading are not tangled? But I just tried it now, and it doesn't seem to be the case anymore - code blocks under commented header are still tangled - has this feature been removed or was it never there? Rainer > > Hope this helps, > > Michael Bach writes: > >> Dear org-mode Users and Developers, >> >> >> I am looking for a nice way to deactivate a babel source block with >> point being anywhere on it. Imagine e.g. C-c C-v C-w to say "I want to >> toggle execution/tangling for this block". >> >> Background: I have the .emacs setup in a literate org-mode file where I >> am testing new emacs packages. Now many blocks represent specific >> features that I want to be activated / deactivated. This should ideally >> behave like the other source code functions (i.e. C-c C-v family). >> >> My naive approach as elisp noob was: >> #+begin_src emacs-lisp >> (defun my-org-babel-deactivate () >> (interactive) >> (org-edit-special) >> (mark-whole-buffer) >> (comment-region) >> (org-edit-src-exit)) >> #+end_src >> >> Apart from it not working (Wrong number of arguments), this would have >> been a dirty one in any case. Now I thought there must be a better way >> by setting/un-setting the respective header arguments in an automated >> way. Is this already possible with org-mode version 8.2? >> >> Best Regards, >> Michael >> >> <#secure method=pgpmime mode=sign> -- Rainer M. Krug email: RMKruggmailcom
[O] Time remaining report, anyone done it?
Hello all, I have a bit of time now so I am dusting off a slightly buggy way of finding out how much time is remaining on a project. The basic idea is that: :Effort: - [total clocked time] = [time remaining before completion] The ultimate aim is to get a "time remaining report", similar to a "clocked time report". Before I get too stuck in I thought I would ask: Has anyone already done this or thought about a good way to do it (I really hope so)? Myles
[O] Babel: Ada, Smalltalk and Objective-C ?
Is there any support for Ada, Smalltalk and Objective-C that anyone is aware of ? Are there any pointers on how to add such support to Babel ? cheers, mehul -- Mehul N. Sanghvi email: mehul.sang...@gmail.com
[O] capture, attach, link files from web
Hello, Just thought I would share something I find useful. What the code below does is: 1) prompts for a link to a file on the internet 2) downloads the file 3) attaches the file to the current subtree 4) inserts at the current point a link to the attachment This is useful if (e.g.) you are scouring Google images for ideas and want to save lots of image files. Requirements: wget, set $TMPDIR. TODO: integrate properly with capture template #+here_is_some elisp (setq org-link-abbrev-alist '(("att" . org-attach-expand-link))) (defun my-attach-and-link-web-file (lnk) "Download a file, attach it to our heading, insert a link" (interactive "*sAttach and link to url: \n") (let ((tmpdir (expand-file-name (getenv "TMPDIR"))) (fname (file-name-nondirectory lnk))) (progn (message (concat "Downloading " lnk " to " tmpdir "/" fname)) (call-process "wget" nil '("*Messages*" t) nil "-P" tmpdir "-d" lnk) (org-attach-attach (concat tmpdir "/" fname) nil 'mv) (insert (concat "[[att:" fname "]]") (define-key global-map "\C-cs" 'my-attach-and-link-web-file) #+that_was_elisp Myles
Re: [O] capture, attach, link files from web
Hi Myles, I counter your tip with my own on capturing pdfs. Maybe you'll find some of this stuff useful for your case. My capture template captures a pdf file that I have to read. It works for: 1. A pdf file in doc-view mode. 2. Any dired buffer with point on a pdf file. What it does: 1. Create a new TODO item under gtd.org/Projects/Scientific Articles 2. The item title is "Read blah-blah by Foo", if the pdf name has proper format, otherwise it's just "Read blah-blah". 3. The pdf is attached to the TODO item. 4. A note is added with the capture time. Here's the code: (setq org.d "~/Dropbox/org/") (require 'org-attach) (require 'org-capture) (defun org-process-current-pdf () (let* ((buffer (org-capture-get :buffer)) (buffer-mode (with-current-buffer buffer major-mode)) (filename (org-capture-get :original-file))) (when (file-directory-p filename) (with-current-buffer (org-capture-get :original-buffer) (setq filename (dired-get-filename (when (string= (file-name-extension filename) "pdf") (let ((org-attach-directory (concat org.d "data/")) (name (file-name-sans-extension (file-name-nondirectory filename (org-attach-attach filename nil 'cp) (if (string-match "\\[\\(.*\\)\\] \\(.*\\)(\\(.*\\))" name) (format "\"%s\" by %s" (match-string 2 name) (match-string 1 name)) name) (add-to-list 'org-capture-templates '("p" "Pdf article" entry (file+olp (concat org.d "gtd.org") "Projects" "Scientific Articles") "* TODO Read %(org-process-current-pdf)\nAdded: %U %i\n %?\n")) regards, Oleh On Mon, Oct 7, 2013 at 1:49 PM, Myles English wrote: > > Hello, > > Just thought I would share something I find useful. What the code below > does is: > > 1) prompts for a link to a file on the internet > 2) downloads the file > 3) attaches the file to the current subtree > 4) inserts at the current point a link to the attachment > > This is useful if (e.g.) you are scouring Google images for ideas and > want to save lots of image files. > > Requirements: wget, set $TMPDIR. > TODO: integrate properly with capture template > > #+here_is_some elisp > (setq org-link-abbrev-alist '(("att" . org-attach-expand-link))) > > (defun my-attach-and-link-web-file (lnk) > "Download a file, attach it to our heading, insert a link" > (interactive "*sAttach and link to url: \n") > (let ((tmpdir (expand-file-name (getenv "TMPDIR"))) > (fname (file-name-nondirectory lnk))) > (progn (message (concat "Downloading " lnk " to " tmpdir "/" fname)) >(call-process "wget" nil '("*Messages*" t) nil "-P" > tmpdir "-d" > lnk) >(org-attach-attach (concat tmpdir "/" fname) nil 'mv) >(insert (concat "[[att:" fname "]]") > > (define-key global-map "\C-cs" 'my-attach-and-link-web-file) > #+that_was_elisp > > Myles > >
Re: [O] Problem with beamer export
Hello, Marvin Doyley writes: > I just updated to Org 8.2.1 and for some reason when I export a frame I get > > \subsection{Title} > > > rather than > > \begin{frame}{Title} > > \end{frame} > > > Is this a bug or am I doing something wrong ? This is a bug I introduced recently. It should now be fixed. Thank you for reporting it. Regards, -- Nicolas Goaziou
Re: [O] org-mode based groupware wiki
Hi Eric, thanks for the email. I will give org-ehtml a try. Do you still actively maintain it. We would rely rather heavily on it ( a group of about 10 people) and I would be happy to know that I do not ride a dead horse. On the other hand you get a bunch of beta-testers ;) Could you agree with the following comparison: * gollum - standalone application, based on git and org-ruby. - can use different makeup-languages - can be integrated in a larger environment (read something about using Apache Webserver) - enables the creation and editing of pages via webbrowser (a minimal org-mode editor is available) - basic settings of the theme (top, footer, sidebar). * org-ehtml - part of org-mode requires emacs and elnode - makes use of the new exporter - ... ... because I tried to give it a test but it did not work out. I tried a test instance via the following commands (and its outputs) (ert "org-ehtml") -> Selector: "org-ehtml" Passed: 0 Failed: 0 Total: 0/0 Started at: 2013-10-07 16:44:00+0200 Finished. Finished at: 2013-10-07 16:44:00+0200 (setq org-ehtml-docroot "/home/torsten/test-wiki/") -> "/home/torsten/test-wiki/" (elnode-start 'org-ehtml-handler :port ) -> (( . #)) When I start it according to the README, all I get when calling http://localhost:/simple.org is: Server error No errors are given in any log-buffer I could find. Not sure where the problem appears. A test of elnode according to the elnode README worked out ok (defun my-test-handler (httpcon) "Demonstration function" (elnode-http-start httpcon 200 '("Content-type" . "text/html")) (elnode-http-return httpcon "HELLO!")) (elnode-start 'my-test-handler :port 8010 :host "localhost") Might it be, that the elnode API changed and that the handler function need some rewrite? All the best Torsten On 4 October 2013 16:03, Eric Schulte wrote: > Check out org-ehtml. See the original announcement [1] and the repo on > github [2]. It might need some attention as the Org-mode export API is > constantly in flux, but it does work to allow editing of Org-mode pages > through a web page. > > Cheers, > > Footnotes: > [1] http://thread.gmane.org/gmane.emacs.orgmode/58773/focus=58884 > > [2] https://github.com/eschulte/org-ehtml > > -- > Eric Schulte > https://cs.unm.edu/~eschulte > PGP: 0x614CA05D >
Re: [O] Babel: Ada, Smalltalk and Objective-C ?
Aloha Mehul, Mehul Sanghvi writes: > Is there any support for Ada, Smalltalk and Objective-C that anyone is > aware of ? Not that I'm aware of. > > Are there any pointers on how to add such support to Babel ? Yes, see http://orgmode.org/worg/org-contrib/babel/languages.html#develop There is a template that outlines what needs to be done. Also a template for preparing on-line documentation. hth, Tom -- Thomas S. Dye http://www.tsdye.com
Re: [O] [Babel][R] Inclusion of multi-line named code blocks in R code
Hi Alex, I made a first draft of the Babel SQL documentation for Worg. See http://orgmode.org/worg/org-contrib/babel/languages/ob-doc-sql.html Please edit or augment as you see fit. I believe you need FSF papers to contribute to ob-sql.el. If you have those, then by all means, please add Netezza support and get the ball rolling on sessions. All the best, Tom Alexander Vorobiev writes: > Hi Tom, > > Unfortunately I can't have pure SQL output in my org files for two reasons: > > 1. The result set I am dealing with for this particular problem is about > 2 records > 2. My SQL server (Netezza, "big data appliance") is not supported by > Babel-SQL. I configured sql-mode to work with Netezza but session-based SQL > is not supported by Babel either. I started adding support for SQL sessions > to ob-sql.el and it kind of works but the results I am getting are > inconsistent and only a small subset of header parameters is supported. Of > course I haven't tested is with any other database. I can share what I've > done if anybody is interested. > > Regards, > Alex > > > On Wed, Sep 18, 2013 at 5:27 PM, Thomas S. Dye wrote: > >> Aloha Alex, >> >> My work flow in this situation evaluates the SQL to create an Org-mode >> table, which serves as input to the R source code block. >> >> For me, seeing the SQL output in a table is a sanity check. >> >> hth, >> Tom >> >> Alexander Vorobiev writes: >> >> > I have R code which submits SQL statements to a database server. Since >> the >> > SQL is rather complex, I want to put it into a separate code block in >> order >> > to have proper formatting, syntax highlighting, etc: >> > >> > #+name: long-sql >> > #+begin_src sql >> > select * >> > from many, tables >> > where >> > complex_condition1 = 1, >> > complex_condition2 = 2 >> > #+end_src >> > >> > * Load the data to R session >> > #+begin_src R :session *R* :noweb yes >> > result <- submit_query('<>') >> > #+end_src >> > >> > Unfortunately, the R block doesn't work. When I open the file generated >> by >> > Babel, I see this: >> > >> > result <- submit_query('select * >> > result <- submit_query('from many, tables >> > etc >> > >> > instead of the one R submit_query call with my SQL statement as an >> > argument. Is there anything I can do to achieve that? >> > >> > Thanks >> > Alex >> > I have R code which submits SQL statements to a database server. Since >> > the SQL is rather complex, I want to put it into a separate code block >> > in order to have proper formatting, syntax highlighting, etc: >> > >> > #+name: long-sql >> > #+begin_src sql >> > select * >> > from many, tables >> > where >> > complex_condition1 = 1, >> > complex_condition2 = 2 >> > #+end_src >> > >> > * Load the data to R session >> > #+begin_src R :session *R* :noweb yes >> > result <- submit_query('<>') >> > #+end_src >> > >> > Unfortunately, the R block doesn't work. When I open the file >> > generated by Babel, I see this: >> > >> > result <- submit_query('select * >> > result <- submit_query('from many, tables >> > etc >> > >> > instead of the one R submit_query call with my SQL statement as an >> > argument. Is there anything I can do to achieve that? >> > >> > Thanks >> > Alex >> > >> > >> >> -- >> Thomas S. Dye >> http://www.tsdye.com >> > Hi Tom, > > Unfortunately I can't have pure SQL output in my org files for two > reasons: > > 1. The result set I am dealing with for this particular problem is > about 2 records > 2. My SQL server (Netezza, "big data appliance") is not supported by > Babel-SQL. I configured sql-mode to work with Netezza but > session-based SQL is not supported by Babel either. I started adding > support for SQL sessions to ob-sql.el and it kind of works but the > results I am getting are inconsistent and only a small subset of > header parameters is supported. Of course I haven't tested is with any > other database. I can share what I've done if anybody is interested. > > Regards, > Alex > > On Wed, Sep 18, 2013 at 5:27 PM, Thomas S. Dye wrote: > > Aloha Alex, > > My work flow in this situation evaluates the SQL to create an > Org-mode > table, which serves as input to the R source code block. > > For me, seeing the SQL output in a table is a sanity check. > > hth, > Tom > > > > Alexander Vorobiev writes: > > > I have R code which submits SQL statements to a database server. > Since the > > SQL is rather complex, I want to put it into a separate code > block in order > > to have proper formatting, syntax highlighting, etc: > > > > #+name: long-sql > > #+begin_src sql > > select * > > from many, tables > > where > > complex_condition1 = 1, > > complex_condition2 = 2 > > #+end_src > > > > * Load the data to R session > > #+begin_src R :session *R* :noweb yes > > result <- submit_query('<>') > > #+end_src > > > > Unfortunately, the
Re: [O] capture, attach, link files from web
Myles English writes: > Hello, > > Just thought I would share something I find useful. What the code below > does is: > > 1) prompts for a link to a file on the internet > 2) downloads the file > 3) attaches the file to the current subtree > 4) inserts at the current point a link to the attachment > > This is useful if (e.g.) you are scouring Google images for ideas and > want to save lots of image files. Interesting! I've done a fair amount of this, and wanted this exact sort of function, and have been too lazy to implement it myself. A couple of thoughts: Rather than sending downloaded files to $TMPDIR, it might be nice to have them just use whatever dir org-attach would have used. I use org-attach from time to time, and notice that everything ends up under ~/org/data/. I haven't actually investigated why that happens (I've got org-directory set to ~/org/), mostly because it strikes me as a fine default. When we've got that directory, setting a different TMPDIR seems unnecessary. I'll admit part of my hesitation comes from the fact that "TMPDIR" sounds like it's going to get automatically deleted at some point. I've often thought it would be nice to link to images in an org file with http: links, then at some arbitrary point in time call a hypothetical org-localize-external-resources command. That command would wget all the external resources, put them somewhere local, and switch the links to the file: type. Just a thought. Regardless, thanks for posting this. It's fun to see other people thinking in familiar directions. E > Requirements: wget, set $TMPDIR. > TODO: integrate properly with capture template > > #+here_is_some elisp > (setq org-link-abbrev-alist '(("att" . org-attach-expand-link))) > > (defun my-attach-and-link-web-file (lnk) > "Download a file, attach it to our heading, insert a link" > (interactive "*sAttach and link to url: \n") > (let ((tmpdir (expand-file-name (getenv "TMPDIR"))) > (fname (file-name-nondirectory lnk))) > (progn (message (concat "Downloading " lnk " to " tmpdir "/" fname)) > (call-process "wget" nil '("*Messages*" t) nil "-P" >tmpdir "-d" >lnk) > (org-attach-attach (concat tmpdir "/" fname) nil 'mv) > (insert (concat "[[att:" fname "]]") > > (define-key global-map "\C-cs" 'my-attach-and-link-web-file) > #+that_was_elisp > > Myles
Re: [O] LaTeX export with Code
Sam Flint flintfam.org> writes: > > I regularly use org-mode for LP, and would like to be able to export the > name of a code chunk as a caption in LaTeX. I have looked at the > manual, and don't see any way of doing this, are there? Yes. Quite a few. If you want is the src block name to be used as the caption, you can put this line: #+CAPTION: use-name-as-caption before the named src block and execute this code before you export: #+BEGIN_SRC emacs-lisp (defun org-export-use-name-as-caption (text &optional back-end info) "Use the block name as the caption." (replace-regexp-in-string "label{\\([^}]*\\)}\\(use-name-as-caption\\)" "label{\\1}\\1" text)) (add-to-list 'org-export-filter-src-block-functions 'org-export-use-name-as-caption) #+END_SRC Then when you export this #+CAPTION: use-name-as-caption #+NAME: y-plus-z-becomes-x #+BEGIN_SRC R x <- y+z #+END_SRC the result is \begin{figure}[H] \begin{verbatim} x <- y+z \end{verbatim}\caption{\label{y-plus-z-becomes-x}y-plus-z-becomes-x} \end{figure} HTH, Chuck
Re: [O] capture, attach, link files from web
Hi Eric, I am glad you like it. e...@ericabrahamsen.net writes: [..] > Rather than sending downloaded files to $TMPDIR, it might be nice to > have them just use whatever dir org-attach would have used. I use > org-attach from time to time, and notice that everything ends up under > ~/org/data/. I haven't actually investigated why that happens (I've got > org-directory set to ~/org/), mostly because it strikes me as a fine > default. When we've got that directory, setting a different TMPDIR seems > unnecessary. I'll admit part of my hesitation comes from the fact that > "TMPDIR" sounds like it's going to get automatically deleted at some > point. The $TMPDIR was just an environment variable I had set already so assumed it was semi-standard (doesn't everyone have a $TMPDIR?). When my function calls: (org-attach-attach (concat tmpdir "/" fname) nil 'mv) it moves the file from $TMPDIR to the attachment directory, amongst other things no doubt. The attachment directory is decided by the (org-attach-dir) function and I presume the new file could be downloaded straight there and then the task/heading would have to be synchronised with it's attachments to get the new file to show up in the heading's properties. > I've often thought it would be nice to link to images in an org file > with http: links, then at some arbitrary point in time call a > hypothetical org-localize-external-resources command. That command would > wget all the external resources, put them somewhere local, and switch > the links to the file: type. Just a thought. Good idea. I look forward to your clever implementation with proper indenting and informative comments. > Regardless, thanks for posting this. It's fun to see other people > thinking in familiar directions. I agree, it is nice to supplement the daily diet of bug reports, help requests, "have you tried emacs -Q" etc. Myles
Re: [O] Babel: Ada, Smalltalk and Objective-C ?
On Mon, Oct 7, 2013 at 11:23 AM, Thomas S. Dye wrote: > Aloha Mehul, > > Mehul Sanghvi writes: > > > Is there any support for Ada, Smalltalk and Objective-C that anyone is > > aware of ? > > Not that I'm aware of. > > > > > Are there any pointers on how to add such support to Babel ? > > Yes, see > http://orgmode.org/worg/org-contrib/babel/languages.html#develop > > There is a template that outlines what needs to be done. Also a template > for preparing on-line documentation. > > Thanks for the pointer. I'll take a look and see what I can come up with. -- Mehul N. Sanghvi email: mehul.sang...@gmail.com
Re: [O] Problem with beamer export
Marvin Doyley writes: > In end of data: > org.el:23923:1:Warning: the following functions are not known to be defined: > characterp, activate-mark, mouse-set-point, with-demoted-errors, > clear-image-cache, face-at-point, image-refresh, beginning-of-visual-line, > invisible-p > Wrote /Users/doyley/Dropbox/root/elisp/org-mode/lisp/org.elc > Compiling /Users/doyley/Dropbox/root/elisp/org-mode/lisp/ox-ascii.el... > Wrote /Users/doyley/Dropbox/root/elisp/org-mode/lisp/ox-ascii.elc > Compiling /Users/doyley/Dropbox/root/elisp/org-mode/lisp/ox-beamer.el... > Wrote /Users/doyley/Dropbox/root/elisp/org-mode/lisp/ox-beamer.elc > Compiling /Users/doyley/Dropbox/root/elisp/org-mode/lisp/ox-html.el... > > In org-html-table--table.el-table: > ox-html.el:3183:27:Warning: kill-buffer called with 0 arguments, but requires > 1 > > In end of data: > ox-html.el:3441:1:Warning: the function `string-match-p' is not known to be > defined. […] Something is seriously wrong with the Emacs you use for compilation or your setup. What is the result of "make config-all"? Regards, Achim. -- +<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+ Factory and User Sound Singles for Waldorf Blofeld: http://Synth.Stromeko.net/Downloads.html#WaldorfSounds
Re: [O] [Babel][R] Inclusion of multi-line named code blocks in R code
Hi Tom, Thanks for the Worg documentation. I don't have the FSF papers yet, but I will sign and send them soon. It looks like the Babel SQL support would benefit from more modular approach so that adding new engine would not require modifying existing functions. Perhaps, something like the Emacs sql-mode which provides hooks and functions for adding database engines. For instance I was able to add Netezza support easily without touching anything in sql-mode.el. Eventually I managed to run my Netezza queries from Babel by writing a bash script which would supply the correct parameters to nzsql and calling it psql :) but having native Babel support would be so much better. I also have a looming need to run Hadoop Hive sql queries which is not supported by Babel (or sql-mode) either so I will be definitely adding hive to ob-sql as well. Regards, Alex On Mon, Oct 7, 2013 at 10:42 AM, Thomas S. Dye wrote: > Hi Alex, > > I made a first draft of the Babel SQL documentation for Worg. See > http://orgmode.org/worg/org-contrib/babel/languages/ob-doc-sql.html > > Please edit or augment as you see fit. > > I believe you need FSF papers to contribute to ob-sql.el. If you have > those, then by all means, please add Netezza support and get the ball > rolling on sessions. > > All the best, > Tom > > Alexander Vorobiev writes: > > > Hi Tom, > > > > Unfortunately I can't have pure SQL output in my org files for two > reasons: > > > > 1. The result set I am dealing with for this particular problem is about > > 2 records > > 2. My SQL server (Netezza, "big data appliance") is not supported by > > Babel-SQL. I configured sql-mode to work with Netezza but session-based > SQL > > is not supported by Babel either. I started adding support for SQL > sessions > > to ob-sql.el and it kind of works but the results I am getting are > > inconsistent and only a small subset of header parameters is supported. > Of > > course I haven't tested is with any other database. I can share what I've > > done if anybody is interested. > > > > Regards, > > Alex > > > > > > On Wed, Sep 18, 2013 at 5:27 PM, Thomas S. Dye wrote: > > > >> Aloha Alex, > >> > >> My work flow in this situation evaluates the SQL to create an Org-mode > >> table, which serves as input to the R source code block. > >> > >> For me, seeing the SQL output in a table is a sanity check. > >> > >> hth, > >> Tom > >> > >> Alexander Vorobiev writes: > >> > >> > I have R code which submits SQL statements to a database server. Since > >> the > >> > SQL is rather complex, I want to put it into a separate code block in > >> order > >> > to have proper formatting, syntax highlighting, etc: > >> > > >> > #+name: long-sql > >> > #+begin_src sql > >> > select * > >> > from many, tables > >> > where > >> > complex_condition1 = 1, > >> > complex_condition2 = 2 > >> > #+end_src > >> > > >> > * Load the data to R session > >> > #+begin_src R :session *R* :noweb yes > >> > result <- submit_query('<>') > >> > #+end_src > >> > > >> > Unfortunately, the R block doesn't work. When I open the file > generated > >> by > >> > Babel, I see this: > >> > > >> > result <- submit_query('select * > >> > result <- submit_query('from many, tables > >> > etc > >> > > >> > instead of the one R submit_query call with my SQL statement as an > >> > argument. Is there anything I can do to achieve that? > >> > > >> > Thanks > >> > Alex > >> > I have R code which submits SQL statements to a database server. Since > >> > the SQL is rather complex, I want to put it into a separate code block > >> > in order to have proper formatting, syntax highlighting, etc: > >> > > >> > #+name: long-sql > >> > #+begin_src sql > >> > select * > >> > from many, tables > >> > where > >> > complex_condition1 = 1, > >> > complex_condition2 = 2 > >> > #+end_src > >> > > >> > * Load the data to R session > >> > #+begin_src R :session *R* :noweb yes > >> > result <- submit_query('<>') > >> > #+end_src > >> > > >> > Unfortunately, the R block doesn't work. When I open the file > >> > generated by Babel, I see this: > >> > > >> > result <- submit_query('select * > >> > result <- submit_query('from many, tables > >> > etc > >> > > >> > instead of the one R submit_query call with my SQL statement as an > >> > argument. Is there anything I can do to achieve that? > >> > > >> > Thanks > >> > Alex > >> > > >> > > >> > >> -- > >> Thomas S. Dye > >> http://www.tsdye.com > >> > > Hi Tom, > > > > Unfortunately I can't have pure SQL output in my org files for two > > reasons: > > > > 1. The result set I am dealing with for this particular problem is > > about 2 records > > 2. My SQL server (Netezza, "big data appliance") is not supported by > > Babel-SQL. I configured sql-mode to work with Netezza but > > session-based SQL is not supported by Babel either. I started adding > > support for SQL sessions to ob-sql.el and it kind of works but the > > results I am getting are inconsistent and only a small
Re: [O] capture, attach, link files from web
Myles English writes: > Hi Eric, > > I am glad you like it. > > e...@ericabrahamsen.net writes: > > [..] > >> Rather than sending downloaded files to $TMPDIR, it might be nice to >> have them just use whatever dir org-attach would have used. I use >> org-attach from time to time, and notice that everything ends up under >> ~/org/data/. I haven't actually investigated why that happens (I've got >> org-directory set to ~/org/), mostly because it strikes me as a fine >> default. When we've got that directory, setting a different TMPDIR seems >> unnecessary. I'll admit part of my hesitation comes from the fact that >> "TMPDIR" sounds like it's going to get automatically deleted at some >> point. > > The $TMPDIR was just an environment variable I had set already so > assumed it was semi-standard (doesn't everyone have a $TMPDIR?). When > my function calls: > > (org-attach-attach (concat tmpdir "/" fname) nil 'mv) > > it moves the file from $TMPDIR to the attachment directory, amongst > other things no doubt. Whoops, should have looked at the signature of `org-attach-attach' more closely... > The attachment directory is decided by the (org-attach-dir) function and > I presume the new file could be downloaded straight there and then the > task/heading would have to be synchronised with it's attachments to get > the new file to show up in the heading's properties. > >> I've often thought it would be nice to link to images in an org file >> with http: links, then at some arbitrary point in time call a >> hypothetical org-localize-external-resources command. That command would >> wget all the external resources, put them somewhere local, and switch >> the links to the file: type. Just a thought. > > Good idea. I look forward to your clever implementation with proper > indenting and informative comments. I'll get right on it :)
Re: [O] Problem with beamer export
The problem is now solved. I downloaded the latest update and everything works like a charm. I still get some strange errors during completion. Here is the result of the make config-all = Emacs executable and Installation paths EMACS = emacs DESTDIR = ORGCM = dirall ORG_MAKE_DOC= info html pdf lispdir = /usr/share/emacs/site-lisp/org infodir = /usr/share/info datadir = /usr/share/emacs/etc/org testdir = /var/folders/70/h1dqf9dn3997jbfptpp2fxlmgn/T//tmp-orgtest = Additional files from contrib/lisp = Test configuration BTEST_PRE = BTEST_POST = BTEST_OB_LANGUAGES = awk C fortran maxima lilypond octave python sh perl BTEST_EXTRA = = Executables used by make CP = install -m 644 -p MKDIR = install -m 755 -d RM = rm -f RMR = rm -fr FIND= find SUDO= sudo PDFTEX = pdftex TEXI2PDF= texi2pdf --batch --clean --expand TEXI2HTML = makeinfo --html --number-sections MAKEINFO= makeinfo INSTALL_INFO= install-info = Commands used by make BATCH = emacs -batch -Q --eval '(setq vc-handled-backends nil)' BATCHL = emacs -batch -Q --eval '(setq vc-handled-backends nil)' --eval '(add-to-list '"'"'load-path ".")' ELC = emacs -batch -Q --eval '(setq vc-handled-backends nil)' --eval '(add-to-list '"'"'load-path ".")' --eval '(batch-byte-compile)' ELCDIR = emacs -batch -Q --eval '(setq vc-handled-backends nil)' --eval '(add-to-list '"'"'load-path ".")' --eval '(batch-byte-recompile-directory 0)' BTEST = emacs -batch -Q --eval '(setq vc-handled-backends nil)' --eval '(add-to-list '"'"'load-path "./lisp")' --eval '(add-to-list '"'"'load-path "./testing")' -l org-loaddefs.el -l testing/org-test.el --eval '(require '"'"'ob-awk)' --eval '(require '"'"'ob-C)' --eval '(require '"'"'ob-fortran)' --eval '(require '"'"'ob-maxima)' --eval '(require '"'"'ob-lilypond)' --eval '(require '"'"'ob-octave)' --eval '(require '"'"'ob-python)' --eval '(require '"'"'ob-sh)' --eval '(require '"'"'ob-perl)' --eval '(setq org-confirm-babel-evaluate nil)' MAKE_LOCAL_MK = emacs -batch -Q --eval '(setq vc-handled-backends nil)' --eval '(add-to-list '"'"'load-path "./lisp")' --eval '(load "org-compat.el")' --eval '(load "../mk/org-fixup.el")' --eval '(org-make-local-mk)' MAKE_ORG_INSTALL= emacs -batch -Q --eval '(setq vc-handled-backends nil)' --eval '(add-to-list '"'"'load-path ".")' --eval '(load "org-compat.el")' --eval '(load "../mk/org-fixup.el")' --eval '(org-make-org-loaddefs)' MAKE_ORG_VERSION= emacs -batch -Q --eval '(setq vc-handled-backends nil)' --eval '(add-to-list '"'"'load-path ".")' --eval '(load "org-compat.el")' --eval '(load "../mk/org-fixup.el")' --eval '(org-make-org-version "8.2.1" "release_8.2.1-80-g21b110" "'/usr/share/emacs/etc/org'")' = Org version make: Org-mode version 8.2.1 (release_8.2.1-80-g21b110 => /usr/share/emacs/site-lisp/org)