Re: File local setting for export directory?
Russell Adams writes: > On Mon, Aug 03, 2020 at 04:15:22PM +0200, Loris Bennett wrote: >> I want to export an org file to a pdf and have the pdf created in >> subdirectory relative to the org file. >> >> What's the simplest way to set the export directory in a file local way? > > Can you just set your EXPORT_FILE_NAME to include that directory? > > #+EXPORT_FILE_NAME: subdir/Thing.html > > You might need a FQPN. You'll have to test. > Unfortunately, this produces the tex file in the subdir, but the xelatex/pdflatex process is still run in the current directory, with `subdir/file.tex' as input file, so it produces the PDF in the current directory. I was wondering why Eric A. suggested a patch, but I guess this is the reason (N.B. I haven't tried his patch). -- Nick "There are only two hard problems in computer science: cache invalidation, naming things, and off-by-one errors." -Martin Fowler
Re: File local setting for export directory?
"Loris Bennett" writes: > Hi, > > I want to export an org file to a pdf and have the pdf created in > subdirectory relative to the org file. > > What's the simplest way to set the export directory in a file local way? I suggested the attached diff a while ago, but no one seemed very interested. I think it might already do what you want. diff --git a/lisp/ox.el b/lisp/ox.el index 9cf62078a..77cafb20d 100644 --- a/lisp/ox.el +++ b/lisp/ox.el @@ -6417,6 +6417,20 @@ Return file name as a string." "Output file: " pub-dir nil nil nil (lambda (n) (string= extension (file-name-extension n t)) extension)) + (pub-dir (or pub-dir + (and subtreep (org-entry-get + nil "EXPORT_PUB_DIR" 'selective)) + (org-with-point-at (point-min) + (catch :found + (let ((case-fold-search t)) + (while (re-search-forward +"^[ \t]*#\\+EXPORT_PUB_DIR:[ \t]+\\S-" +nil t) + (let ((element (org-element-at-point))) +(when (eq 'keyword (org-element-type element)) + (throw :found + (org-element-property + :value element)) (output-file ;; Build file name. Enforce EXTENSION over whatever user ;; may have come up with. PUB-DIR, if defined, always has
[Feature Request] More flexibility in org-speed-commands customization
Hi All, Org's speed keys are a very interesting feature to which I've long been attracted to. And indeed, I've flirted with it a number of times in the past. But every time I do so, I end up stepping back, because I get weary of fat fingering my documents. The whole set of speed keys is more powerful than what I would wish. I'd love to have speed keys for navigation and visibility, but I would also gladly refrain from these "too handy" editing keys. As things stand, the speed keys are defined by combining `org-speed-commands-default', a defconst, and `org-speed-commands-user', a defcustom. But the former already contains a large set of speed keys, including some quite powerful editing ones. And it is thus hard to remove these keys. Of course, it is possible. We could shadow the same key in `org-speed-commands-user' to do nothing. Or, though a defconst, `org-speed-commands-default' can be redefined after loading Org. The first is clumsy, and renders the `org-speed-command-help' buffer quite confusing. The second feels wrong (because it is). I don't know if there is a strong reason to hard-code the set of keys in `org-speed-commands-default'. But, if there isn't, could you consider (somehow) exposing the whole set of `org-speed-commands' to user customization? Best, Gustavo.
Re: File local setting for export directory?
On Mon, Aug 03, 2020 at 04:15:22PM +0200, Loris Bennett wrote: > I want to export an org file to a pdf and have the pdf created in > subdirectory relative to the org file. > > What's the simplest way to set the export directory in a file local way? Can you just set your EXPORT_FILE_NAME to include that directory? #+EXPORT_FILE_NAME: subdir/Thing.html You might need a FQPN. You'll have to test. -- Russell Adamsrlad...@adamsinfoserv.com PGP Key ID: 0x1160DCB3 http://www.adamsinfoserv.com/ Fingerprint:1723 D8CA 4280 1EC9 557F 66E8 1154 E018 1160 DCB3
How create a hook before export ONLY to text
Hi friends. First time here, I have a couple of years working with org and i love it. Now I have a problem. I discovered the plantuml language to create nice charts, also I have minted configured to transform in latex to pdf. But minted doesn't have the lexer so throws error. I think, if there are a simple solution to do that. A hook, maybe this: org-export-before-parsing-hook To parse or use 'sed' i don't know yet. To change the "#+BEGIN_SRC plantuml" to "#+BEGIN_SRC text" or similar. So, what i need to know or do? I know a little of lisp, i understand i have to: - condition export to latex (only, because html is fine) - if use plantuml change, if not not - in latex has to create \begin{minted}[text] and not \begin{minted}[plantuml] Or, there are a general form to drop the minted on languages that not has lexer? Using emacs-org Best regards!! Sent with [ProtonMail](https://protonmail.com) Secure Email.
File local setting for export directory?
Hi, I want to export an org file to a pdf and have the pdf created in subdirectory relative to the org file. What's the simplest way to set the export directory in a file local way? Cheers, Loris -- This signature is currently under construction.
RE: Website revamp?
Hi TEC, Just wanted to add one datapoint here. I think this effort your putting down is commendable and deserves many +1's. Reading about something ofc happen on devices other than where the software in the end is installed. Thus, I agree fully with what you write below! Your draft is already a big improvement and I, for one, hope it can go into "release" as soon as possible. Even if it's not "perfect". Because nothing is, especially not regarding design, where facts are few and opinions are many. Thank you. /Gustav > -Original Message- > From: Emacs-orgmode On Behalf > Of TEC > Sent: den 3 augusti 2020 07:11 > To: Colin Baxter > Cc: emacs-orgmode@gnu.org > Subject: Re: Website revamp? > > > Colin Baxter writes: > > >> TEC writes: > >> - The site is now more mobile friendly, the navbar now has a > > > > Why? How many users are installing org-mode on their 'phones - smart > > or otherwise? > > Zero, I expect :P > > However, I don't think that's the question we should be asking. > Consider someone tweeting about org-mode, the question then is: > how many people use twitter on their phones? > > Likewise, if someone wants to share a org-mode with a friend, and sends them > a link - whether it be by email, sms, whatsapp, messenger, or telegram: > what's the chance that they'll take a peek oh their phones? > > Of course we don't exactly have any hard answers to these questions, but I'd > wager the answer is enough to warrant a little bit of effort to make the > mobile experience not-garbage. To see how orgmode.org currently appears, see > https://i.imgur.com/XPFfBaB.png > > IMO that's downright off-putting --- and I say that intending no criticism > to Carsten or Bastien, in 2012 mobile design simple wasn't a priority. > > Moreover, we can improve the mobile experience with no compromise to the > desktop > --- so why wouldn't we? :D > > I hope this fleshes out my motivation for improving the mobile experience :) > > Timothy.
Re: Website revamp?
Colin Baxter writes: It seems to have the usual vertical monotone blocks, commonly seen in mobile sites. These may be necessary for the small screen but represent to me a retrograde development in web-site design. Ah yes, the big banner on the index page. I think I can see your point of view --- the current index is far more informative. Ultimately though the decision to use a banner wasn't just triggered by mobile considerations, but a little re-think about the structure and purpose of the website. As I see it, the desirable purpose of the 'main' pages is roughly as follows: - index :: attention grabber - features :: capture interest, entice to try - releases :: see what's changed recently - install :: how to get started - documentation :: dig into the details - contribute :: encourage to give back to the project With those goals in mind, I see a large banner on the index declaring (effectively) that "org is great" as being in line with the above UX. Of course, my criticism is unimportant since you are doing the hard work - not me. Quite the contrary! If there's anything I want more of with this effort (appart from general help) it's criticism/feedback. As you've pointed out it's (effectively) just me working on this: so hearing other people's thoughts is emminently desirable. Would it be possible to have two sites: one for display on a desktop and another for mobile use? Perhaps not. Effectively, yes. You could have CSS as follows: #+BEGIN_SRC css @media(min-width:851px) { /* desktop style */ } @media(max-width:850px) { /* mobile style */ } #+END_SRC Good luck. Thanks :) I hope this can receive Bastien/Carsten's blessing and be used for the main site sooner rather than later. All the best, Timothy.
Re: Website revamp?
On Mon, Aug 03, 2020 at 01:11:24PM +0800, TEC wrote: > > Colin Baxter writes: > > >> TEC writes: > >> - The site is now more mobile friendly, the navbar now has a > > > > Why? How many users are installing org-mode on their 'phones - smart or > > otherwise? > > Zero, I expect :P Emacs should run fine on PostmarketOS [1] [2]. Thus Org, too. Cheers [1] https://postmarketos.org/ [2] https://en.wikipedia.org/wiki/PostmarketOS -- t signature.asc Description: Digital signature
Re: Website revamp?
Dear Timothy, > TEC writes: - Snip -- > Of course we don't exactly have any hard answers to these > questions, but I'd wager the answer is enough to warrant a little > bit of effort to make the mobile experience not-garbage. To see > how orgmode.org currently appears, see > https://i.imgur.com/XPFfBaB.png It seems to have the usual vertical monotone blocks, commonly seen in mobile sites. These may be necessary for the small screen but represent to me a retrograde development in web-site design. Of course, my criticism is unimportant since you are doing the hard work - not me. Would it be possible to have two sites: one for display on a desktop and another for mobile use? Perhaps not. Good luck. Colin Baxter -- Colin Baxter URL: http://www.Colin-Baxter.com