diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..3d8db14 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/processed diff --git a/README.md b/README.md index 413024a..e139853 100644 --- a/README.md +++ b/README.md @@ -2,4 +2,4 @@ 2013-related scripts, tools, and other goodies -After installing Aftman and running `aftman install`, run `lune run compile.luau` to compile the corescripts and libraries from this directory to ./corescripts/processed. +After installing Aftman and running `aftman install`, run `lune run compile.luau` to compile the corescripts and libraries from this directory to ./processed. diff --git a/compile.luau b/compile.luau index bc41683..f10aecd 100644 --- a/compile.luau +++ b/compile.luau @@ -22,15 +22,9 @@ local libraryCores = { local otherCores = {} local plugins = {} --- Allow for running from the base or corescripts directories -local cwd = process.cwd -local fromCoresDir = not not string.match(cwd, "corescripts/$") -local coresDir = if fromCoresDir then "." else "./corescripts" - --- local normalCoresDir = if fromCoresDir then "./luau" else "./corescripts/luau" -local normalCoresDir = `{coresDir}/luau` -local normalPluginsDir = `{coresDir}/terrain plugins` -local outputDir = `{coresDir}/processed` +local normalCoresDir = "./luau" +local normalPluginsDir = "./terrain plugins" +local outputDir = "./processed" for _, core in ipairs(fs.readDir(normalCoresDir)) do table.insert( @@ -43,9 +37,7 @@ for _, core in ipairs(fs.readDir(normalPluginsDir)) do table.insert(plugins, core) end -local pluginsDir = if fromCoresDir - then "../Client deployer" - else "./Client deployer" +local pluginsDir = "./Client deployer" -- not here but.. ya get the idea local function processCores( scripts: { string }, @@ -54,9 +46,7 @@ local function processCores( config: "lines" | "dense", libraries: boolean? ) - local configFile = if fromCoresDir - then `../{config}.json5` - else `{config}.json5` + local configFile = `{config}.json5` local w = waiter(#scripts) @@ -70,7 +60,7 @@ local function processCores( "process", "-c", configFile, - `{coresDir}/{startDir}/{core}`, + `./{startDir}/{core}`, `{endDir}/{newCore}`, })