1
0
This commit is contained in:
Zef Hemel 2022-05-04 16:26:52 +02:00
parent a6eff1e371
commit 1bb8ab3056
4 changed files with 8 additions and 6 deletions

2
package-lock.json generated
View File

@ -9995,7 +9995,7 @@
"yargs": "^17.3.1" "yargs": "^17.3.1"
}, },
"bin": { "bin": {
"silverbullet": "dist/server.js" "silverbullet": "dist/server/server.js"
}, },
"devDependencies": { "devDependencies": {
"@parcel/packager-raw-url": "2.3.2", "@parcel/packager-raw-url": "2.3.2",

View File

@ -7,10 +7,10 @@
"version": "0.0.1", "version": "0.0.1",
"license": "MIT", "license": "MIT",
"bin": { "bin": {
"silverbullet": "./dist/server.js" "silverbullet": "./dist/server/server.js"
}, },
"scripts": { "scripts": {
"start": "nodemon -w dist --exec 'node --enable-source-maps dist/server/server.js --token abc ../../pages'", "start": "nodemon -w dist --exec 'silverbullet ../../pages'",
"test": "jest dist/test" "test": "jest dist/test"
}, },
"targets": { "targets": {

View File

@ -1,4 +1,4 @@
#!/usr/bin/env node #!/usr/bin/env node --enable-source-maps
import { nodeModulesDir } from "@plugos/plugos/environments/node_sandbox"; import { nodeModulesDir } from "@plugos/plugos/environments/node_sandbox";
import { preloadModules } from "@silverbulletmd/common/preload_modules"; import { preloadModules } from "@silverbulletmd/common/preload_modules";
import { realpathSync } from "fs"; import { realpathSync } from "fs";
@ -18,7 +18,9 @@ let args = yargs(hideBin(process.argv))
.parse(); .parse();
if (!args._.length) { if (!args._.length) {
console.error("Usage: silverbullet <path-to-pages>"); console.error(
"Usage: silverbullet [--port 3000] [--token mysecrettoken] <path-to-pages>"
);
process.exit(1); process.exit(1);
} }

View File

@ -64,7 +64,7 @@ if (navigator.serviceWorker) {
}); });
} else { } else {
console.log( console.log(
"No launching service worker (not present, maybe because not running on localhost or over SSL" "No launching service worker (not present, maybe because not running on localhost or over SSL)"
); );
} }
// } // }