Fixing some small things. And making some design decisions.
This commit is contained in:
parent
d5cfdcadc1
commit
cc6035eef0
@ -1,4 +1,4 @@
|
||||
import "./import.binc";
|
||||
import "./import";
|
||||
|
||||
enum TestEnum {
|
||||
VAL1,
|
@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "@hibas123/SimpleRPC",
|
||||
"name": "@hibas123/jrpcgen",
|
||||
"version": "1.0.0",
|
||||
"main": "lib/index.js",
|
||||
"license": "MIT",
|
||||
"packageManager": "yarn@3.1.1",
|
||||
"scripts": {
|
||||
"start": "ts-node src/index.ts",
|
||||
"test": "npm run start -- compile examples/example.binc -o=ts-node:examples/out && ts-node examples/test.ts"
|
||||
"test": "npm run start -- compile examples/example.jrpc -o=ts-node:examples/out && ts-node examples/test.ts"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/debug": "^4.1.7",
|
||||
|
@ -96,7 +96,7 @@ function processFile(ctx: ProcessContext, file: string): Parsed | null {
|
||||
.map((statement) => {
|
||||
if (statement.type == "import") {
|
||||
const base = Path.dirname(file);
|
||||
const resolved = Path.resolve(Path.join(base, statement.path));
|
||||
const resolved = Path.resolve(Path.join(base, statement.path + ".jrpc"));
|
||||
return processFile(ctx, resolved);
|
||||
} else {
|
||||
return statement;
|
||||
|
Loading…
Reference in New Issue
Block a user