From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.text.pandoc/22729 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: jiewuza Newsgroups: gmane.text.pandoc Subject: Re: ' in meta value is converted into =?utf-8?Q?=E2=80=99?= in a lua filter Date: Thu, 16 May 2019 15:40:51 +0800 Message-ID: References: Reply-To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="69181"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (darwin) To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-X-From: pandoc-discuss+bncBDS4Z3WZ2UDRB65H6TTAKGQE5NGHFWA-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Thu May 16 09:40:48 2019 Return-path: Envelope-to: gtp-pandoc-discuss@m.gmane.org Original-Received: from mail-lj1-f188.google.com ([209.85.208.188]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.89) (envelope-from ) id 1hRB0O-000Hpn-Up for gtp-pandoc-discuss@m.gmane.org; Thu, 16 May 2019 09:40:44 +0200 Original-Received: by mail-lj1-f188.google.com with SMTP id h1sf326709ljk.22 for ; Thu, 16 May 2019 00:40:44 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1557992444; cv=pass; d=google.com; s=arc-20160816; b=j9gQGuk/aPKJ6D/gzSQy26lnzowvH/eI6ln9ySBDuDKsw75cLUYbnU8KJt+h8n/86q E7EYLn+WoPORl+b/oyqt2O8njt4FTQ+sk6CyLWTmzQ8hynf2koYoeFcpkOPy0AKjIuFz 1NSRpeOCXKS5Mrzw2i/fY2H7DCaKL4rcF9T8Ead2P7f2pISZcmxdAbpv9KQQnVNdF5iT B7EqStAsAGMAL0U6c0hX8zaqb7AmCEHzYpRXT/F7LHEx5xph87iUlGt5yVDEMVxDRJ4y zPYmCk6+glnX7JBeL1uJ+fSlRk3bofI6RgEfjVb4nifciAy/Kgt9TBqsEVfIXHJ1S23u KwjA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:cancel-lock:user-agent :content-transfer-encoding:mime-version:references:message-id:date :subject:from:to:sender:dkim-signature; bh=sEkl5hBX+lB5kzwn8OpEForfwFTPO1Sh9Xh82iMAMoM=; b=lPsHOjhaiwNudNeiItEj+sNSaeFCg/69Z0gw+6/nqaBOxyE66KDU0iYnPr9Yj/QWVx m7Y3ISzpf6IM9/s4BLQvmsYdW1HGeLG+WBlWn7mz/2DA3nGpBOa/0ysJ/VVpy3bFgUOF 7jAJx800XpyZFEwETQ2ou5jbre3lb5j+TsY8wJk/o3qMnFksDIFsb5JUDnPUpkTfM2G+ tctKNt4lwwcn04EJGwMqab6QwLX9ddGJAqnEvNHCaD4/iK1whxInzx51S0NBeB7ACslj Tt1FZwPeDSTfwAS8Ec3yIOOeh9K2qvFIT0Qr8S3mPBNu3mqpsd7nvEHo3pY2kwwYF3qg ZVCQ== ARC-Authentication-Results: i=2; gmr-mx.google.com; spf=neutral (google.com: 195.159.176.226 is neither permitted nor denied by best guess record for domain of gtp-pandoc-discuss@m.gmane.org) smtp.mailfrom=gtp-pandoc-discuss@m.gmane.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=163.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20161025; h=sender:to:from:subject:date:message-id:references:mime-version :content-transfer-encoding:user-agent:cancel-lock:x-original-sender :x-original-authentication-results:reply-to:precedence:mailing-list :list-id:list-post:list-help:list-archive:list-subscribe :list-unsubscribe; bh=sEkl5hBX+lB5kzwn8OpEForfwFTPO1Sh9Xh82iMAMoM=; b=FayuB8Otbvvk4t3wsaldjse0mfE5cJ8gSoh/BOUQhnC61bO8FdRfv2s15BOc2pUva4 G6AF/VHWiNL2fN2dXKbi083HEEIBHqfEe4S7Yk3HxAaVuf0a03uqhvZkGLoIRU/NfouT 06XxFpjOyLOvXKkXpvbooR+WhmpzgkqgvbY7gUP53HCMlNbbcPzGIc+PKAzEgyqUY8N9 ub6iUivLZ1g9EqVoNQjSu8blJVQMR/c9Yt6KPfbBvkx3LKK87/rpUwNaWFuLUKxFZ12L LQn5vgus8eWVFI1xghWoF5QJGTwJNZ4K9rq46u5jkUc+/JkeO3S9VeQtrgrCjo93fFAc Kccw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=sender:x-gm-message-state:to:from:subject:date:message-id :references:mime-version:content-transfer-encoding:user-agent :cancel-lock:x-original-sender:x-original-authentication-results :reply-to:precedence:mailing-list:list-id:x-spam-checked-in-group :list-post:list-help:list-archive:list-subscribe:list-unsubscribe; bh=sEkl5hBX+lB5kzwn8OpEForfwFTPO1Sh9Xh82iMAMoM=; b=YULDBQ/53sVXVEuRGvqaKm+5XIORDW7ip3q7VfEZ6qZzAgWz8FnN2S20hHBf2YkD5U GFsuuwfUnJ+n0HfDhrx0dPU4xCqXt/iWIFkhqRuzJSMPaiX7TT6Zc3rIWohTsgDIeYHr rf9BQtXhlJU5BBXKcdThyoMB2BmdhCuYSKH1YVjqc1LkZIxMKiJ78qlLrJbfrbDj/uzO 9ZOst08vkk30o2hMGPbA+8cXYfyHv0rEuJO0s1aNwpF7fHkCLhO+7Y9ZM3oGz8UJjQo+ FmA2cWp+yK9Me/HQU9YGEYj8QXuhf28JvLVulam5PnSwD9OhBi8Gvbz4rwTKbBv Original-Sender: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org X-Gm-Message-State: APjAAAX+muoLhcQ3bIKuUOAgiQG4/iQUueI6yKo/EqAZBmTRgv999vi1 RVOottvteOVPYsrM8WQCcM8= X-Google-Smtp-Source: APXvYqywf1Y4r1z3hsM8JHysX3z79dzpnr93NkeXNgQB1yoz831Di/m8mixiIU3ohpdIGEZG3XSlcA== X-Received: by 2002:ac2:4919:: with SMTP id n25mr10094418lfi.114.1557992444601; Thu, 16 May 2019 00:40:44 -0700 (PDT) X-BeenThere: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-Received: by 2002:ac2:4c88:: with SMTP id d8ls451681lfl.13.gmail; Thu, 16 May 2019 00:40:43 -0700 (PDT) X-Received: by 2002:ac2:4c93:: with SMTP id d19mr4362024lfl.116.1557992443567; Thu, 16 May 2019 00:40:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1557992443; cv=none; d=google.com; s=arc-20160816; b=RkVeyaCdLQ5e2ZCpvpv91DYkEkWoFCxruQysC3z+RBCuH3Kp9FcigQ5Va8/dTgLtwe VoKHvaCfqKGJBF/6+K4hzgFgE1BL/CPZAbYt376Zh3HvZmu53dzAcuLkeNZqpN7eTixJ pUPwl57M+VJbrNmShzkWpyWlPeIuuirWmUWMkVHN4oK3DzgIXZ7hSS8r8p9QilFJ5tuK PcmQZ6FN+m6dnCgXbQgsQQQsQI/EcidL1z0+v6R9yZRJT1HASi48szlM4iBsP0uxuhSZ x+cfALScJI5ZuWuVvO1I/m02KrfT0D0HTE2FFsUcqvvQnKk8s5UtWXi8RK2lI6sHP4Fz KI+A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cancel-lock:user-agent:content-transfer-encoding:mime-version :references:message-id:date:subject:from:to; bh=WCZ2Qh8Az1Qs20hk+bG5C0x70Nk4mjGNthfha2o4aMw=; b=vSUpbNXRdUy0pUZckg1XJ6q5V8CtyfBGGfyLb7NMw0/Heh3WWAZZXZ5XDgT3dSm2td ijGma+DKvj7WEehGrNarV/3VGU6mTLMJn5JZRY39yLa4p770jxD1FfmxeKZSN1Kn8Ba0 TP2VtcXKlEH5DIEo+ER6qajTlRns3hKXP6nXI3RB9u7DuAA741Dzd8I8DT2vYr7Gp16p nSkKy5DBIYlWzOzcvNwa/y/pybBglghnu+jB7yb1WBR/or+9Pj/hXrGDy5csC2P18cjj mEQ0DxTlgwop6BpdBpBzNz0PHZel1TWGmFI9ZY1B/0qsvef8tOtMzPQ2GWbpMMaKdt50 VYJA== ARC-Authentication-Results: i=1; gmr-mx.google.com; spf=neutral (google.com: 195.159.176.226 is neither permitted nor denied by best guess record for domain of gtp-pandoc-discuss@m.gmane.org) smtp.mailfrom=gtp-pandoc-discuss@m.gmane.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=163.com Original-Received: from blaine.gmane.org ([195.159.176.226]) by gmr-mx.google.com with ESMTPS id c9si987737lff.2.2019.05.16.00.40.43 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 16 May 2019 00:40:43 -0700 (PDT) Received-SPF: neutral (google.com: 195.159.176.226 is neither permitted nor denied by best guess record for domain of gtp-pandoc-discuss@m.gmane.org) client-ip=195.159.176.226; Original-Received: from list by blaine.gmane.org with local (Exim 4.89) (envelope-from ) id 1hRB0N-000Hno-0l for pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org; Thu, 16 May 2019 09:40:43 +0200 X-Injected-Via-Gmane: http://gmane.org/ Cancel-Lock: sha1:fSz40KnUBiBxol9W/I2E43dELm0= X-Original-Sender: gtp-pandoc-discuss@m.gmane.org X-Original-Authentication-Results: gmr-mx.google.com; spf=neutral (google.com: 195.159.176.226 is neither permitted nor denied by best guess record for domain of gtp-pandoc-discuss@m.gmane.org) smtp.mailfrom=gtp-pandoc-discuss@m.gmane.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=163.com Precedence: list Mailing-list: list pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org; contact pandoc-discuss+owners-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org List-ID: X-Google-Group-Id: 1007024079513 List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , Xref: news.gmane.org gmane.text.pandoc:22729 Archived-At: I checked the manual, `smart` has effect on quotes and dashes. Instead of disabling smart, I have to escape it to minimize the effect. BTW, if it is for the title value ``` --- title: Children's Cognitive Ability --- ``` I get the expected result withouth escaping the quote or disabling smart: ``` \title{Children's Cognitive Ability} ``` Pandoc deals with it differently from a lua filter? John MacFarlane writes: > YAML metadata fields are interpreted as markdown. > > You can escape it to prevent "smartification": > > Children\'s Cognitive Ability > > Or disable smartification globally by using `-f > markdown-smart` on the command line. > > jiewuza writes: > >> I have some meta value like >> ``` >> --- >> test: Children's Cognitive Ability >> --- >> ``` >> >> In my lua filter: >> ``` >> function Meta(meta) >> for k, v in pairs(meta) do >> if k=3D=3D'test' then >> print(pandoc.utils.stringify(v)) >> end >> end >> end >> ``` >> >> I find it prints >> ``` >> Children=E2=80=99s Cognitive Ability >> ``` >> >> I want to keep the single quote as it is. What should I do? >> >> --=20 >> You received this message because you are subscribed to the Google Group= s "pandoc-discuss" group. >> To unsubscribe from this group and stop receiving emails from it, send a= n email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org >> To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org >> To view this discussion on the web visit https://groups.google.com/d/msg= id/pandoc-discuss/m2mujn7txr.fsf%40163.com. >> For more options, visit https://groups.google.com/d/optout. --=20 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 e= mail to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/= pandoc-discuss/m2ftpe7sos.fsf%40163.com. For more options, visit https://groups.google.com/d/optout.