view tests/test_resources.nim @ 820:85470ae0f728

add: option to walk resources in a specific directory
author Sam <sam@basx.dev>
date Sun, 24 Sep 2023 00:21:42 +0700
parents 275ac4cdf7e0
children 1ab09f8cc68d
line wrap: on
line source

import std/streams

import semicongine

proc main() =
  echo "Mods available: ", modList()
  for modName in modList():
    echo modName, ":"
    selectedMod = modName
    for i in walkResources():
      echo "  ", i, ": ", loadResource(i).readAll().len

when isMainModule:
  main()