From a621fba765cc3ddaa53d0bed48f691974d225f72 Mon Sep 17 00:00:00 2001 From: Ryan Murphy Date: Wed, 1 Mar 2023 22:58:14 -0800 Subject: [PATCH] Everyone else uses mod.ts, so do the same --- .github/workflows/ci.yaml | 2 +- README.md | 4 ++-- deno.jsonc | 2 +- main.ts => mod.ts | 4 ++-- main_test.ts => mod_test.ts | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) rename main.ts => mod.ts (97%) rename main_test.ts => mod_test.ts (99%) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 59af360..a7308c6 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -25,7 +25,7 @@ jobs: run: deno lint - name: Cache dependencies - run: deno cache main.ts main_test.ts + run: deno cache mod.ts mod_test.ts - name: Run tests run: deno test --allow-read diff --git a/README.md b/README.md index c3d037c..13ab174 100644 --- a/README.md +++ b/README.md @@ -37,7 +37,7 @@ data/ After `import`'ing `quaff`: ```ts -import { load } from "https://deno.land/x/quaff/main.ts"; +import { load } from "https://deno.land/x/quaff/mod.ts"; const data = await load("./data/"); console.log(data); @@ -81,7 +81,7 @@ It's also possible to load a single file at a time, allowing more custom approaches in case `load` doesn't work exactly the way you'd like. ```ts -import { loadFile } from "https://deno.land/x/quaff/main.ts"; +import { loadFile } from "https://deno.land/x/quaff/mod.ts"; const data = await loadFile("./data/mammals/bears.csv"); console.log(data); diff --git a/deno.jsonc b/deno.jsonc index 5ce45d8..c7f9f1b 100644 --- a/deno.jsonc +++ b/deno.jsonc @@ -1,6 +1,6 @@ { "tasks": { - "dev": "deno run --watch main.ts" + "dev": "deno run --watch mod.ts" }, "fmt": { "files": { diff --git a/main.ts b/mod.ts similarity index 97% rename from main.ts rename to mod.ts index 3da7f8d..e828960 100644 --- a/main.ts +++ b/mod.ts @@ -23,7 +23,7 @@ * After importing `quaff`: * * ```ts - * import { load } from "https://deno.land/x/quaff/main.ts"; + * import { load } from "https://deno.land/x/quaff/mod.ts"; * * const data = await load("./data/"); * console.log(data); @@ -67,7 +67,7 @@ * approaches in case `load` doesn't work exactly the way you'd like. * * ```ts - * import { loadFile } from "https://deno.land/x/quaff/main.ts"; + * import { loadFile } from "https://deno.land/x/quaff/mod.ts"; * * const data = await loadFile("./data/mammals/bears.csv"); * console.log(data); diff --git a/main_test.ts b/mod_test.ts similarity index 99% rename from main_test.ts rename to mod_test.ts index 9fd4685..5870ad8 100644 --- a/main_test.ts +++ b/mod_test.ts @@ -2,7 +2,7 @@ import { assertEquals, assertRejects, } from "https://deno.land/std@0.178.0/testing/asserts.ts"; -import { load, loadFile } from "./main.ts"; +import { load, loadFile } from "./mod.ts"; import { parseArchieML, parseCsv,