# HG changeset patch # User Sam # Date 1695489702 -25200 # Node ID 85470ae0f72890c674ccf05b907a88ee62bddb7e # Parent 4c8bab2d1cc51236e196a11baa84cb98fe0f7b12 add: option to walk resources in a specific directory diff -r 4c8bab2d1cc5 -r 85470ae0f728 src/semicongine/resources.nim --- a/src/semicongine/resources.nim Sat Sep 23 23:05:22 2023 +0700 +++ b/src/semicongine/resources.nim Sun Sep 24 00:21:42 2023 +0700 @@ -139,6 +139,7 @@ proc modList*(): seq[string] = modList_intern() -iterator walkResources*(): string = +iterator walkResources*(dir=""): string = for i in walkResources_intern(): - yield i + if i.startsWith(dir): + yield i