~exelotl/natu

Add doImport and natuSharedDir v1 APPLIED

Benjamin Johnson: 1
 Add doImport and natuSharedDir

 1 files changed, 5 insertions(+), 0 deletions(-)
Export patchset (mbox)
How do I use this?

Copy & paste the following snippet into your terminal to import this patchset into git:

curl -s https://lists.sr.ht/~exelotl/natu/patches/48407/mbox | git am -3
Learn more about email & git

[PATCH] Add doImport and natuSharedDir Export this patch

---
 natu/private/common.nim | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/natu/private/common.nim b/natu/private/common.nim
index b72bc6c..2dcebab 100644
--- a/natu/private/common.nim
+++ b/natu/private/common.nim
@@ -8,9 +8,14 @@ const natuPlatform* {.strdefine.} = "gba"

const natuOutputDir* {.strdefine.} = ""
const natuConfigDir* {.strdefine.} = ""
const natuSharedDir* {.strdefine.} = ""

when natuOutputDir == "": {.error: "natuOutputDir is not set.".}
when natuConfigDir == "": {.error: "natuConfigDir is not set.".}
when natuSharedDir == "": {.error: "natuSharedDir is not set.".}

template doInclude*(path: static string) =
  include `path`

template doImport*(path: static string) =
  import `path`
-- 
2.31.1