From c80e1d7f23bf564b252dd58d9aa04c76719fa553 Mon Sep 17 00:00:00 2001 From: Dan Abramov Date: Fri, 10 Oct 2025 05:55:02 +0100 Subject: [PATCH] 0.2.5 --- packages/cli/package.json | 2 +- packages/cli/src/commands/init.ts | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/cli/package.json b/packages/cli/package.json index d4d1cca..fb16cad 100644 --- a/packages/cli/package.json +++ b/packages/cli/package.json @@ -1,6 +1,6 @@ { "name": "@typelex/cli", - "version": "0.2.4", + "version": "0.2.5", "main": "dist/index.js", "type": "module", "bin": { diff --git a/packages/cli/src/commands/init.ts b/packages/cli/src/commands/init.ts index f9e5881..aed0ee8 100644 --- a/packages/cli/src/commands/init.ts +++ b/packages/cli/src/commands/init.ts @@ -1,4 +1,4 @@ -import { resolve } from "path"; +import { resolve, relative } from "path"; import { mkdir, writeFile, readFile, access } from "fs/promises"; import { spawn } from "child_process"; import { createInterface } from "readline"; @@ -82,8 +82,8 @@ export async function initCommand(): Promise { const lexiconsPath = resolve(currentDir, "lexicons"); await access(lexiconsPath); // Calculate relative path from cwd to this lexicons directory - const relative = require("path").relative(cwd, lexiconsPath); - lexiconsDir = relative; + const relativePath = relative(cwd, lexiconsPath); + lexiconsDir = relativePath; } catch { // Continue } -- 2.51.2