draftify-cli 1.0.74 → 1.0.76

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.js +6 -0
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -6,6 +6,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
7
  const commander_1 = require("commander");
8
8
  const https_1 = __importDefault(require("https"));
9
+ const fs_1 = __importDefault(require("fs"));
10
+ const path_1 = __importDefault(require("path"));
9
11
  const login_1 = require("./commands/login");
10
12
  const refactor_1 = require("./commands/refactor");
11
13
  const repl_1 = require("./repl");
@@ -36,6 +38,10 @@ program.on('command:*', function () {
36
38
  process.exit(1);
37
39
  });
38
40
  async function checkVersion() {
41
+ const isDev = fs_1.default.existsSync(path_1.default.join(__dirname, "../src/index.ts"));
42
+ if (isDev) {
43
+ return;
44
+ }
39
45
  return new Promise((resolve) => {
40
46
  // Set a short timeout so the CLI doesn't hang if the registry is slow or offline
41
47
  const req = https_1.default.get("https://registry.npmjs.org/draftify-cli/latest", { timeout: 2000 }, (res) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "draftify-cli",
3
- "version": "1.0.74",
3
+ "version": "1.0.76",
4
4
  "description": "Draftify AI CLI tool",
5
5
  "main": "dist/index.js",
6
6
  "bin": {