public inbox archive for pandoc-discuss@googlegroups.com
 help / color / mirror / Atom feed
* Can't access keys containing spaces in pandoc
@ 2019-09-02  9:10 Frederik Hartmann
       [not found] ` <92055fd0-049b-4943-a51a-2eb0905b59ca-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
  0 siblings, 1 reply; 11+ messages in thread
From: Frederik Hartmann @ 2019-09-02  9:10 UTC (permalink / raw)
  To: pandoc-discuss


[-- Attachment #1.1: Type: text/plain, Size: 1566 bytes --]

Hi!

We are using rather complicated templates to display certain information 
about dependencies.
These information can be exported in yaml files and looks like the 
following:

---
dependencies:
  external:
    hardware:
    - Description: Text here....
      Dependency On: Text here....
      Date Required: Text here....
      Dependency Owner: Text here....
      Color: Text here....
      Status: Text here....
      Last Updated: Text here....
      State: Text here....
...

This is a perfectly valid and well-formed yaml document.

Now, the best thing would be if I could simply loop over these attributes 
without having to specify them directly.
The next best thing would be if I could access them via the usual method:

$for(dependencies.external.hardware)$
$if(dependencies.external.hardware.Description)$\textbf{Description:} & 
$dependencies.external.hardware.Description$ \\ $endif$
$endfor$


The issue are with the keys that contain spaces. I can't find a way to 
access them at all.

I tried it the following ways:
$if(dependencies.external.hardware.Dependency On)$
$if(dependencies.external.hardware.Dependency\ On)$

Any suggestion?

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/92055fd0-049b-4943-a51a-2eb0905b59ca%40googlegroups.com.

[-- Attachment #1.2: Type: text/html, Size: 11244 bytes --]

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2019-09-06 20:31 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-02  9:10 Can't access keys containing spaces in pandoc Frederik Hartmann
     [not found] ` <92055fd0-049b-4943-a51a-2eb0905b59ca-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2019-09-02  9:37   ` James
     [not found]     ` <5E6256F2-6354-43F9-9A49-2328471A9D2B-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2019-09-02 10:32       ` Frederik Hartmann
     [not found]         ` <68fbd484-0729-4ee2-a7a2-0846cd0bbd28-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2019-09-02 17:28           ` John MacFarlane
     [not found]             ` <m2tv9uboau.fsf-pgq/RBwaQ+zq8tPRBa0AtqxOck334EZe@public.gmane.org>
2019-09-02 20:19               ` Frederik Hartmann
     [not found]                 ` <7c15c170-1b08-4274-b24e-280b4585c0c6-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2019-09-03 16:25                   ` John MacFarlane
     [not found]                     ` <yh480k8sr5z6r1.fsf-pgq/RBwaQ+zq8tPRBa0AtqxOck334EZe@public.gmane.org>
2019-09-03 16:35                       ` Daniel Staal
     [not found]                         ` <330c5975-5678-26fa-e517-2a9ca612a383-Jdbf3xiKgS8@public.gmane.org>
2019-09-03 17:20                           ` Benct Philip Jonsson
2019-09-04  5:33                     ` jiewuza
     [not found]                       ` <m2o900wrpc.fsf-9Onoh4P/yGk@public.gmane.org>
2019-09-04  8:39                         ` Frederik Hartmann
     [not found]                           ` <35a9acd1-dff5-4529-9abb-d8f9fc87bce4-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2019-09-06 20:31                             ` BPJ

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).