Skip to content

Use separated deno.json to manage dependencies #42

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion deno.jsonc
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,8 @@
"update": "deno run --allow-env --allow-read --allow-write=. --allow-run=git,deno --allow-net=deno.land,jsr.io,registry.npmjs.org jsr:@molt/cli ./**/*.ts",
"update:write": "deno task -q update --write",
"update:commit": "deno task -q update --commit --prefix :package: --pre-commit=fmt,lint"
}
},
"workspace": [
"./denops/fall"
]
}
12 changes: 4 additions & 8 deletions denops/fall/_assets/default.custom.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
import type { Entrypoint } from "jsr:@vim-fall/custom@^0.1.0";
import {
composeRenderers,
refineCurator,
refineSource,
} from "jsr:@vim-fall/std@^0.10.0";
import * as builtin from "jsr:@vim-fall/std@^0.10.0/builtin";
import { SEPARATOR } from "jsr:@std/path@^1.0.8/constants";
import type { Entrypoint } from "@vim-fall/custom";
import { composeRenderers, refineCurator, refineSource } from "@vim-fall/std";
import * as builtin from "@vim-fall/std/builtin";
import { SEPARATOR } from "@std/path/constants";

// NOTE:
//
Expand Down
4 changes: 2 additions & 2 deletions denops/fall/_assets/minimum.custom.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import type { Entrypoint } from "jsr:@vim-fall/custom@^0.1.0";
import * as builtin from "jsr:@vim-fall/std@^0.10.0/builtin";
import type { Entrypoint } from "@vim-fall/custom";
import * as builtin from "@vim-fall/std/builtin";

export const main: Entrypoint = ({
definePickerFromSource,
Expand Down
8 changes: 4 additions & 4 deletions denops/fall/component/_component.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import type { Denops } from "jsr:@denops/std@^7.3.2";
import * as popup from "jsr:@denops/std@^7.3.2/popup";
import type { Border } from "jsr:@vim-fall/core@^0.3.0/theme";
import type { Dimension } from "jsr:@vim-fall/core@^0.3.0/coordinator";
import type { Denops } from "@denops/std";
import * as popup from "@denops/std/popup";
import type { Border } from "@vim-fall/core/theme";
import type { Dimension } from "@vim-fall/core/coordinator";

const HIGHLIGHT_NORMAL = "FallNormal";
const HIHGLIGHT_BORDER = "FallBorder";
Expand Down
6 changes: 3 additions & 3 deletions denops/fall/component/_component_test.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { test } from "jsr:@denops/test@^3.0.4";
import * as fn from "jsr:@denops/std@^7.3.2/function";
import { assertEquals, assertNotEquals } from "jsr:@std/assert@^1.0.7";
import { test } from "@denops/test";
import * as fn from "@denops/std/function";
import { assertEquals, assertNotEquals } from "@std/assert";

import { screentext } from "./_testutil.ts";
import { BaseComponent } from "./_component.ts";
Expand Down
12 changes: 6 additions & 6 deletions denops/fall/component/_testutil.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import type { Denops } from "jsr:@denops/std@^7.3.2";
import * as fn from "jsr:@denops/std@^7.3.2/function";
import { collect } from "jsr:@denops/std@^7.3.2/batch";
import * as iterutil from "jsr:@core/iterutil@^0.9/pipe";
import { range } from "jsr:@core/iterutil@^0.9.0";
import { pipe } from "jsr:@core/pipe@^0.4.0";
import type { Denops } from "@denops/std";
import * as fn from "@denops/std/function";
import { collect } from "@denops/std/batch";
import * as iterutil from "@core/iterutil/pipe";
import { range } from "@core/iterutil";
import { pipe } from "@core/pipe";

/**
* Get screen text in the specified range.
Expand Down
12 changes: 6 additions & 6 deletions denops/fall/component/help.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import type { Denops } from "jsr:@denops/std@^7.3.2";
import type { Decoration } from "jsr:@denops/std@^7.3.2/buffer";
import * as mapping from "jsr:@denops/std@^7.3.2/mapping";
import * as fn from "jsr:@denops/std@^7.3.2/function";
import * as buffer from "jsr:@denops/std@^7.3.2/buffer";
import type { Dimension } from "jsr:@vim-fall/core@^0.3.0/coordinator";
import type { Denops } from "@denops/std";
import type { Decoration } from "@denops/std/buffer";
import * as mapping from "@denops/std/mapping";
import * as fn from "@denops/std/function";
import * as buffer from "@denops/std/buffer";
import type { Dimension } from "@vim-fall/core/coordinator";

import { BaseComponent } from "./_component.ts";
import { ItemBelt } from "../lib/item_belt.ts";
Expand Down
8 changes: 4 additions & 4 deletions denops/fall/component/help_test.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import "../lib/polyfill.ts";

import { test } from "jsr:@denops/test@^3.0.4";
import * as fn from "jsr:@denops/std@^7.3.2/function";
import { fromFileUrl } from "jsr:@std/path@^1.0.8/from-file-url";
import { assertEquals } from "jsr:@std/assert@^1.0.6";
import { test } from "@denops/test";
import * as fn from "@denops/std/function";
import { fromFileUrl } from "@std/path/from-file-url";
import { assertEquals } from "@std/assert";

import { HelpComponent } from "./help.ts";

Expand Down
8 changes: 4 additions & 4 deletions denops/fall/component/input.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import type { Denops } from "jsr:@denops/std@^7.3.2";
import * as fn from "jsr:@denops/std@^7.3.2/function";
import * as buffer from "jsr:@denops/std@^7.3.2/buffer";
import type { Dimension } from "jsr:@vim-fall/core@^0.3.0/coordinator";
import type { Denops } from "@denops/std";
import * as fn from "@denops/std/function";
import * as buffer from "@denops/std/buffer";
import type { Dimension } from "@vim-fall/core/coordinator";

import { Spinner, UNICODE_SPINNER } from "../lib/spinner.ts";
import { adjustOffset } from "../lib/adjust_offset.ts";
Expand Down
12 changes: 6 additions & 6 deletions denops/fall/component/input_test.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import "../lib/polyfill.ts";

import { assertEquals } from "jsr:@std/assert@^1.0.6";
import { delay } from "jsr:@std/async@^1.0.7";
import { test } from "jsr:@denops/test@^3.0.4";
import { fromFileUrl } from "jsr:@std/path@^1.0.8/from-file-url";
import { listDecorations } from "jsr:@denops/std@^7.3.2/buffer";
import * as fn from "jsr:@denops/std@^7.3.2/function";
import { assertEquals } from "@std/assert";
import { delay } from "@std/async";
import { test } from "@denops/test";
import { fromFileUrl } from "@std/path/from-file-url";
import { listDecorations } from "@denops/std/buffer";
import * as fn from "@denops/std/function";

import {
HIGHLIGHT_COUNTER,
Expand Down
12 changes: 6 additions & 6 deletions denops/fall/component/list.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import type { Denops } from "jsr:@denops/std@^7.3.2";
import type { Decoration } from "jsr:@denops/std@^7.3.2/buffer";
import { batch } from "jsr:@denops/std@^7.3.2/batch";
import * as fn from "jsr:@denops/std@^7.3.2/function";
import * as buffer from "jsr:@denops/std@^7.3.2/buffer";
import type { Dimension } from "jsr:@vim-fall/core@^0.3.0/coordinator";
import type { Denops } from "@denops/std";
import type { Decoration } from "@denops/std/buffer";
import { batch } from "@denops/std/batch";
import * as fn from "@denops/std/function";
import * as buffer from "@denops/std/buffer";
import type { Dimension } from "@vim-fall/core/coordinator";

import { BaseComponent, ComponentProperties } from "./_component.ts";

Expand Down
14 changes: 7 additions & 7 deletions denops/fall/component/list_test.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import "../lib/polyfill.ts";

import type { Denops } from "jsr:@denops/std@^7.3.2";
import { test } from "jsr:@denops/test@^3.0.4";
import * as fn from "jsr:@denops/std@^7.3.2/function";
import { listDecorations } from "jsr:@denops/std@^7.3.2/buffer";
import { assertEquals } from "jsr:@std/assert@^1.0.6";
import { fromFileUrl } from "jsr:@std/path@^1.0.8/from-file-url";
import { omit } from "jsr:@std/collections@^1.0.9/omit";
import type { Denops } from "@denops/std";
import { test } from "@denops/test";
import * as fn from "@denops/std/function";
import { listDecorations } from "@denops/std/buffer";
import { assertEquals } from "@std/assert";
import { fromFileUrl } from "@std/path/from-file-url";
import { omit } from "@std/collections/omit";

import {
HIGHLIGHT_MATCH,
Expand Down
10 changes: 5 additions & 5 deletions denops/fall/component/preview.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import type { Denops } from "jsr:@denops/std@^7.3.2";
import * as fn from "jsr:@denops/std@^7.3.2/function";
import * as buffer from "jsr:@denops/std@^7.3.2/buffer";
import { batch } from "jsr:@denops/std@^7.3.2/batch";
import type { Dimension } from "jsr:@vim-fall/core@^0.3.0/coordinator";
import type { Denops } from "@denops/std";
import * as fn from "@denops/std/function";
import * as buffer from "@denops/std/buffer";
import { batch } from "@denops/std/batch";
import type { Dimension } from "@vim-fall/core/coordinator";

import { BaseComponent, type ComponentProperties } from "./_component.ts";

Expand Down
8 changes: 4 additions & 4 deletions denops/fall/component/preview_test.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import "../lib/polyfill.ts";

import { test } from "jsr:@denops/test@^3.0.4";
import * as fn from "jsr:@denops/std@^7.3.2/function";
import { fromFileUrl } from "jsr:@std/path@^1.0.8/from-file-url";
import { assertEquals } from "jsr:@std/assert@^1.0.6";
import { test } from "@denops/test";
import * as fn from "@denops/std/function";
import { fromFileUrl } from "@std/path/from-file-url";
import { assertEquals } from "@std/assert";

import { PreviewComponent } from "./preview.ts";

Expand Down
35 changes: 16 additions & 19 deletions denops/fall/custom.ts
Original file line number Diff line number Diff line change
@@ -1,30 +1,27 @@
import type { Denops } from "jsr:@denops/std@^7.3.2";
import * as buffer from "jsr:@denops/std@^7.3.2/buffer";
import * as vars from "jsr:@denops/std@^7.3.2/variable";
import * as autocmd from "jsr:@denops/std@^7.3.2/autocmd";
import { TextLineStream } from "jsr:@std/streams@^1.0.8/text-line-stream";
import { mergeReadableStreams } from "jsr:@std/streams@^1.0.8/merge-readable-streams";
import { toFileUrl } from "jsr:@std/path@^1.0.8/to-file-url";
import { fromFileUrl } from "jsr:@std/path@^1.0.8/from-file-url";
import { dirname } from "jsr:@std/path@^1.0.8/dirname";
import { copy } from "jsr:@std/fs@^1.0.5/copy";
import {
buildRefineSetting,
type Setting,
} from "jsr:@vim-fall/custom@^0.1.0/setting";
import type { Denops } from "@denops/std";
import * as buffer from "@denops/std/buffer";
import * as vars from "@denops/std/variable";
import * as autocmd from "@denops/std/autocmd";
import { TextLineStream } from "@std/streams/text-line-stream";
import { mergeReadableStreams } from "@std/streams/merge-readable-streams";
import { toFileUrl } from "@std/path/to-file-url";
import { fromFileUrl } from "@std/path/from-file-url";
import { dirname } from "@std/path/dirname";
import { copy } from "@std/fs/copy";
import { buildRefineSetting, type Setting } from "@vim-fall/custom/setting";
import {
type ActionPickerParams,
buildRefineActionPicker,
} from "jsr:@vim-fall/custom@^0.1.0/action-picker";
} from "@vim-fall/custom/action-picker";
import {
buildDefinePickerFromCurator,
buildDefinePickerFromSource,
type PickerParams,
} from "jsr:@vim-fall/custom@^0.1.0/picker";
} from "@vim-fall/custom/picker";

import { modern } from "jsr:@vim-fall/std@^0.10.0/builtin/coordinator/modern";
import { MODERN_THEME } from "jsr:@vim-fall/std@^0.10.0/builtin/theme/modern";
import { fzf } from "jsr:@vim-fall/std@^0.10.0/builtin/matcher/fzf";
import { modern } from "@vim-fall/std/builtin/coordinator/modern";
import { MODERN_THEME } from "@vim-fall/std/builtin/theme/modern";
import { fzf } from "@vim-fall/std/builtin/matcher/fzf";

import { ExpectedError } from "./error.ts";

Expand Down
22 changes: 22 additions & 0 deletions denops/fall/deno.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"imports": {
"@core/asyncutil": "jsr:@core/asyncutil@^1.2.0",
"@core/errorutil": "jsr:@core/errorutil@^1.2.0",
"@core/iterutil": "jsr:@core/iterutil@^0.9.0",
"@core/pipe": "jsr:@core/pipe@^0.4.0",
"@core/unknownutil": "jsr:@core/unknownutil@^4.3.0",
"@denops/std": "jsr:@denops/std@^7.3.2",
"@denops/test": "jsr:@denops/test@^3.0.4",
"@nick/dispose": "jsr:@nick/dispose@^1.1.0",
"@std/assert": "jsr:@std/assert@^1.0.8",
"@std/async": "jsr:@std/async@^1.0.7",
"@std/collections": "jsr:@std/collections@^1.0.9",
"@std/fs": "jsr:@std/fs@^1.0.5",
"@std/path": "jsr:@std/path@^1.0.8",
"@std/streams": "jsr:@std/streams@^1.0.8",
"@std/testing": "jsr:@std/testing@^1.0.0",
"@vim-fall/core": "jsr:@vim-fall/core@^0.3.0",
"@vim-fall/custom": "jsr:@vim-fall/custom@^0.1.0",
"@vim-fall/std": "jsr:@vim-fall/std@^0.10.0"
}
}
4 changes: 2 additions & 2 deletions denops/fall/error.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import type { Denops } from "jsr:@denops/std@^7.3.2";
import { AssertError } from "jsr:@core/unknownutil@^4.3.0/assert";
import type { Denops } from "@denops/std";
import { AssertError } from "@core/unknownutil/assert";

/**
* Application error that is used to represent an expected error.
Expand Down
2 changes: 1 addition & 1 deletion denops/fall/event_test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assertEquals } from "jsr:@std/assert@^1.0.6";
import { assertEquals } from "@std/assert";

import { consume, dispatch, type Event } from "./event.ts";

Expand Down
2 changes: 1 addition & 1 deletion denops/fall/extension/action/session.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { Action } from "jsr:@vim-fall/core@^0.3.0/action";
import type { Action } from "@vim-fall/core/action";
import type { Detail } from "../source/session.ts";

export const defaultSessionActions = {
Expand Down
6 changes: 3 additions & 3 deletions denops/fall/extension/previewer/session.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import type { PreviewItem } from "jsr:@vim-fall/core@^0.3.0/item";
import type { Previewer } from "jsr:@vim-fall/core@^0.3.0/previewer";
import { definePreviewer } from "jsr:@vim-fall/std@^0.10.0/previewer";
import type { PreviewItem } from "@vim-fall/core/item";
import type { Previewer } from "@vim-fall/core/previewer";
import { definePreviewer } from "@vim-fall/std/previewer";
import type { Detail } from "../source/session.ts";

export function session(): Previewer<Detail> {
Expand Down
6 changes: 3 additions & 3 deletions denops/fall/extension/renderer/session.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import type { Denops } from "jsr:@denops/std@^7.3.2";
import type { Renderer } from "jsr:@vim-fall/core@^0.3.0/renderer";
import type { DisplayItem } from "jsr:@vim-fall/core@^0.3.0/item";
import type { Denops } from "@denops/std";
import type { Renderer } from "@vim-fall/core/renderer";
import type { DisplayItem } from "@vim-fall/core/item";
import type { Detail } from "../source/session.ts";

export function session(): Renderer<Detail> {
Expand Down
6 changes: 3 additions & 3 deletions denops/fall/extension/source/action.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import type { Detail } from "jsr:@vim-fall/core@^0.3.0/item";
import type { Source } from "jsr:@vim-fall/core@^0.3.0/source";
import type { Action } from "jsr:@vim-fall/core@^0.3.0/action";
import type { Detail } from "@vim-fall/core/item";
import type { Source } from "@vim-fall/core/source";
import type { Action } from "@vim-fall/core/action";

/**
* Create a source for actions.
Expand Down
4 changes: 2 additions & 2 deletions denops/fall/extension/source/list.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import type { Detail, IdItem } from "jsr:@vim-fall/core@^0.3.0/item";
import type { Source } from "jsr:@vim-fall/core@^0.3.0/source";
import type { Detail, IdItem } from "@vim-fall/core/item";
import type { Source } from "@vim-fall/core/source";

/**
* Create a source from a list
Expand Down
4 changes: 2 additions & 2 deletions denops/fall/extension/source/session.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import type { Source } from "jsr:@vim-fall/core@^0.3.0/source";
import type { DetailUnit, IdItem } from "jsr:@vim-fall/core@^0.3.0/item";
import type { Source } from "@vim-fall/core/source";
import type { DetailUnit, IdItem } from "@vim-fall/core/item";
import type { PickerSession } from "../../session.ts";
import { listPickerSessions } from "../../session.ts";

Expand Down
2 changes: 1 addition & 1 deletion denops/fall/lib/adjust_offset_test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assertEquals } from "jsr:@std/assert@^1.0.6";
import { assertEquals } from "@std/assert";
import { adjustOffset } from "./adjust_offset.ts";

Deno.test("adjustOffset", async (t) => {
Expand Down
2 changes: 1 addition & 1 deletion denops/fall/lib/chunker_test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assertEquals, assertThrows } from "jsr:@std/assert@^1.0.7";
import { assertEquals, assertThrows } from "@std/assert";
import { Chunker } from "./chunker.ts";

Deno.test("Chunker", async (t) => {
Expand Down
2 changes: 1 addition & 1 deletion denops/fall/lib/debounce.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export type DebounceOptions = {
* @example
* ```ts
* import { debounce } from "./debounce.ts";
* import { delay } from "jsr:@std/async@^1.0.0/delay";
* import { delay } from "@std/async/delay";
*
* const saveData = () => console.log("Saving data...");
* const debouncedSave = debounce(() => saveData(), { delay: 100 });
Expand Down
6 changes: 3 additions & 3 deletions denops/fall/lib/debounce_test.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { assertEquals } from "jsr:@std/assert@^1.0.6";
import { delay } from "jsr:@std/async@^1.0.0/delay";
import { FakeTime } from "jsr:@std/testing@^1.0.0/time";
import { assertEquals } from "@std/assert";
import { delay } from "@std/async/delay";
import { FakeTime } from "@std/testing/time";

import { debounce } from "./debounce.ts";

Expand Down
4 changes: 2 additions & 2 deletions denops/fall/lib/dispose.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { isObjectOf } from "jsr:@core/unknownutil@^4.3.0/is/object-of";
import { isFunction } from "jsr:@core/unknownutil@^4.3.0/is/function";
import { isObjectOf } from "@core/unknownutil/is/object-of";
import { isFunction } from "@core/unknownutil/is/function";

const isDisposable = isObjectOf({
[Symbol.dispose]: isFunction,
Expand Down
2 changes: 1 addition & 1 deletion denops/fall/lib/dispose_test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assertEquals } from "jsr:@std/assert@^1.0.8";
import { assertEquals } from "@std/assert";
import { dispose } from "./dispose.ts";

Deno.test("dispose", async (t) => {
Expand Down
2 changes: 1 addition & 1 deletion denops/fall/lib/item_belt_test.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { assertEquals } from "jsr:@std/assert@^1.0.8";
import { assertEquals } from "@std/assert";
import { ItemBelt } from "./item_belt.ts";

Deno.test("ItemBelt", async (t) => {
Expand Down
5 changes: 1 addition & 4 deletions denops/fall/lib/polyfill.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
import {
AsyncDisposableStack,
DisposableStack,
} from "jsr:@nick/dispose@^1.1.0";
import { AsyncDisposableStack, DisposableStack } from "@nick/dispose";

// DisposableStack and AsyncDisposableStack are not available yet.
// https://github.com/denoland/deno/issues/20821
Expand Down
4 changes: 2 additions & 2 deletions denops/fall/lib/scheduler_test.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { delay } from "jsr:@std/async@^1.0.7";
import { assertEquals } from "jsr:@std/assert@^1.0.6";
import { delay } from "@std/async";
import { assertEquals } from "@std/assert";
import { Scheduler } from "./scheduler.ts";

Deno.test("Scheduler", async (t) => {
Expand Down
Loading
Loading