From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.text.pandoc/29200 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: John MacFarlane Newsgroups: gmane.text.pandoc Subject: Re: Absolute path in for loop / output? Date: Tue, 07 Sep 2021 10:06:33 -0700 Message-ID: References: <78489a20-5148-4826-ab6a-b43fa48938d4n@googlegroups.com> 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: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="9117"; mail-complaints-to="usenet@ciao.gmane.io" To: Martin Post , pandoc-discuss Original-X-From: pandoc-discuss+bncBCJZJHG45QDBBJ5Y32EQMGQEVVLPRMA-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Tue Sep 07 19:07:00 2021 Return-path: Envelope-to: gtp-pandoc-discuss@m.gmane-mx.org Original-Received: from mail-qv1-f59.google.com ([209.85.219.59]) by ciao.gmane.io with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1mNeYl-000274-B7 for gtp-pandoc-discuss@m.gmane-mx.org; Tue, 07 Sep 2021 19:06:59 +0200 Original-Received: by mail-qv1-f59.google.com with SMTP id jq13-20020ad45fcd000000b0036c273baa23sf18137221qvb.8 for ; Tue, 07 Sep 2021 10:06:59 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1631034418; cv=pass; d=google.com; s=arc-20160816; b=Pf29p94lLoSmeS6U+yr0X6etukfd2vMLd43hXGRdzbE/SbSCY5eLoMjGeBl19UXX8w QlSj4uF1PoqTUNyYyw8dwv42Ne5MOzLk4cjbgf1AzQxDyqRrNu7oUEFO2m4hnQ2bCRp6 7ZmuZfByqFmDVdaT63sb0kLSp6GRRjkw2AHIM7m77IYW1FcU8OxPtKKSkYZWk16pd5z9 1dfzwVYyF2JzEI8d9hr3AQAC5mgQXiH3O2Wn2k+04uwr/DaI13FnNb3aLtX79dKOXdk1 Neq78H6dT2U/yo1kIYOEqN0eZNLTImlQghOY5fvgMGt7524k4ooqqmB9eU1POUgrQ/aU Kf3g== 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:content-transfer-encoding :mime-version:message-id:date:references:in-reply-to:subject:to:from :sender:dkim-signature; bh=c/kuX9Q8DqT0U+Tb8//MuyuNd3jsoEa8YR60UbRl35w=; b=NkvozXsAVIUdQrxuXdvd7lQ1QFVnbZkg6LYDkvh8/gVKln/iqohFYMe+PAnUOBV2Ki uSRCUv7/+zzdeh1Bt1BYtj3xm9hC4AzjHZFIG4v89FYsJLd4H+HHwK8WMR/h2fApiJCH CQdqgZSD0ZVFNktAB2YZKp1Qod+1nBJ1o/pwkhNv6xkKin4ZwpmX5zGRlge+cAUz0yEQ G/SFiNnYkf25y4pwwfRS5nVa28S2T/gVVz8XyKl8K4si16EGIPE1baSLmWHMbvk1mBjF 4S1TOw0vSkrKBjMQvY2HHGzwNfAXi3rAxmZPU0YWrQmun2VupdY+UcGa5Hmms4JDEvvh /DBw== ARC-Authentication-Results: i=2; gmr-mx.google.com; dkim=pass header.i=@berkeley-edu.20150623.gappssmtp.com header.s=20150623 header.b=g4XKTA3h; spf=pass (google.com: domain of jgm-TVLZxgkOlNX2fBVCVOL8/A@public.gmane.org designates 2607:f8b0:4864:20::42b as permitted sender) smtp.mailfrom=jgm-TVLZxgkOlNX2fBVCVOL8/A@public.gmane.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20210112; h=sender:from:to:subject:in-reply-to:references:date:message-id :mime-version:content-transfer-encoding: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=c/kuX9Q8DqT0U+Tb8//MuyuNd3jsoEa8YR60UbRl35w=; b=ieYZvK8DrRj4N1UsQcDoNwQpjWL8Nx3z3Fy45aOZHzugDUU8ZyamKQI6LDHnKuKpbt TKBuJ7++znJU70JWL1CpMdlXTyAGUX4rkifHdpN9HrGYg+QoyFeOTmd16EtAHGVJCXKs aIWTUtO0ttKlhjUZIdfSnTPDWu8OCm4CmHF4803H1Z+ZFVvuF45aRk4f+8Fd6lCKpxW2 wymbOInftLPth1aFGH34K0zX1so+eAqOLcEDhiJ2ZZUokvbIC7QWz6WcxcAb4TWgokfw 0k6HczFRAcTgCfBZS+xpn5r1NxLmncS/C9rvEOjoWenjaTmn5+xsUKS+zkmhvAFnFPCt 2ZtQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=sender:x-gm-message-state:from:to:subject:in-reply-to:references :date:message-id:mime-version:content-transfer-encoding :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=c/kuX9Q8DqT0U+Tb8//MuyuNd3jsoEa8YR60UbRl35w=; b=t0G18IY1tYwNJ9blepjI7fcZnE0xM4Hjw6Pt8fYvA6fs737MyLnaxqC0QOADLraZ6n 22erwVmGftNIU5RIc8s4WRpoCwPEtglw6DU/hFMxUGTZ09qM0fv8bAAuNYDRdwKBXMTo GNfcUYG6FtdDsDuvfO+jK9eb+/xid6tWFHevEONXvmy3CqFrEOXKkqNNBGzLKKqTNgEI nFY6BMGp0v0iZn2Q4cQ6bE6FrZBr72mlj3qajkKUKfPMbL4kTNfPUk4EWvJt158BKZas /Bv4ateaNGXtazwscimyVh32InM0NpcsXFSV0wk0F47DUBpZDeEgJdut4Ng13Q8bN7/A Original-Sender: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org X-Gm-Message-State: AOAM532JM6PeAtuQBBIPb0UTSfqph32x/PWf7ictthPYoTIdLIeXBjqu EE0M6aM5H3beRZ1JWqzu2AU= X-Google-Smtp-Source: ABdhPJzSmajXCHSgvPGR30T0pUtd6XDQ48d1XTbYUAVSDyN2FcT1Ln3nA13A96Xdq4NfBsmsFKJZ6g== X-Received: by 2002:a05:620a:1aa6:: with SMTP id bl38mr16602862qkb.36.1631034408831; Tue, 07 Sep 2021 10:06:48 -0700 (PDT) X-BeenThere: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-Received: by 2002:a05:6214:21cb:: with SMTP id d11ls3600576qvh.1.gmail; Tue, 07 Sep 2021 10:06:47 -0700 (PDT) X-Received: by 2002:a0c:8150:: with SMTP id 74mr17951120qvc.31.1631034406169; Tue, 07 Sep 2021 10:06:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1631034406; cv=none; d=google.com; s=arc-20160816; b=GrVDyn3nrYbf03hf084Q7DtK8ojPMDfUpWUVX2xQ/5W6hl2shhuSEQCwWXGYd48w3W p39PAjU769vEcd+FjPWpHXRP9d96eyChpd53My7tbX3W2x110TwzECM4xeDshtNBMwrF F70hDjXPHCJb1kyrOxOIDyP/l3Iep2BuJWx5TfyTXLJcpD6gyY3mbdV7lX1U3L/Mejus 9THxoznLKYqsPbKZrpEw/jfYczPAFgEgnTIruXEyVgWy7LoajL7Gnb4LeJ9sSLMZcyJN AipGlbizWUGl9hH34dWJZOI37Ii+12z9FoarmV8isT51kDCeKb56u1AmVm1nwHMTVCgy jnvw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:message-id:date:references :in-reply-to:subject:to:from:dkim-signature; bh=tXSa5onm/z/KPVrp6hZ1qe8qmmAtrPCnvrrX7Cxe02U=; b=H8QCxq/L4jGlkTV80Rio0wdRqe9CnrODFh4zfvfRc/cBYsCFnNaBEo7IhP3zeW+SHS 0J8icw2iYLH+OGGtfLYDED3aehMyWRoN71yG8AeAEhphAqRk0x4D49+gA0R8LIZlK5wi KbNP59D/3ybFfMhexEMCJJLyt9ESJl3gVi91bBeoO2hV6/PWYFKOYrRglu7XgiNdHtgV krt1ORsH2NRWW6DtfPqRMgGFORcfBqeqkgZMJzDlU+Q6qnoJcVwMahcYk5Ud0HbpZw07 9Y7trP2piK13yzZob37wSgMeh2uKF/CDAnCZ5AB0RC4Bbqg2vTyPdB6S4Btndo8HsLUV 1qSA== ARC-Authentication-Results: i=1; gmr-mx.google.com; dkim=pass header.i=@berkeley-edu.20150623.gappssmtp.com header.s=20150623 header.b=g4XKTA3h; spf=pass (google.com: domain of jgm-TVLZxgkOlNX2fBVCVOL8/A@public.gmane.org designates 2607:f8b0:4864:20::42b as permitted sender) smtp.mailfrom=jgm-TVLZxgkOlNX2fBVCVOL8/A@public.gmane.org Original-Received: from mail-pf1-x42b.google.com (mail-pf1-x42b.google.com. [2607:f8b0:4864:20::42b]) by gmr-mx.google.com with ESMTPS id t12si678146qtn.4.2021.09.07.10.06.46 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 07 Sep 2021 10:06:46 -0700 (PDT) Received-SPF: pass (google.com: domain of jgm-TVLZxgkOlNX2fBVCVOL8/A@public.gmane.org designates 2607:f8b0:4864:20::42b as permitted sender) client-ip=2607:f8b0:4864:20::42b; Original-Received: by mail-pf1-x42b.google.com with SMTP id f65so5093989pfb.10 for ; Tue, 07 Sep 2021 10:06:46 -0700 (PDT) X-Received: by 2002:aa7:80d1:0:b029:399:ce3a:d617 with SMTP id a17-20020aa780d10000b0290399ce3ad617mr21784785pfn.16.1631034405224; Tue, 07 Sep 2021 10:06:45 -0700 (PDT) Original-Received: from johnmacfarlane.net (li55-134.members.linode.com. [74.82.3.134]) by smtp.gmail.com with ESMTPSA id gk12sm3057166pjb.39.2021.09.07.10.06.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Sep 2021 10:06:44 -0700 (PDT) Original-Received: by johnmacfarlane.net (Postfix, from userid 1000) id B3FBAA1A8; Tue, 7 Sep 2021 13:06:33 -0400 (EDT) In-Reply-To: <78489a20-5148-4826-ab6a-b43fa48938d4n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org> X-Original-Sender: jgm-TVLZxgkOlNX2fBVCVOL8/A@public.gmane.org X-Original-Authentication-Results: gmr-mx.google.com; dkim=pass header.i=@berkeley-edu.20150623.gappssmtp.com header.s=20150623 header.b=g4XKTA3h; spf=pass (google.com: domain of jgm-TVLZxgkOlNX2fBVCVOL8/A@public.gmane.org designates 2607:f8b0:4864:20::42b as permitted sender) smtp.mailfrom=jgm-TVLZxgkOlNX2fBVCVOL8/A@public.gmane.org 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.io gmane.text.pandoc:29200 Archived-At: Here $f is going to be an absolute path. So you should not add a directory. Just use -o "${f%.md}.htm"; \ Martin Post writes: > I need to use Pandoc with absolute input and output paths in a shell=20 > script, like so: > > #!/bin/bash > > for f in "/users/myname/desktop/test/input/"*.md; \ > do \ > pandoc "$f" \ > --standalone \ > -o "/users/myname/desktop/test/output/"${f%.md}.htm; \ > done > > =E2=80=A6 which gives an error: > > /users/myname/desktop/test/output//users/myname/desktop/test/input/1.htm:= =20 > openFile: does not exist (No such file or directory) > > (Removing the output path will render the files in the source directory, = as=20 > expected.) > > I realise the problem is probably my limited understanding of how the she= ll=20 > works, not something with Pandoc. I still hope someone here can help. Tha= nk=20 > you. > > --=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= email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To view this discussion on the web visit https://groups.google.com/d/msgi= d/pandoc-discuss/78489a20-5148-4826-ab6a-b43fa48938d4n%40googlegroups.com. --=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 view this discussion on the web visit https://groups.google.com/d/msgid/= pandoc-discuss/m25yvc48o6.fsf%40MacBook-Pro-2.hsd1.ca.comcast.net.