From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.text.pandoc/33148 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: "ch_...-S0/GAf8tV78@public.gmane.org" Newsgroups: gmane.text.pandoc Subject: requiring other lua files from parent directories from within filters Date: Tue, 3 Oct 2023 09:17:04 -0700 (PDT) Message-ID: Reply-To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_Part_36646_2093324928.1696349824817" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="19178"; mail-complaints-to="usenet@ciao.gmane.io" To: pandoc-discuss Original-X-From: pandoc-discuss+bncBD65VBUXVUPBBAX56CUAMGQEVYHG37Q-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Tue Oct 03 18:17:10 2023 Return-path: Envelope-to: gtp-pandoc-discuss@m.gmane-mx.org Original-Received: from mail-oa1-f61.google.com ([209.85.160.61]) by ciao.gmane.io with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1qni57-0004b8-Gd for gtp-pandoc-discuss@m.gmane-mx.org; Tue, 03 Oct 2023 18:17:09 +0200 Original-Received: by mail-oa1-f61.google.com with SMTP id 586e51a60fabf-1bf00f8cf77sf1513283fac.0 for ; Tue, 03 Oct 2023 09:17:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20230601; t=1696349828; x=1696954628; darn=m.gmane-mx.org; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:x-original-sender :mime-version:subject:message-id:to:from:date:sender:from:to:cc :subject:date:message-id:reply-to; bh=28pNMcQ/KwTKkIW2yRDBvcKsNtAguU5WDFUfbYhfLdM=; b=DSUZoB6Q4NNHZ8YrRAjAgRQbyvy/xQKtLLrtzaS7o2Vwf4xx272p9i3Peow3P9YLxZ ewMwhbok6F4MpNFxngMeEPZOCUehaFlg+WvXPta2KsOnv3893dp06+5SZw8gDY4O3jkP Ch9u6CQCZUZbN+IstY7fWiyCwJFrgHbCDz32zfL+0R0Ica6L8Tc0petol/RV9FCElQcN aNJj4QqoHCAnK/XKYGdcWioXPpFIXvgwR2R3gUM0yIvazQ10vtUmk7S9lIBfR8x3UePP dnURvQ3hzF4YGwWrTG0fXmj250W9b2tWOwXiGOYT0GMOANmMTMbN9Nf8IjpbXt5gVK7U rlhQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1696349828; x=1696954628; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence:reply-to :x-original-sender:mime-version:subject:message-id:to:from:date :x-beenthere:x-gm-message-state:sender:from:to:cc:subject:date :message-id:reply-to; bh=28pNMcQ/KwTKkIW2yRDBvcKsNtAguU5WDFUfbYhfLdM=; b=c4v5kxxl7l0ru1g+7Vt6n8WMGgBQE77RFJFPCEwyVWn7SaTomFSyxTIXr9QWtcNLB/ ihqO2n9zR1dHTqtTEUHoF1G3jV7pI5Hx4uxYasbOiASbgsGo8W3LLTqYujkIGeH6goun i0N2WyzJOOVUODznEDeWETrODiK19uI0VJtSqSXtgmMYgRBV1lo4cnMOd4OoYm4ZPBs7 0o/Na7PugC2AnXDWA88CA6LwHpUIkjqkd0EcH1u5hq6YjHfMCK5+KlTaqh4g2BurLbyK Tg2a/2FN8wpWzUONAG9S09Dnmm+xPkWStJtcQSSIbs3qiKwCVqUqE1Uz0lbFW716c96e Original-Sender: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org X-Gm-Message-State: AOJu0YwiY/c2/THQCHDY1Dz1fnNtDcq3ezCx+1lwm3jScCIECehgBdO+ KkT3Eb6VK6LxHuXCYru2HRE= X-Google-Smtp-Source: AGHT+IElQLr1T9qJUB7IZj+McL+woe1X6ulQcqRQXpTF5G9Zij/jDR5xSM9QxrfzzIDDaihqqkB1qA== X-Received: by 2002:a05:6871:5ce:b0:1d0:c53c:19e5 with SMTP id v14-20020a05687105ce00b001d0c53c19e5mr71793oan.39.1696349828404; Tue, 03 Oct 2023 09:17:08 -0700 (PDT) X-BeenThere: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-Received: by 2002:a05:6870:649f:b0:1bf:dcb1:699 with SMTP id cz31-20020a056870649f00b001bfdcb10699ls624559oab.2.-pod-prod-06-us; Tue, 03 Oct 2023 09:17:05 -0700 (PDT) X-Received: by 2002:a05:6870:6289:b0:1dd:39ce:e25c with SMTP id s9-20020a056870628900b001dd39cee25cmr26866oan.3.1696349825256; Tue, 03 Oct 2023 09:17:05 -0700 (PDT) X-Original-Sender: ch_819-S0/GAf8tV78@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:33148 Archived-At: ------=_Part_36646_2093324928.1696349824817 Content-Type: multipart/alternative; boundary="----=_Part_36647_1251997566.1696349824817" ------=_Part_36647_1251997566.1696349824817 Content-Type: text/plain; charset="UTF-8" I have the following file structure: inner/script.lua library/library.lua I try to load the library from within the script library = require("../library/library.lua") but get an error when running inside inner: pandoc lua script.lua Error running Lua: script.lua:1: module '../library/library.lua' not found: no field package.preload['../library/library.lua'] no file '/usr/local/share/lua/5.4////library/library/lua.lua' no file '/usr/local/share/lua/5.4////library/library/lua/init.lua' no file '/usr/local/lib/lua/5.4////library/library/lua.lua' no file '/usr/local/lib/lua/5.4////library/library/lua/init.lua' no file './///library/library/lua.lua' no file './///library/library/lua/init.lua' no file '/usr/local/lib/lua/5.4////library/library/lua.so' no file '/usr/local/lib/lua/5.4/loadall.so' no file './///library/library/lua.so' no file '/usr/local/lib/lua/5.4/.so' no file '/usr/local/lib/lua/5.4/loadall.so' no file './.so' stack traceback: script.lua:1: in main chunk -- 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/ee1ceb10-3318-48d0-ae1a-0ca538a3cdc9n%40googlegroups.com. ------=_Part_36647_1251997566.1696349824817 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
I have the following file structure:

inner/script.lua
library/library.lua

I try to load the library fro= m within the script

=
library =3D req= uire("../library/library.lua")

but get an= error when running inside inner: = pandoc lua script.lua

Error running Lua:
script.lua:1: module '../library/library.lua' no= t found:
no field package.pr= eload['../library/library.lua']
no file '/usr/local/share/lua/5.4////library/library/lua.lua'
no file '/usr/local/share/lua/5.4////= library/library/lua/init.lua'
no file '/usr/local/lib/lua/5.4////library/library/lua.lua'
no file '/usr/local/lib/lua/5.4////librar= y/library/lua/init.lua'
no f= ile './///library/library/lua.lua'
= no file './///library/library/lua/init.lua'
no file '/usr/local/lib/lua/5.4////library/library/l= ua.so'
no file '/usr/local/l= ib/lua/5.4/loadall.so'
no fi= le './///library/library/lua.so'
no file '/usr/local/lib/lua/5.4/.so'
no file '/usr/local/lib/lua/5.4/loadall.so'
no file './.so'
stack traceback:
<= span style=3D"white-space: pre;">
script.lua:1: in main chunk
=

--
You received this message because you are subscribed to the Google Groups &= quot;pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an e= mail to pand= oc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To view this discussion on the web visit https://groups.google.com/d= /msgid/pandoc-discuss/ee1ceb10-3318-48d0-ae1a-0ca538a3cdc9n%40googlegroups.= com.
------=_Part_36647_1251997566.1696349824817-- ------=_Part_36646_2093324928.1696349824817--