Skip to content

Commit

Permalink
feat: add Buffer and readLines
Browse files Browse the repository at this point in the history
  • Loading branch information
c4spar committed May 9, 2021
1 parent f599187 commit 269ba69
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 6 deletions.
2 changes: 2 additions & 0 deletions deps.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ export {
writeAll,
writeAllSync,
} from "https://deno.land/std@0.95.0/io/util.ts";
export { Buffer } from "https://deno.land/std@0.95.0/io/buffer.ts";
export { readLines } from "https://deno.land/std@0.95.0/io/bufio.ts";
export { default as escapeStr } from "https://esm.sh/shq@1.0.2";
export { parse as parseFlags } from "https://deno.land/std@0.95.0/flags/mod.ts";
export type {
Expand Down
19 changes: 13 additions & 6 deletions dzx.ts
Original file line number Diff line number Diff line change
@@ -1,25 +1,32 @@
/// <reference path="./types.d.ts" />

import { join } from "./deps.ts";
import { error } from "./src/_utils.ts";
import {
$,
Buffer,
cd,
iter,
iterSync,
join,
parseFlags,
quote,
readAll,
readAllSync,
readLines,
writeAll,
writeAllSync,
} from "./deps.ts";
import { $, cd, parseFlags, quote } from "./mod.ts";
import { error } from "./src/_utils.ts";
} from "./mod.ts";

window.$ = $;
window.Buffer = Buffer;
window.cd = cd;
window.quote = quote;
window.parseFlags = parseFlags;
window.iter = iter;
window.iterSync = iterSync;
window.parseFlags = parseFlags;
window.quote = quote;
window.readAll = readAll;
window.readAllSync = readAllSync;
window.readLines = readLines;
window.writeAll = writeAll;
window.writeAllSync = writeAllSync;

Expand Down
4 changes: 4 additions & 0 deletions mod.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import {
Buffer,
colors,
escapeStr,
iter,
iterSync,
readAll,
readAllSync,
readLines,
writeAll,
writeAllSync,
} from "./deps.ts";
Expand Down Expand Up @@ -33,13 +35,15 @@ $.quote = escapeStr;
$.throwErors = false;

export {
Buffer,
cd,
iter,
iterSync,
parseFlags,
quote,
readAll,
readAllSync,
readLines,
writeAll,
writeAllSync,
};

0 comments on commit 269ba69

Please sign in to comment.