New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

@commitguard/cli

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@commitguard/cli - npm Package Compare versions

Comparing version
0.0.3
to
0.0.13
+14
-13
dist/index.mjs
#!/usr/bin/env node
import { createRequire } from "node:module";
import process from "node:process";

@@ -13,4 +12,4 @@ import { consola } from "consola";

import { dirname, join } from "node:path";
import { fileURLToPath, pathToFileURL } from "node:url";
import { readFile } from "node:fs/promises";
import { pathToFileURL } from "node:url";
import { findUp } from "find-up";

@@ -21,8 +20,4 @@ import { FlatCache } from "flat-cache";

//#region rolldown:runtime
var __require = /* @__PURE__ */ createRequire(import.meta.url);
//#endregion
//#region package.json
var version = "0.0.3";
var version = "0.0.13";
var package_default = {

@@ -36,3 +31,3 @@ name: "@commitguard/cli",

"type": "git",
"url": "git+https://github.com/moshetanzer/commitguard.git"
"url": "git+https://github.com/commitguard/cli.git"
},

@@ -55,3 +50,4 @@ exports: {

"lint": "eslint .",
"lint:fix": "eslint . --fix"
"lint:fix": "eslint . --fix",
"release": "pnpm typecheck && bumpp --tag --push --publish && npm publish"
},

@@ -748,3 +744,3 @@ dependencies: {

const node = process.execPath.replace(/\\/g, "/");
const cliPath = __require.resolve("commitguard").replace(/\\/g, "/");
const cliPath = fileURLToPath(import.meta.url).replace(/\\/g, "/");
writeFileSync(COMMIT_MSG_HOOK_PATH, `#!/bin/sh

@@ -798,5 +794,10 @@ ${COMMITGUARD_MARKER}

`, { mode: 493 });
log.info("Analyzing ESLint configuration for better checks...");
await getEslintRules({ overrideCache: true });
log.success("ESLint configuration loaded.");
log.info("Checking ESLint configuration...");
try {
const eslintRules = await getEslintRules({ overrideCache: true });
if (Object.keys(eslintRules.rules).length > 0) log.success("ESLint configuration loaded.");
else log.info("No ESLint rules detected.");
} catch {
log.warn("Failed to load ESLint configuration.");
}
if (!getGlobalKey() && process.env.COMMITGUARD_API_KEY === void 0) {

@@ -803,0 +804,0 @@ if (await confirm({

{
"name": "@commitguard/cli",
"type": "module",
"version": "0.0.3",
"version": "0.0.13",
"description": "AI-powered git commit checker that blocks bad code before it ships",

@@ -9,3 +9,3 @@ "license": "MIT",

"type": "git",
"url": "git+https://github.com/moshetanzer/commitguard.git"
"url": "git+https://github.com/commitguard/cli.git"
},

@@ -25,2 +25,12 @@ "exports": {

],
"scripts": {
"build": "tsdown",
"dev": "tsdown --watch",
"test": "vitest",
"typecheck": "tsc --noEmit",
"prepublishOnly": "pnpm run build",
"lint": "eslint .",
"lint:fix": "eslint . --fix",
"release": "pnpm typecheck && bumpp --tag --push --publish && npm publish"
},
"dependencies": {

@@ -47,11 +57,3 @@ "@clack/prompts": "^0.11.0",

"vitest": "^4.0.16"
},
"scripts": {
"build": "tsdown",
"dev": "tsdown --watch",
"test": "vitest",
"typecheck": "tsc --noEmit",
"lint": "eslint .",
"lint:fix": "eslint . --fix"
}
}
}