Fixes
This commit is contained in:
+3
-39
@@ -3,46 +3,10 @@
|
||||
// For a full list of overridable settings, and general information on folder-specific settings,
|
||||
// see the documentation: https://zed.dev/docs/configuring-zed#settings-files
|
||||
{
|
||||
"lsp": {
|
||||
"deno": {
|
||||
"settings": {
|
||||
"deno": {
|
||||
"enable": true
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"languages": {
|
||||
"JavaScript": {
|
||||
"language_servers": [
|
||||
"deno",
|
||||
"!typescript-language-server",
|
||||
"!vtsls",
|
||||
"!eslint"
|
||||
],
|
||||
"formatter": "language_server"
|
||||
},
|
||||
"TypeScript": {
|
||||
"language_servers": [
|
||||
"deno",
|
||||
"!typescript-language-server",
|
||||
"!vtsls",
|
||||
"!eslint"
|
||||
],
|
||||
"formatter": "language_server"
|
||||
},
|
||||
"TSX": {
|
||||
"language_servers": [
|
||||
"deno",
|
||||
"!typescript-language-server",
|
||||
"!vtsls",
|
||||
"!eslint"
|
||||
],
|
||||
"formatter": "language_server"
|
||||
},
|
||||
"Markdown": {
|
||||
"format_on_save": "off",
|
||||
"remove_trailing_whitespace_on_save": false
|
||||
}
|
||||
}
|
||||
"remove_trailing_whitespace_on_save": false,
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
@@ -96,6 +96,8 @@ make check
|
||||
make fmt
|
||||
# Run all tests
|
||||
make test
|
||||
# Run benchmarks
|
||||
make bench
|
||||
```
|
||||
|
||||
### Build a docker container
|
||||
|
||||
@@ -21,7 +21,7 @@ import { Space } from "./space.ts";
|
||||
// Use `type` for type-only imports (part of the lint rules)
|
||||
import type { Command } from "./types/command.ts";
|
||||
|
||||
// Use package-prefixed absolute when available (defined in deno.json)
|
||||
// Use package-prefixed absolute when available (defined in package.json)
|
||||
import { sleep } from "@silverbulletmd/silverbullet/lib/async";
|
||||
```
|
||||
|
||||
|
||||
+2
-4
@@ -1,7 +1,4 @@
|
||||
use strict;
|
||||
use warnings;
|
||||
use File::Copy;
|
||||
import { bench } from "vitest";
|
||||
import { bench, expect } from "vitest";
|
||||
import { readFile } from "node:fs/promises";
|
||||
import { parse } from "../client/space_lua/parse.ts";
|
||||
import { luaBuildStandardEnv } from "../client/space_lua/stdlib.ts";
|
||||
@@ -77,6 +74,7 @@ bench("[Lua] Lume functions tests", async () => {
|
||||
async function runLuaTest(luaPath: string) {
|
||||
const luaFile = await readFile(
|
||||
fileURLToPath(new URL(luaPath, import.meta.url)),
|
||||
"utf-8",
|
||||
);
|
||||
const chunk = parse(luaFile, {});
|
||||
const env = new LuaEnv(luaBuildStandardEnv());
|
||||
|
||||
@@ -16,7 +16,6 @@ program
|
||||
.option("--info", "Print out size info per function", false)
|
||||
.option("-w, --watch", "Watch for changes and rebuild", false)
|
||||
.option("--dist <path>", "Folder to put the resulting .plug.json file into", ".")
|
||||
.option("-c, --config <path>", "Path to deno.json file to use")
|
||||
.option("--runtimeUrl <url>", "URL to worker_runtime.ts to use")
|
||||
.action(async (manifestPaths: string[], options: any) => {
|
||||
await plugCompileCommand(
|
||||
@@ -24,7 +23,6 @@ program
|
||||
dist: options.dist,
|
||||
debug: options.debug,
|
||||
info: options.info,
|
||||
config: options.config,
|
||||
runtimeUrl: options.runtimeUrl,
|
||||
},
|
||||
...manifestPaths,
|
||||
|
||||
@@ -50,7 +50,6 @@ if (isMain) {
|
||||
{
|
||||
debug: args.debug as boolean | undefined,
|
||||
info: args.info as boolean | undefined,
|
||||
configPath: fileURLToPath(new URL("deno.json", import.meta.url)),
|
||||
},
|
||||
);
|
||||
esbuild.stop();
|
||||
|
||||
@@ -28,8 +28,6 @@ const workerRuntimeUrl = `data:text/javascript;charset=utf-8,${encodeURIComponen
|
||||
export type CompileOptions = {
|
||||
debug?: boolean;
|
||||
runtimeUrl?: string;
|
||||
// path to config file
|
||||
configPath?: string;
|
||||
// Print info on bundle size
|
||||
info?: boolean;
|
||||
};
|
||||
@@ -194,11 +192,10 @@ export function patchDenoLibJS(code: string): string {
|
||||
}
|
||||
|
||||
export async function plugCompileCommand(
|
||||
{ dist, debug, info, config, runtimeUrl }: {
|
||||
{ dist, debug, info, runtimeUrl }: {
|
||||
dist: string;
|
||||
debug: boolean;
|
||||
info: boolean;
|
||||
config?: string;
|
||||
runtimeUrl?: string;
|
||||
},
|
||||
...manifestPaths: string[]
|
||||
@@ -210,7 +207,6 @@ export async function plugCompileCommand(
|
||||
debug: debug,
|
||||
info: info,
|
||||
runtimeUrl,
|
||||
configPath: config,
|
||||
},
|
||||
);
|
||||
esbuild.stop();
|
||||
|
||||
@@ -1,140 +0,0 @@
|
||||
{
|
||||
"name": "@silverbulletmd/silverbullet",
|
||||
"version": "2.4.1",
|
||||
"tasks": {
|
||||
"build": "make clean && deno run -A build_plugs_libraries.ts && deno run -A build_client.ts",
|
||||
"build-production": "deno task build --production",
|
||||
"build-plug-compile": "deno run -A --no-lock build_plug_compile.ts",
|
||||
"check": "find . -name '*.ts*' -not -path \"*/node_modules/*\" | xargs deno check",
|
||||
"checks": "deno task check && deno task lint && deno task test",
|
||||
"lint": "deno lint --fix",
|
||||
"fmt": "deno fmt",
|
||||
"test": "deno run -A npm:vitest run",
|
||||
"test-deno-old": "deno test -A --fail-fast",
|
||||
"bench": "deno bench -A",
|
||||
"plugs": "deno run -A --no-lock build_plugs_libraries.ts"
|
||||
},
|
||||
"publish": {
|
||||
"exclude": ["website", "CHANGELOG.md", "**/*.md"]
|
||||
},
|
||||
"lint": {
|
||||
"exclude": ["dist", "client_bundle", "website"],
|
||||
"rules": {
|
||||
"exclude": ["no-explicit-any", "no-slow-types", "jsx-boolean-value"]
|
||||
}
|
||||
},
|
||||
"fmt": {
|
||||
"exclude": [
|
||||
"dist*",
|
||||
"client_bundle/*",
|
||||
"website",
|
||||
"**/*.md",
|
||||
"**/*.html",
|
||||
"**/*.js",
|
||||
"**/*.json"
|
||||
]
|
||||
},
|
||||
"compilerOptions": {
|
||||
"lib": ["dom", "dom.iterable", "dom.asynciterable", "deno.ns"],
|
||||
"jsx": "react-jsx",
|
||||
"jsxImportSource": "npm:preact@10.28.2"
|
||||
},
|
||||
"exports": {
|
||||
"./syscall": "./plug-api/syscall.ts",
|
||||
"./syscalls": "./plug-api/syscalls.ts",
|
||||
"./constants": "./plug-api/constants.ts",
|
||||
"./lib/json": "./plug-api/lib/json.ts",
|
||||
"./lib/tree": "./plug-api/lib/tree.ts",
|
||||
"./lib/ref": "./plug-api/lib/ref.ts",
|
||||
"./lib/resolve": "./plug-api/lib/resolve.ts",
|
||||
"./lib/dates": "./plug-api/lib/dates.ts",
|
||||
"./lib/async": "./plug-api/lib/async.ts",
|
||||
"./lib/crypto": "./plug-api/lib/crypto.ts",
|
||||
"./lib/limited_map": "./plug-api/lib/limited_map.ts",
|
||||
"./lib/tags": "./plug-api/lib/tags.ts",
|
||||
"./type/client": "./plug-api/types/client.ts",
|
||||
"./type/config": "./plug-api/types/config.ts",
|
||||
"./type/manifest": "./plug-api/types/manifest.ts",
|
||||
"./type/namespace": "./plug-api/types/namespace.ts",
|
||||
"./type/datastore": "./plug-api/types/datastore.ts",
|
||||
"./type/event": "./plug-api/types/event.ts",
|
||||
"./type/index": "./plug-api/types/index.ts"
|
||||
},
|
||||
"imports": {
|
||||
"@silverbulletmd/silverbullet/syscall": "./plug-api/syscall.ts",
|
||||
"@silverbulletmd/silverbullet/syscalls": "./plug-api/syscalls.ts",
|
||||
"@silverbulletmd/silverbullet/constants": "./plug-api/constants.ts",
|
||||
"@silverbulletmd/silverbullet/type/client": "./plug-api/types/client.ts",
|
||||
"@silverbulletmd/silverbullet/type/config": "./plug-api/types/config.ts",
|
||||
"@silverbulletmd/silverbullet/type/datastore": "./plug-api/types/datastore.ts",
|
||||
"@silverbulletmd/silverbullet/type/event": "./plug-api/types/event.ts",
|
||||
"@silverbulletmd/silverbullet/type/index": "./plug-api/types/index.ts",
|
||||
"@silverbulletmd/silverbullet/type/manifest": "./plug-api/types/manifest.ts",
|
||||
"@silverbulletmd/silverbullet/type/namespace": "./plug-api/types/namespace.ts",
|
||||
"@silverbulletmd/silverbullet/lib/json": "./plug-api/lib/json.ts",
|
||||
"@silverbulletmd/silverbullet/lib/tree": "./plug-api/lib/tree.ts",
|
||||
"@silverbulletmd/silverbullet/lib/limited_map": "./plug-api/lib/limited_map.ts",
|
||||
"@silverbulletmd/silverbullet/lib/ref": "./plug-api/lib/ref.ts",
|
||||
"@silverbulletmd/silverbullet/lib/transclusion": "./plug-api/lib/transclusion.ts",
|
||||
"@silverbulletmd/silverbullet/lib/async": "./plug-api/lib/async.ts",
|
||||
"@silverbulletmd/silverbullet/lib/crypto": "./plug-api/lib/crypto.ts",
|
||||
"@silverbulletmd/silverbullet/lib/dates": "./plug-api/lib/dates.ts",
|
||||
"@silverbulletmd/silverbullet/lib/resolve": "./plug-api/lib/resolve.ts",
|
||||
"@silverbulletmd/silverbullet/lib/query_expression": "./plug-api/lib/query_expression.ts",
|
||||
"@silverbulletmd/silverbullet/lib/native_fetch": "./plug-api/lib/native_fetch.ts",
|
||||
"@silverbulletmd/silverbullet/lib/tags": "./plug-api/lib/tags.ts",
|
||||
"@codemirror/autocomplete": "npm:@codemirror/autocomplete@6.20.0",
|
||||
"@codemirror/commands": "npm:@codemirror/commands@6.10.1",
|
||||
"@codemirror/lang-css": "npm:@codemirror/lang-css@6.3.1",
|
||||
"@codemirror/lang-html": "npm:@codemirror/lang-html@6.4.11",
|
||||
"@codemirror/lang-javascript": "npm:@codemirror/lang-javascript@6.2.4",
|
||||
"@codemirror/lang-markdown": "npm:@codemirror/lang-markdown@6.5.0",
|
||||
"@codemirror/language": "npm:@codemirror/language@6.12.1",
|
||||
"@codemirror/legacy-modes": "npm:@codemirror/legacy-modes@6.5.2",
|
||||
"@codemirror/legacy-modes/mode/yaml": "npm:@codemirror/legacy-modes@6.5.2/mode/yaml",
|
||||
"@codemirror/lint": "npm:@codemirror/lint@6.9.2",
|
||||
"@codemirror/search": "npm:@codemirror/search@6.6.0",
|
||||
"@codemirror/state": "npm:@codemirror/state@6.5.4",
|
||||
"@codemirror/view": "npm:@codemirror/view@6.39.11",
|
||||
"@lezer/common": "npm:@lezer/common@1.5.0",
|
||||
"@lezer/css": "npm:@lezer/css@1.3.0",
|
||||
"@lezer/highlight": "npm:@lezer/highlight@1.2.3",
|
||||
"@lezer/html": "npm:@lezer/html@1.3.13",
|
||||
"@lezer/javascript": "npm:@lezer/javascript@1.5.4",
|
||||
"@lezer/lr": "npm:@lezer/lr@1.4.7",
|
||||
"@lezer/markdown": "npm:@lezer/markdown@1.6.3",
|
||||
"@replit/codemirror-lang-nix": "npm:@replit/codemirror-lang-nix@6.0.1",
|
||||
"@replit/codemirror-vim": "npm:@replit/codemirror-vim@6.3.0",
|
||||
"@std/assert": "jsr:@std/assert@^1.0.1",
|
||||
"@cliffy/command": "jsr:@cliffy/command@^1.0.0-rc.7",
|
||||
"@std/cli": "jsr:@std/cli@^1.0.1",
|
||||
"@std/fs": "jsr:@std/fs@^1.0.18",
|
||||
"@std/io": "jsr:@std/io@^0.225.2",
|
||||
"@std/io/read-all": "jsr:@std/io@^0.225.2/read-all",
|
||||
"@std/path": "jsr:@std/path@^1.0.8",
|
||||
"@std/testing": "jsr:@std/testing@^1.0.14",
|
||||
"@std/yaml": "jsr:@std/yaml@^1.0.8",
|
||||
"crelt": "npm:crelt@1.0.6",
|
||||
"denosass": "https://deno.land/x/denosass@1.0.6/mod.ts",
|
||||
"fake-indexeddb/auto": "npm:fake-indexeddb@6.0.1/auto",
|
||||
"fast-diff": "npm:fast-diff@1.3.0",
|
||||
"fuse": "npm:fuse.js@7.1.0",
|
||||
"gitignore-parser": "npm:gitignore-parser@0.0.2",
|
||||
"idb": "npm:idb@8.0.3",
|
||||
"js-yaml": "npm:js-yaml@4.1.0",
|
||||
"mimetypes": "https://deno.land/x/mimetypes@v1.0.0/mod.ts",
|
||||
"mime": "npm:mime@4.0.4",
|
||||
"vitest": "npm:vitest@4.0.18",
|
||||
"preact": "npm:preact@10.28.2",
|
||||
"preact-feather": "npm:preact-feather@4.2.1",
|
||||
"preact-feather/types": "npm:preact-feather@4.2.1/dist/types",
|
||||
"react-icons/md": "https://deno.land/x/react_icons_md@1.0.9/mod.ts",
|
||||
"react-icons/md/": "https://deno.land/x/react_icons_md@1.0.9/ico/",
|
||||
"react-icons/types": "https://deno.land/x/react_icons@1.0.9/mod.ts",
|
||||
"style-mod": "npm:style-mod@4.1.2",
|
||||
"turndown": "npm:turndown@7.2.2",
|
||||
"ajv": "npm:ajv@8.17.1",
|
||||
"turndown-plugin-gfm": "npm:@joplin/turndown-plugin-gfm@1.0.64",
|
||||
"@msgpack/msgpack": "npm:@msgpack/msgpack@3.1.3"
|
||||
}
|
||||
}
|
||||
+1
-2
@@ -2,9 +2,8 @@
|
||||
|
||||
VERSION=$1
|
||||
|
||||
# Patch version is version.ts and deno.json
|
||||
# Patch version in version.ts
|
||||
echo "export const version = \"$VERSION\";" > version.ts
|
||||
sed -i '' "s/\(\"version\": \"\)[^\"]*\(\"\)/\1$VERSION\2/" deno.json
|
||||
git commit -am $VERSION
|
||||
git tag $VERSION
|
||||
git push && git push --tags
|
||||
|
||||
Reference in New Issue
Block a user