-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #15 from vim-denops/re-modernize
Re modernize
- Loading branch information
Showing
9 changed files
with
31 additions
and
75 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
import { using } from "https://deno.land/x/[email protected]/mod.ts"; | ||
import { Message, Session } from "../mod.ts"; | ||
import { using } from "../deps_test.ts"; | ||
|
||
// NOTE: | ||
// Do NOT use 'console.log()' while stdout is used to communicate with Vim | ||
|
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
import { Deferred, deferred } from "./deps.ts"; | ||
import { Deferred, deferred } from "https://deno.land/[email protected]/async/mod.ts"; | ||
import { Message, MessageId } from "./message.ts"; | ||
|
||
const DEFAULT_RESPONSE_TIMEOUT = 10000; // milliseconds | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,7 @@ | ||
import { assertEquals, assertRejects } from "./deps_test.ts"; | ||
import { | ||
assertEquals, | ||
assertRejects, | ||
} from "https://deno.land/[email protected]/testing/asserts.ts"; | ||
import { Message, MessageId } from "./message.ts"; | ||
import { ResponseWaiter, TimeoutError } from "./response_waiter.ts"; | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,16 @@ | ||
import { Deferred, deferred, Disposable, JSONparser, streams } from "./deps.ts"; | ||
import * as streams from "https://deno.land/[email protected]/streams/mod.ts"; | ||
import { | ||
Deferred, | ||
deferred, | ||
} from "https://deno.land/[email protected]/async/deferred.ts"; | ||
import type { Disposable } from "https://deno.land/x/[email protected]/mod.ts"; | ||
import { Indexer } from "https://deno.land/x/[email protected]/mod.ts"; | ||
// NOTE: | ||
// streamparser-json must be v0.0.5 because it automatically end-up parsing without separator after v0.0.5 | ||
// https://github.com/juanjoDiaz/streamparser-json/commit/577e918b90c19d6758b87d41bdb6c5571a2c012d | ||
import JSONParser from "https://deno.land/x/[email protected]/jsonparse.ts#="; | ||
import { isMessage, Message } from "./message.ts"; | ||
import * as command from "./command.ts"; | ||
import { Indexer } from "./indexer.ts"; | ||
import { ResponseWaiter } from "./response_waiter.ts"; | ||
|
||
const MSGID_THRESHOLD = 2 ** 32; | ||
|
@@ -84,7 +93,7 @@ export class Session implements Disposable { | |
} | ||
|
||
private async listen(): Promise<void> { | ||
const parser = new JSONparser(); | ||
const parser = new JSONParser(); | ||
parser.onValue = (data, _key, _parent, stack) => { | ||
if (stack.length > 0) { | ||
return; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,16 @@ | ||
import { JSONparser, streams } from "./deps.ts"; | ||
import { assertEquals, assertRejects, delay, using } from "./deps_test.ts"; | ||
import * as streams from "https://deno.land/[email protected]/streams/mod.ts"; | ||
import { | ||
assertEquals, | ||
assertRejects, | ||
} from "https://deno.land/[email protected]/testing/asserts.ts"; | ||
import { delay } from "https://deno.land/[email protected]/async/mod.ts"; | ||
import { using } from "https://deno.land/x/[email protected]/mod.ts"; | ||
import { Indexer } from "https://deno.land/x/[email protected]/mod.ts"; | ||
// NOTE: | ||
// streamparser-json must be v0.0.5 because it automatically end-up parsing without separator after v0.0.5 | ||
// https://github.com/juanjoDiaz/streamparser-json/commit/577e918b90c19d6758b87d41bdb6c5571a2c012d | ||
import JSONParser from "https://deno.land/x/[email protected]/jsonparse.ts#="; | ||
import { Session, SessionClosedError } from "./session.ts"; | ||
import { Indexer } from "./indexer.ts"; | ||
import * as command from "./command.ts"; | ||
|
||
const MSGID_THRESHOLD = 2 ** 32; | ||
|
@@ -111,7 +120,7 @@ class Vim { | |
} | ||
|
||
private async listen(): Promise<void> { | ||
const parser = new JSONparser(); | ||
const parser = new JSONParser(); | ||
parser.onValue = (data, _key, _parent, stack) => { | ||
if (stack.length > 0) { | ||
return; | ||
|