git-coco 0.1.1 → 0.2.1
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.
- package/README.md +10 -2
- package/dist/index.esm.mjs +139 -251
- package/dist/index.esm.mjs.map +1 -1
- package/dist/index.js +138 -252
- package/dist/lib/parsers/noResult.d.ts +4 -6
- package/dist/lib/simple-git/createCommit.d.ts +2 -0
- package/dist/lib/simple-git/getChanges.d.ts +12 -0
- package/dist/lib/simple-git/getDiff.d.ts +7 -0
- package/dist/lib/simple-git/getStatus.d.ts +3 -0
- package/dist/lib/simple-git/getSummaryText.d.ts +3 -0
- package/dist/lib/types.d.ts +3 -3
- package/dist/stats.html +1 -1
- package/package.json +10 -11
- package/dist/lib/parsers/default/utils/parseFileDiff.d.ts +0 -4
- package/dist/lib/utils/git/constants.d.ts +0 -1
- package/dist/lib/utils/git/createCommit.d.ts +0 -2
- package/dist/lib/utils/git/getChanges.d.ts +0 -43
- package/dist/lib/utils/git/getStatus.d.ts +0 -3
- package/dist/lib/utils/git/getSummaryText.d.ts +0 -2
- package/dist/lib/utils/git/parsePatches.d.ts +0 -18
- /package/dist/lib/parsers/default/{fileChangeParser.d.ts → index.d.ts} +0 -0
package/dist/stats.html
CHANGED
|
@@ -5285,7 +5285,7 @@ var drawChart = (function (exports) {
|
|
|
5285
5285
|
</script>
|
|
5286
5286
|
<script>
|
|
5287
5287
|
/*<!--*/
|
|
5288
|
-
const data = {"version":2,"tree":{"name":"root","children":[{"name":"index.js","children":[{"name":"src","children":[{"name":"lib","children":[{"name":"utils","children":[{"uid":"458c-87","name":"removeUndefined.ts"},{"uid":"458c-109","name":"logger.ts"},{"uid":"458c-111","name":"getPathFromFilePath.ts"},{"uid":"458c-121","name":"readFile.ts"},{"uid":"458c-131","name":"getTokenizer.ts"},{"name":"git","children":[{"uid":"458c-133","name":"constants.ts"},{"uid":"458c-135","name":"getSummaryText.ts"},{"uid":"458c-137","name":"getStatus.ts"},{"uid":"458c-139","name":"parsePatches.ts"},{"uid":"458c-141","name":"getChanges.ts"},{"uid":"458c-143","name":"createCommit.ts"}]}]},{"name":"config","children":[{"name":"services","children":[{"uid":"458c-89","name":"env.ts"},{"uid":"458c-91","name":"git.ts"},{"uid":"458c-93","name":"ignore.ts"},{"uid":"458c-95","name":"project.ts"},{"uid":"458c-97","name":"xdg.ts"},{"uid":"458c-99","name":"yargs.ts"}]},{"uid":"458c-105","name":"default.ts"},{"uid":"458c-107","name":"index.ts"}]},{"name":"langchain","children":[{"name":"prompts","children":[{"uid":"458c-101","name":"commitDefault.ts"},{"uid":"458c-103","name":"summarize.ts"}]},{"name":"chains","children":[{"uid":"458c-113","name":"summarize.ts"},{"uid":"458c-145","name":"llm.ts"}]},{"uid":"458c-125","name":"utils.ts"}]},{"name":"parsers","children":[{"name":"default","children":[{"name":"utils","children":[{"uid":"458c-115","name":"summarizeDiffs.ts"},{"uid":"458c-117","name":"createDiffTree.ts"},{"uid":"458c-119","name":"collectDiffs.ts"},{"uid":"458c-123","name":"parseFileDiff.ts"}]},{"uid":"458c-127","name":"fileChangeParser.ts"}]},{"uid":"458c-147","name":"noResult.ts"}]},{"uid":"458c-129","name":"ui.ts"}]},{"uid":"458c-149","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"458c-87":{"renderedLength":258,"gzipLength":0,"brotliLength":141,"metaUid":"458c-86"},"458c-89":{"renderedLength":858,"gzipLength":0,"brotliLength":282,"metaUid":"458c-88"},"458c-91":{"renderedLength":1183,"gzipLength":0,"brotliLength":354,"metaUid":"458c-90"},"458c-93":{"renderedLength":927,"gzipLength":0,"brotliLength":271,"metaUid":"458c-92"},"458c-95":{"renderedLength":367,"gzipLength":0,"brotliLength":172,"metaUid":"458c-94"},"458c-97":{"renderedLength":539,"gzipLength":0,"brotliLength":260,"metaUid":"458c-96"},"458c-99":{"renderedLength":1588,"gzipLength":0,"brotliLength":524,"metaUid":"458c-98"},"458c-101":{"renderedLength":752,"gzipLength":0,"brotliLength":329,"metaUid":"458c-100"},"458c-103":{"renderedLength":369,"gzipLength":0,"brotliLength":200,"metaUid":"458c-102"},"458c-105":{"renderedLength":347,"gzipLength":0,"brotliLength":210,"metaUid":"458c-104"},"458c-107":{"renderedLength":719,"gzipLength":0,"brotliLength":256,"metaUid":"458c-106"},"458c-109":{"renderedLength":1634,"gzipLength":0,"brotliLength":400,"metaUid":"458c-108"},"458c-111":{"renderedLength":256,"gzipLength":0,"brotliLength":151,"metaUid":"458c-110"},"458c-113":{"renderedLength":442,"gzipLength":0,"brotliLength":201,"metaUid":"458c-112"},"458c-115":{"renderedLength":3944,"gzipLength":0,"brotliLength":1184,"metaUid":"458c-114"},"458c-117":{"renderedLength":1262,"gzipLength":0,"brotliLength":380,"metaUid":"458c-116"},"458c-119":{"renderedLength":1199,"gzipLength":0,"brotliLength":428,"metaUid":"458c-118"},"458c-121":{"renderedLength":67,"gzipLength":0,"brotliLength":57,"metaUid":"458c-120"},"458c-123":{"renderedLength":2484,"gzipLength":0,"brotliLength":779,"metaUid":"458c-122"},"458c-125":{"renderedLength":1374,"gzipLength":0,"brotliLength":559,"metaUid":"458c-124"},"458c-127":{"renderedLength":1297,"gzipLength":0,"brotliLength":511,"metaUid":"458c-126"},"458c-129":{"renderedLength":290,"gzipLength":0,"brotliLength":177,"metaUid":"458c-128"},"458c-131":{"renderedLength":573,"gzipLength":0,"brotliLength":239,"metaUid":"458c-130"},"458c-133":{"renderedLength":71,"gzipLength":0,"brotliLength":75,"metaUid":"458c-132"},"458c-135":{"renderedLength":673,"gzipLength":0,"brotliLength":196,"metaUid":"458c-134"},"458c-137":{"renderedLength":517,"gzipLength":0,"brotliLength":152,"metaUid":"458c-136"},"458c-139":{"renderedLength":1786,"gzipLength":0,"brotliLength":593,"metaUid":"458c-138"},"458c-141":{"renderedLength":2800,"gzipLength":0,"brotliLength":843,"metaUid":"458c-140"},"458c-143":{"renderedLength":463,"gzipLength":0,"brotliLength":201,"metaUid":"458c-142"},"458c-145":{"renderedLength":238,"gzipLength":0,"brotliLength":141,"metaUid":"458c-144"},"458c-147":{"renderedLength":1162,"gzipLength":0,"brotliLength":360,"metaUid":"458c-146"},"458c-149":{"renderedLength":5798,"gzipLength":0,"brotliLength":1344,"metaUid":"458c-148"}},"nodeMetas":{"458c-86":{"id":"/src/lib/utils/removeUndefined.ts","moduleParts":{"index.js":"458c-87"},"imported":[],"importedBy":[{"uid":"458c-88"}]},"458c-88":{"id":"/src/lib/config/services/env.ts","moduleParts":{"index.js":"458c-89"},"imported":[{"uid":"458c-86"}],"importedBy":[{"uid":"458c-106"}]},"458c-90":{"id":"/src/lib/config/services/git.ts","moduleParts":{"index.js":"458c-91"},"imported":[{"uid":"458c-163"},{"uid":"458c-164"},{"uid":"458c-165"},{"uid":"458c-166"}],"importedBy":[{"uid":"458c-106"}]},"458c-92":{"id":"/src/lib/config/services/ignore.ts","moduleParts":{"index.js":"458c-93"},"imported":[{"uid":"458c-163"}],"importedBy":[{"uid":"458c-106"}]},"458c-94":{"id":"/src/lib/config/services/project.ts","moduleParts":{"index.js":"458c-95"},"imported":[{"uid":"458c-163"}],"importedBy":[{"uid":"458c-106"}]},"458c-96":{"id":"/src/lib/config/services/xdg.ts","moduleParts":{"index.js":"458c-97"},"imported":[{"uid":"458c-163"},{"uid":"458c-165"},{"uid":"458c-164"}],"importedBy":[{"uid":"458c-106"}]},"458c-98":{"id":"/src/lib/config/services/yargs.ts","moduleParts":{"index.js":"458c-99"},"imported":[{"uid":"458c-153"},{"uid":"458c-154"}],"importedBy":[{"uid":"458c-148"},{"uid":"458c-106"}]},"458c-100":{"id":"/src/lib/langchain/prompts/commitDefault.ts","moduleParts":{"index.js":"458c-101"},"imported":[{"uid":"458c-159"}],"importedBy":[{"uid":"458c-148"},{"uid":"458c-104"}]},"458c-102":{"id":"/src/lib/langchain/prompts/summarize.ts","moduleParts":{"index.js":"458c-103"},"imported":[{"uid":"458c-159"}],"importedBy":[{"uid":"458c-126"},{"uid":"458c-104"}]},"458c-104":{"id":"/src/lib/config/default.ts","moduleParts":{"index.js":"458c-105"},"imported":[{"uid":"458c-100"},{"uid":"458c-102"}],"importedBy":[{"uid":"458c-106"}]},"458c-106":{"id":"/src/lib/config/index.ts","moduleParts":{"index.js":"458c-107"},"imported":[{"uid":"458c-88"},{"uid":"458c-90"},{"uid":"458c-92"},{"uid":"458c-94"},{"uid":"458c-96"},{"uid":"458c-98"},{"uid":"458c-104"}],"importedBy":[{"uid":"458c-148"},{"uid":"458c-126"},{"uid":"458c-140"},{"uid":"458c-114"},{"uid":"458c-118"},{"uid":"458c-138"}]},"458c-108":{"id":"/src/lib/utils/logger.ts","moduleParts":{"index.js":"458c-109"},"imported":[{"uid":"458c-152"},{"uid":"458c-156"},{"uid":"458c-157"},{"uid":"458c-158"}],"importedBy":[{"uid":"458c-148"},{"uid":"458c-126"},{"uid":"458c-114"},{"uid":"458c-118"}]},"458c-110":{"id":"/src/lib/utils/getPathFromFilePath.ts","moduleParts":{"index.js":"458c-111"},"imported":[],"importedBy":[{"uid":"458c-114"}]},"458c-112":{"id":"/src/lib/langchain/chains/summarize.ts","moduleParts":{"index.js":"458c-113"},"imported":[{"uid":"458c-170"}],"importedBy":[{"uid":"458c-114"}]},"458c-114":{"id":"/src/lib/parsers/default/utils/summarizeDiffs.ts","moduleParts":{"index.js":"458c-115"},"imported":[{"uid":"458c-167"},{"uid":"458c-108"},{"uid":"458c-106"},{"uid":"458c-110"},{"uid":"458c-112"}],"importedBy":[{"uid":"458c-126"}]},"458c-116":{"id":"/src/lib/parsers/default/utils/createDiffTree.ts","moduleParts":{"index.js":"458c-117"},"imported":[],"importedBy":[{"uid":"458c-126"}]},"458c-118":{"id":"/src/lib/parsers/default/utils/collectDiffs.ts","moduleParts":{"index.js":"458c-119"},"imported":[{"uid":"458c-106"},{"uid":"458c-108"}],"importedBy":[{"uid":"458c-126"}]},"458c-120":{"id":"/src/lib/utils/readFile.ts","moduleParts":{"index.js":"458c-121"},"imported":[{"uid":"458c-163"},{"uid":"458c-171"}],"importedBy":[{"uid":"458c-122"}]},"458c-122":{"id":"/src/lib/parsers/default/utils/parseFileDiff.ts","moduleParts":{"index.js":"458c-123"},"imported":[{"uid":"458c-150"},{"uid":"458c-168"},{"uid":"458c-120"}],"importedBy":[{"uid":"458c-126"}]},"458c-124":{"id":"/src/lib/langchain/utils.ts","moduleParts":{"index.js":"458c-125"},"imported":[{"uid":"458c-159"},{"uid":"458c-160"},{"uid":"458c-161"},{"uid":"458c-162"}],"importedBy":[{"uid":"458c-148"},{"uid":"458c-126"}]},"458c-126":{"id":"/src/lib/parsers/default/fileChangeParser.ts","moduleParts":{"index.js":"458c-127"},"imported":[{"uid":"458c-106"},{"uid":"458c-114"},{"uid":"458c-108"},{"uid":"458c-116"},{"uid":"458c-118"},{"uid":"458c-122"},{"uid":"458c-124"},{"uid":"458c-102"}],"importedBy":[{"uid":"458c-148"}]},"458c-128":{"id":"/src/lib/ui.ts","moduleParts":{"index.js":"458c-129"},"imported":[{"uid":"458c-152"}],"importedBy":[{"uid":"458c-148"}]},"458c-130":{"id":"/src/lib/utils/getTokenizer.ts","moduleParts":{"index.js":"458c-131"},"imported":[{"uid":"458c-155"}],"importedBy":[{"uid":"458c-148"}]},"458c-132":{"id":"/src/lib/utils/git/constants.ts","moduleParts":{"index.js":"458c-133"},"imported":[],"importedBy":[{"uid":"458c-140"}]},"458c-134":{"id":"/src/lib/utils/git/getSummaryText.ts","moduleParts":{"index.js":"458c-135"},"imported":[],"importedBy":[{"uid":"458c-138"}]},"458c-136":{"id":"/src/lib/utils/git/getStatus.ts","moduleParts":{"index.js":"458c-137"},"imported":[],"importedBy":[{"uid":"458c-138"}]},"458c-138":{"id":"/src/lib/utils/git/parsePatches.ts","moduleParts":{"index.js":"458c-139"},"imported":[{"uid":"458c-169"},{"uid":"458c-106"},{"uid":"458c-134"},{"uid":"458c-136"}],"importedBy":[{"uid":"458c-140"}]},"458c-140":{"id":"/src/lib/utils/git/getChanges.ts","moduleParts":{"index.js":"458c-141"},"imported":[{"uid":"458c-150"},{"uid":"458c-106"},{"uid":"458c-132"},{"uid":"458c-138"}],"importedBy":[{"uid":"458c-148"},{"uid":"458c-146"}]},"458c-142":{"id":"/src/lib/utils/git/createCommit.ts","moduleParts":{"index.js":"458c-143"},"imported":[{"uid":"458c-150"}],"importedBy":[{"uid":"458c-148"}]},"458c-144":{"id":"/src/lib/langchain/chains/llm.ts","moduleParts":{"index.js":"458c-145"},"imported":[{"uid":"458c-160"}],"importedBy":[{"uid":"458c-148"}]},"458c-146":{"id":"/src/lib/parsers/noResult.ts","moduleParts":{"index.js":"458c-147"},"imported":[{"uid":"458c-140"}],"importedBy":[{"uid":"458c-148"}]},"458c-148":{"id":"/src/index.ts","moduleParts":{"index.js":"458c-149"},"imported":[{"uid":"458c-150"},{"uid":"458c-151"},{"uid":"458c-106"},{"uid":"458c-126"},{"uid":"458c-128"},{"uid":"458c-98"},{"uid":"458c-130"},{"uid":"458c-108"},{"uid":"458c-140"},{"uid":"458c-100"},{"uid":"458c-124"},{"uid":"458c-142"},{"uid":"458c-144"},{"uid":"458c-146"}],"importedBy":[],"isEntry":true},"458c-150":{"id":"nodegit","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-148"},{"uid":"458c-140"},{"uid":"458c-142"},{"uid":"458c-122"}],"isExternal":true},"458c-151":{"id":"@inquirer/prompts","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-148"}],"isExternal":true},"458c-152":{"id":"chalk","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-128"},{"uid":"458c-108"}],"isExternal":true},"458c-153":{"id":"yargs","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-98"}],"isExternal":true},"458c-154":{"id":"yargs/helpers","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-98"}],"isExternal":true},"458c-155":{"id":"gpt3-tokenizer","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-130"}],"isExternal":true},"458c-156":{"id":"ora","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-108"}],"isExternal":true},"458c-157":{"id":"performance-now","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-108"}],"isExternal":true},"458c-158":{"id":"pretty-ms","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-108"}],"isExternal":true},"458c-159":{"id":"langchain/prompts","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-100"},{"uid":"458c-124"},{"uid":"458c-102"}],"isExternal":true},"458c-160":{"id":"langchain/chains","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-124"},{"uid":"458c-144"}],"isExternal":true},"458c-161":{"id":"langchain/llms/openai","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-124"}],"isExternal":true},"458c-162":{"id":"langchain/text_splitter","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-124"}],"isExternal":true},"458c-163":{"id":"fs","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-90"},{"uid":"458c-92"},{"uid":"458c-94"},{"uid":"458c-96"},{"uid":"458c-120"}],"isExternal":true},"458c-164":{"id":"os","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-90"},{"uid":"458c-96"}],"isExternal":true},"458c-165":{"id":"path","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-90"},{"uid":"458c-96"}],"isExternal":true},"458c-166":{"id":"ini","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-90"}],"isExternal":true},"458c-167":{"id":"p-queue","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-114"}],"isExternal":true},"458c-168":{"id":"diff","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-122"}],"isExternal":true},"458c-169":{"id":"minimatch","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-138"}],"isExternal":true},"458c-170":{"id":"langchain/document","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-112"}],"isExternal":true},"458c-171":{"id":"util","moduleParts":{},"imported":[],"importedBy":[{"uid":"458c-120"}],"isExternal":true}},"env":{"rollup":"3.26.1"},"options":{"gzip":false,"brotli":true,"sourcemap":false}};
|
|
5288
|
+
const data = {"version":2,"tree":{"name":"root","children":[{"name":"index.js","children":[{"name":"src","children":[{"name":"lib","children":[{"name":"utils","children":[{"uid":"7909-80","name":"removeUndefined.ts"},{"uid":"7909-102","name":"logger.ts"},{"uid":"7909-104","name":"getPathFromFilePath.ts"},{"uid":"7909-122","name":"getTokenizer.ts"}]},{"name":"config","children":[{"name":"services","children":[{"uid":"7909-82","name":"env.ts"},{"uid":"7909-84","name":"git.ts"},{"uid":"7909-86","name":"ignore.ts"},{"uid":"7909-88","name":"project.ts"},{"uid":"7909-90","name":"xdg.ts"},{"uid":"7909-92","name":"yargs.ts"}]},{"uid":"7909-98","name":"default.ts"},{"uid":"7909-100","name":"index.ts"}]},{"name":"langchain","children":[{"name":"prompts","children":[{"uid":"7909-94","name":"commitDefault.ts"},{"uid":"7909-96","name":"summarize.ts"}]},{"name":"chains","children":[{"uid":"7909-106","name":"summarize.ts"},{"uid":"7909-124","name":"llm.ts"}]},{"uid":"7909-114","name":"utils.ts"}]},{"name":"parsers","children":[{"name":"default","children":[{"name":"utils","children":[{"uid":"7909-108","name":"summarizeDiffs.ts"},{"uid":"7909-110","name":"createDiffTree.ts"},{"uid":"7909-112","name":"collectDiffs.ts"}]},{"uid":"7909-118","name":"index.ts"}]},{"uid":"7909-132","name":"noResult.ts"}]},{"name":"simple-git","children":[{"uid":"7909-116","name":"getDiff.ts"},{"uid":"7909-126","name":"getStatus.ts"},{"uid":"7909-128","name":"getSummaryText.ts"},{"uid":"7909-130","name":"getChanges.ts"},{"uid":"7909-134","name":"createCommit.ts"}]},{"uid":"7909-120","name":"ui.ts"}]},{"uid":"7909-136","name":"index.ts"}]}]}],"isRoot":true},"nodeParts":{"7909-80":{"renderedLength":258,"gzipLength":0,"brotliLength":141,"metaUid":"7909-79"},"7909-82":{"renderedLength":858,"gzipLength":0,"brotliLength":282,"metaUid":"7909-81"},"7909-84":{"renderedLength":1183,"gzipLength":0,"brotliLength":354,"metaUid":"7909-83"},"7909-86":{"renderedLength":927,"gzipLength":0,"brotliLength":271,"metaUid":"7909-85"},"7909-88":{"renderedLength":367,"gzipLength":0,"brotliLength":172,"metaUid":"7909-87"},"7909-90":{"renderedLength":539,"gzipLength":0,"brotliLength":260,"metaUid":"7909-89"},"7909-92":{"renderedLength":1588,"gzipLength":0,"brotliLength":524,"metaUid":"7909-91"},"7909-94":{"renderedLength":752,"gzipLength":0,"brotliLength":329,"metaUid":"7909-93"},"7909-96":{"renderedLength":369,"gzipLength":0,"brotliLength":200,"metaUid":"7909-95"},"7909-98":{"renderedLength":347,"gzipLength":0,"brotliLength":210,"metaUid":"7909-97"},"7909-100":{"renderedLength":719,"gzipLength":0,"brotliLength":256,"metaUid":"7909-99"},"7909-102":{"renderedLength":1634,"gzipLength":0,"brotliLength":400,"metaUid":"7909-101"},"7909-104":{"renderedLength":256,"gzipLength":0,"brotliLength":151,"metaUid":"7909-103"},"7909-106":{"renderedLength":442,"gzipLength":0,"brotliLength":201,"metaUid":"7909-105"},"7909-108":{"renderedLength":3948,"gzipLength":0,"brotliLength":1183,"metaUid":"7909-107"},"7909-110":{"renderedLength":1262,"gzipLength":0,"brotliLength":380,"metaUid":"7909-109"},"7909-112":{"renderedLength":1199,"gzipLength":0,"brotliLength":428,"metaUid":"7909-111"},"7909-114":{"renderedLength":1374,"gzipLength":0,"brotliLength":559,"metaUid":"7909-113"},"7909-116":{"renderedLength":1586,"gzipLength":0,"brotliLength":527,"metaUid":"7909-115"},"7909-118":{"renderedLength":1143,"gzipLength":0,"brotliLength":468,"metaUid":"7909-117"},"7909-120":{"renderedLength":290,"gzipLength":0,"brotliLength":177,"metaUid":"7909-119"},"7909-122":{"renderedLength":573,"gzipLength":0,"brotliLength":239,"metaUid":"7909-121"},"7909-124":{"renderedLength":238,"gzipLength":0,"brotliLength":141,"metaUid":"7909-123"},"7909-126":{"renderedLength":602,"gzipLength":0,"brotliLength":177,"metaUid":"7909-125"},"7909-128":{"renderedLength":239,"gzipLength":0,"brotliLength":140,"metaUid":"7909-127"},"7909-130":{"renderedLength":2504,"gzipLength":0,"brotliLength":529,"metaUid":"7909-129"},"7909-132":{"renderedLength":1088,"gzipLength":0,"brotliLength":343,"metaUid":"7909-131"},"7909-134":{"renderedLength":87,"gzipLength":0,"brotliLength":71,"metaUid":"7909-133"},"7909-136":{"renderedLength":5706,"gzipLength":0,"brotliLength":1318,"metaUid":"7909-135"}},"nodeMetas":{"7909-79":{"id":"/src/lib/utils/removeUndefined.ts","moduleParts":{"index.js":"7909-80"},"imported":[],"importedBy":[{"uid":"7909-81"}]},"7909-81":{"id":"/src/lib/config/services/env.ts","moduleParts":{"index.js":"7909-82"},"imported":[{"uid":"7909-79"}],"importedBy":[{"uid":"7909-99"}]},"7909-83":{"id":"/src/lib/config/services/git.ts","moduleParts":{"index.js":"7909-84"},"imported":[{"uid":"7909-152"},{"uid":"7909-153"},{"uid":"7909-150"},{"uid":"7909-154"}],"importedBy":[{"uid":"7909-99"}]},"7909-85":{"id":"/src/lib/config/services/ignore.ts","moduleParts":{"index.js":"7909-86"},"imported":[{"uid":"7909-152"}],"importedBy":[{"uid":"7909-99"}]},"7909-87":{"id":"/src/lib/config/services/project.ts","moduleParts":{"index.js":"7909-88"},"imported":[{"uid":"7909-152"}],"importedBy":[{"uid":"7909-99"}]},"7909-89":{"id":"/src/lib/config/services/xdg.ts","moduleParts":{"index.js":"7909-90"},"imported":[{"uid":"7909-152"},{"uid":"7909-150"},{"uid":"7909-153"}],"importedBy":[{"uid":"7909-99"}]},"7909-91":{"id":"/src/lib/config/services/yargs.ts","moduleParts":{"index.js":"7909-92"},"imported":[{"uid":"7909-140"},{"uid":"7909-141"}],"importedBy":[{"uid":"7909-135"},{"uid":"7909-99"}]},"7909-93":{"id":"/src/lib/langchain/prompts/commitDefault.ts","moduleParts":{"index.js":"7909-94"},"imported":[{"uid":"7909-146"}],"importedBy":[{"uid":"7909-135"},{"uid":"7909-97"}]},"7909-95":{"id":"/src/lib/langchain/prompts/summarize.ts","moduleParts":{"index.js":"7909-96"},"imported":[{"uid":"7909-146"}],"importedBy":[{"uid":"7909-117"},{"uid":"7909-97"}]},"7909-97":{"id":"/src/lib/config/default.ts","moduleParts":{"index.js":"7909-98"},"imported":[{"uid":"7909-93"},{"uid":"7909-95"}],"importedBy":[{"uid":"7909-99"}]},"7909-99":{"id":"/src/lib/config/index.ts","moduleParts":{"index.js":"7909-100"},"imported":[{"uid":"7909-81"},{"uid":"7909-83"},{"uid":"7909-85"},{"uid":"7909-87"},{"uid":"7909-89"},{"uid":"7909-91"},{"uid":"7909-97"}],"importedBy":[{"uid":"7909-135"},{"uid":"7909-117"},{"uid":"7909-129"},{"uid":"7909-107"},{"uid":"7909-111"}]},"7909-101":{"id":"/src/lib/utils/logger.ts","moduleParts":{"index.js":"7909-102"},"imported":[{"uid":"7909-139"},{"uid":"7909-143"},{"uid":"7909-144"},{"uid":"7909-145"}],"importedBy":[{"uid":"7909-135"},{"uid":"7909-117"},{"uid":"7909-107"},{"uid":"7909-111"}]},"7909-103":{"id":"/src/lib/utils/getPathFromFilePath.ts","moduleParts":{"index.js":"7909-104"},"imported":[],"importedBy":[{"uid":"7909-107"}]},"7909-105":{"id":"/src/lib/langchain/chains/summarize.ts","moduleParts":{"index.js":"7909-106"},"imported":[{"uid":"7909-157"}],"importedBy":[{"uid":"7909-107"}]},"7909-107":{"id":"/src/lib/parsers/default/utils/summarizeDiffs.ts","moduleParts":{"index.js":"7909-108"},"imported":[{"uid":"7909-155"},{"uid":"7909-101"},{"uid":"7909-99"},{"uid":"7909-103"},{"uid":"7909-105"}],"importedBy":[{"uid":"7909-117"}]},"7909-109":{"id":"/src/lib/parsers/default/utils/createDiffTree.ts","moduleParts":{"index.js":"7909-110"},"imported":[],"importedBy":[{"uid":"7909-117"}]},"7909-111":{"id":"/src/lib/parsers/default/utils/collectDiffs.ts","moduleParts":{"index.js":"7909-112"},"imported":[{"uid":"7909-99"},{"uid":"7909-101"}],"importedBy":[{"uid":"7909-117"}]},"7909-113":{"id":"/src/lib/langchain/utils.ts","moduleParts":{"index.js":"7909-114"},"imported":[{"uid":"7909-146"},{"uid":"7909-147"},{"uid":"7909-148"},{"uid":"7909-149"}],"importedBy":[{"uid":"7909-135"},{"uid":"7909-117"}]},"7909-115":{"id":"/src/lib/simple-git/getDiff.ts","moduleParts":{"index.js":"7909-116"},"imported":[{"uid":"7909-156"}],"importedBy":[{"uid":"7909-117"}]},"7909-117":{"id":"/src/lib/parsers/default/index.ts","moduleParts":{"index.js":"7909-118"},"imported":[{"uid":"7909-99"},{"uid":"7909-107"},{"uid":"7909-101"},{"uid":"7909-109"},{"uid":"7909-111"},{"uid":"7909-113"},{"uid":"7909-95"},{"uid":"7909-115"}],"importedBy":[{"uid":"7909-135"}]},"7909-119":{"id":"/src/lib/ui.ts","moduleParts":{"index.js":"7909-120"},"imported":[{"uid":"7909-139"}],"importedBy":[{"uid":"7909-135"}]},"7909-121":{"id":"/src/lib/utils/getTokenizer.ts","moduleParts":{"index.js":"7909-122"},"imported":[{"uid":"7909-142"}],"importedBy":[{"uid":"7909-135"}]},"7909-123":{"id":"/src/lib/langchain/chains/llm.ts","moduleParts":{"index.js":"7909-124"},"imported":[{"uid":"7909-147"}],"importedBy":[{"uid":"7909-135"}]},"7909-125":{"id":"/src/lib/simple-git/getStatus.ts","moduleParts":{"index.js":"7909-126"},"imported":[],"importedBy":[{"uid":"7909-129"},{"uid":"7909-127"}]},"7909-127":{"id":"/src/lib/simple-git/getSummaryText.ts","moduleParts":{"index.js":"7909-128"},"imported":[{"uid":"7909-125"}],"importedBy":[{"uid":"7909-129"}]},"7909-129":{"id":"/src/lib/simple-git/getChanges.ts","moduleParts":{"index.js":"7909-130"},"imported":[{"uid":"7909-150"},{"uid":"7909-151"},{"uid":"7909-99"},{"uid":"7909-125"},{"uid":"7909-127"}],"importedBy":[{"uid":"7909-135"},{"uid":"7909-131"}]},"7909-131":{"id":"/src/lib/parsers/noResult.ts","moduleParts":{"index.js":"7909-132"},"imported":[{"uid":"7909-129"}],"importedBy":[{"uid":"7909-135"}]},"7909-133":{"id":"/src/lib/simple-git/createCommit.ts","moduleParts":{"index.js":"7909-134"},"imported":[],"importedBy":[{"uid":"7909-135"}]},"7909-135":{"id":"/src/index.ts","moduleParts":{"index.js":"7909-136"},"imported":[{"uid":"7909-137"},{"uid":"7909-99"},{"uid":"7909-117"},{"uid":"7909-119"},{"uid":"7909-91"},{"uid":"7909-121"},{"uid":"7909-101"},{"uid":"7909-93"},{"uid":"7909-113"},{"uid":"7909-123"},{"uid":"7909-131"},{"uid":"7909-129"},{"uid":"7909-133"},{"uid":"7909-138"}],"importedBy":[],"isEntry":true},"7909-137":{"id":"@inquirer/prompts","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-135"}],"isExternal":true},"7909-138":{"id":"simple-git","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-135"}],"isExternal":true},"7909-139":{"id":"chalk","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-119"},{"uid":"7909-101"}],"isExternal":true},"7909-140":{"id":"yargs","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-91"}],"isExternal":true},"7909-141":{"id":"yargs/helpers","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-91"}],"isExternal":true},"7909-142":{"id":"gpt3-tokenizer","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-121"}],"isExternal":true},"7909-143":{"id":"ora","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-101"}],"isExternal":true},"7909-144":{"id":"performance-now","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-101"}],"isExternal":true},"7909-145":{"id":"pretty-ms","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-101"}],"isExternal":true},"7909-146":{"id":"langchain/prompts","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-93"},{"uid":"7909-113"},{"uid":"7909-95"}],"isExternal":true},"7909-147":{"id":"langchain/chains","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-113"},{"uid":"7909-123"}],"isExternal":true},"7909-148":{"id":"langchain/llms/openai","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-113"}],"isExternal":true},"7909-149":{"id":"langchain/text_splitter","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-113"}],"isExternal":true},"7909-150":{"id":"path","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-129"},{"uid":"7909-83"},{"uid":"7909-89"}],"isExternal":true},"7909-151":{"id":"minimatch","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-129"}],"isExternal":true},"7909-152":{"id":"fs","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-83"},{"uid":"7909-85"},{"uid":"7909-87"},{"uid":"7909-89"}],"isExternal":true},"7909-153":{"id":"os","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-83"},{"uid":"7909-89"}],"isExternal":true},"7909-154":{"id":"ini","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-83"}],"isExternal":true},"7909-155":{"id":"p-queue","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-107"}],"isExternal":true},"7909-156":{"id":"diff","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-115"}],"isExternal":true},"7909-157":{"id":"langchain/document","moduleParts":{},"imported":[],"importedBy":[{"uid":"7909-105"}],"isExternal":true}},"env":{"rollup":"3.26.1"},"options":{"gzip":false,"brotli":true,"sourcemap":false}};
|
|
5289
5289
|
|
|
5290
5290
|
const run = () => {
|
|
5291
5291
|
const width = window.innerWidth;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "git-coco",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.2.1",
|
|
4
4
|
"description": "zero-effort git commits with commit copilot, or coco for short.",
|
|
5
5
|
"author": "gfargo <ghfargo@gmail.com>",
|
|
6
6
|
"license": "MIT",
|
|
@@ -48,7 +48,6 @@
|
|
|
48
48
|
"@types/ini": "^1.3.31",
|
|
49
49
|
"@types/inquirer": "^9.0.3",
|
|
50
50
|
"@types/jest": "^29.5.2",
|
|
51
|
-
"@types/nodegit": "^0.28.3",
|
|
52
51
|
"@types/yargs": "^17.0.24",
|
|
53
52
|
"@typescript-eslint/eslint-plugin": "^5.61.0",
|
|
54
53
|
"@typescript-eslint/parser": "^5.61.0",
|
|
@@ -74,18 +73,18 @@
|
|
|
74
73
|
},
|
|
75
74
|
"dependencies": {
|
|
76
75
|
"@inquirer/prompts": "^2.3.0",
|
|
77
|
-
"chalk": "
|
|
76
|
+
"chalk": "4.1.2",
|
|
78
77
|
"diff": "^5.1.0",
|
|
79
78
|
"gpt3-tokenizer": "^1.1.5",
|
|
80
79
|
"ini": "^4.1.1",
|
|
81
|
-
"langchain": "^0.0.
|
|
82
|
-
"minimatch": "^9.0.
|
|
83
|
-
"
|
|
84
|
-
"
|
|
85
|
-
"
|
|
86
|
-
"
|
|
87
|
-
"
|
|
88
|
-
"
|
|
80
|
+
"langchain": "^0.0.105",
|
|
81
|
+
"minimatch": "^9.0.3",
|
|
82
|
+
"openai": "3.3.0",
|
|
83
|
+
"ora": "5.4.1",
|
|
84
|
+
"p-queue": "5.0.0",
|
|
85
|
+
"performance-now": "2.1.0",
|
|
86
|
+
"pretty-ms": "7.0.1",
|
|
87
|
+
"simple-git": "^3.19.1",
|
|
89
88
|
"yargs": "^17.7.2"
|
|
90
89
|
}
|
|
91
90
|
}
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import { Repository, Tree, Index } from 'nodegit';
|
|
2
|
-
import { FileChange } from '../../../types';
|
|
3
|
-
import { Logger } from '../../../utils/logger';
|
|
4
|
-
export declare const parseFileDiff: (nodeFile: FileChange, repo: Repository, headTree: Tree, index: Index, logger: Logger) => Promise<string>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const EMPTY_GIT_TREE_HASH = "4b825dc642cb6eb9a060e54bf8d69288fbee4904";
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import { Repository } from 'nodegit';
|
|
2
|
-
import { FileChange } from '../../types';
|
|
3
|
-
export type GetChangesArgs = {
|
|
4
|
-
ignoreUnstaged?: boolean;
|
|
5
|
-
ignoreUntracked?: boolean;
|
|
6
|
-
ignoredFiles?: string[];
|
|
7
|
-
ignoredExtensions?: string[];
|
|
8
|
-
};
|
|
9
|
-
export type GetChangesResult = {
|
|
10
|
-
staged: FileChange[];
|
|
11
|
-
unstaged?: FileChange[];
|
|
12
|
-
untracked?: FileChange[];
|
|
13
|
-
};
|
|
14
|
-
/**
|
|
15
|
-
* The 'git status' for coco
|
|
16
|
-
*
|
|
17
|
-
* Get paths of changed files in the Git repository, excluding ignored files and extensions.
|
|
18
|
-
*
|
|
19
|
-
* @param {string[]} [options.ignoredFiles] - An optional array of file patterns to ignore.
|
|
20
|
-
* If not provided, it defaults to the `ignoredFiles` configuration value from the app's config.
|
|
21
|
-
* @param {string[]} [options.ignoredExtensions] - An optional array of file extensions to ignore.
|
|
22
|
-
* If not provided, it defaults to the `ignoredExtensions` configuration value from the app's config.
|
|
23
|
-
* @returns {Promise<GetChangesResult>} A Promise that resolves to an array of changed file paths.
|
|
24
|
-
*
|
|
25
|
-
* @example
|
|
26
|
-
* const changes = await getStagedChanges()
|
|
27
|
-
* console.log(changes)
|
|
28
|
-
* // {
|
|
29
|
-
* // staged: [
|
|
30
|
-
* // {
|
|
31
|
-
* // filepath: 'src/index.ts',
|
|
32
|
-
* // action: 'modified'
|
|
33
|
-
* // },
|
|
34
|
-
* // ],
|
|
35
|
-
* // unstaged: [
|
|
36
|
-
* // {
|
|
37
|
-
* // filepath: 'src/index.test.ts',
|
|
38
|
-
* // action: 'added'
|
|
39
|
-
* // }
|
|
40
|
-
* // ]
|
|
41
|
-
* // }
|
|
42
|
-
*/
|
|
43
|
-
export declare function getChanges(repo: Repository, options?: GetChangesArgs): Promise<GetChangesResult>;
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { ConvenientPatch } from 'nodegit';
|
|
2
|
-
import { FileChange } from '../../types';
|
|
3
|
-
type ParsePatchesOptions = {
|
|
4
|
-
ignoredFiles?: string[];
|
|
5
|
-
ignoredExtensions?: string[];
|
|
6
|
-
};
|
|
7
|
-
/**
|
|
8
|
-
* Parse patches from a git diff.
|
|
9
|
-
*
|
|
10
|
-
* @param {ConvenientPatch[]} patches - An array of git patches.
|
|
11
|
-
* @param {string[]} [options.ignoredFiles] - An optional array of file patterns to ignore.
|
|
12
|
-
* If not provided, it defaults to the `ignoredFiles` configuration value from the app's config.
|
|
13
|
-
* @param {string[]} [options.ignoredExtensions] - An optional array of file extensions to ignore.
|
|
14
|
-
* If not provided, it defaults to the `ignoredExtensions` configuration value from the app's config.
|
|
15
|
-
* @returns {Promise<FileChange[]>} A Promise that resolves to an array of file changes.
|
|
16
|
-
**/
|
|
17
|
-
export declare const parsePatches: (patches: ConvenientPatch[], { ignoredFiles, ignoredExtensions, }: ParsePatchesOptions) => Promise<FileChange[]>;
|
|
18
|
-
export {};
|
|
File without changes
|