From 4f977dbe57af01fd9542dc569e87d0752d0aaa1b Mon Sep 17 00:00:00 2001 From: James Shubin Date: Fri, 6 Jun 2025 00:33:39 -0400 Subject: [PATCH] lang: Use the source finder wherever we can This was easy to add and it works great! --- lang/lang.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lang/lang.go b/lang/lang.go index 0baa9caa..6ecf4b76 100644 --- a/lang/lang.go +++ b/lang/lang.go @@ -189,9 +189,9 @@ func (obj *Lang) Init(ctx context.Context) error { LexParser: parser.LexParse, Downloader: nil, // XXX: is this used here? StrInterpolater: interpolate.StrInterpolate, - SourceFinder: func(string) ([]byte, error) { + SourceFinder: func(p string) ([]byte, error) { // We're running a bundle as part of a deploy. - return nil, fmt.Errorf("not implemented") // XXX: read from the fs? + return output.FS.ReadFile(p) }, //Local: obj.Local, // TODO: do we need this? //World: obj.World, // TODO: do we need this?