Compare commits

...

7 Commits

Author SHA1 Message Date
di-sukharev
1a32bff538 0.0.19 2023-03-06 22:13:32 +08:00
di-sukharev
297ccac45b * 🐛 fix(package.json): change cli file extension from .cjs to .mjs
* 🐛 fix(githook.ts): change cli file path to match new extension
The cli file extension has been changed from .cjs to .mjs to improve compatibility with Node.js ESM modules. The file path in githook.ts has been updated to match the new extension.
2023-03-06 22:12:37 +08:00
di-sukharev
3859533eff * 🐛 fix(githook.ts): fix HOOK_PATH import URL
The HOOK_PATH import URL was incorrect and has been fixed to point to the correct location.
2023-03-06 21:49:19 +08:00
di-sukharev
757faba0c4 0.0.18 2023-03-06 21:42:05 +08:00
di-sukharev
422d38d51e * 🐛 fix(githook.ts): update HOOK_PATH to point to the correct file path
The HOOK_PATH variable was pointing to the wrong file path, which caused the hook to fail. The file path has been updated to point to the correct file path.
2023-03-06 21:41:58 +08:00
di-sukharev
ee02be56b2 0.0.17 2023-03-06 21:40:49 +08:00
di-sukharev
1c762a6e8c * 🚀 feat(package.json): add deploy script
The deploy script builds the application, increments the patch version, and publishes the package to the registry. This makes it easier to deploy new versions of the application.
2023-03-06 21:40:39 +08:00
3 changed files with 9 additions and 9 deletions

4
package-lock.json generated
View File

@@ -1,12 +1,12 @@
{
"name": "open-commit",
"version": "0.0.16",
"version": "0.0.19",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "open-commit",
"version": "0.0.16",
"version": "0.0.19",
"license": "ISC",
"dependencies": {
"@clack/prompts": "^0.6.1",

View File

@@ -1,6 +1,6 @@
{
"name": "opencommit",
"version": "0.0.16",
"version": "0.0.19",
"description": "AI generates conventional commits with mind-blowing accuracy.",
"keywords": [
"git",
@@ -12,8 +12,8 @@
],
"main": "cli.js",
"bin": {
"opencommit": "./out/cli.cjs",
"oc": "./out/cli.cjs"
"opencommit": "./out/cli.mjs",
"oc": "./out/cli.mjs"
},
"repository": {
"url": "https://github.com/di-sukharev/opencommit"
@@ -34,10 +34,10 @@
},
"scripts": {
"watch": "npm run -S build -- --sourcemap --watch",
"start": "node ./out/cli.cjs",
"start": "node ./out/cli.mjs",
"dev": "ts-node ./src/cli.ts",
"build": "rimraf out && esbuild ./src/cli.ts --bundle --outfile=out/cli.cjs --format=cjs --platform=node",
"patch": "npm version patch",
"build": "rimraf out && esbuild ./src/cli.ts --bundle --outfile=out/cli.mjs --format=esm --platform=node --banner:js=\"import {createRequire} from 'module';const require=createRequire(import.meta.url);\"",
"deploy": "npm run build && npm version patch && npm publish",
"lint": "eslint src --ext ts && tsc --noEmit"
},
"devDependencies": {

View File

@@ -20,7 +20,7 @@ export const hookCommand = command(
parameters: ['<set/unset>']
},
async (argv) => {
const HOOK_PATH = fileURLToPath(new URL('cli.cjs', import.meta.url));
const HOOK_PATH = fileURLToPath(new URL('cli.mjs', import.meta.url));
try {
await assertGitRepo();