codebuff 1.0.506 → 1.0.508
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/index.js +7 -3
- package/package.json +2 -2
package/index.js
CHANGED
|
@@ -14,7 +14,7 @@ const CONFIG = {
|
|
|
14
14
|
homeDir: os.homedir(),
|
|
15
15
|
configDir: path.join(os.homedir(), '.config', 'manicode'),
|
|
16
16
|
binaryName: process.platform === 'win32' ? 'codebuff.exe' : 'codebuff',
|
|
17
|
-
githubRepo: 'CodebuffAI/codebuff
|
|
17
|
+
githubRepo: 'CodebuffAI/codebuff',
|
|
18
18
|
userAgent: 'codebuff-cli',
|
|
19
19
|
requestTimeout: 20000,
|
|
20
20
|
}
|
|
@@ -102,10 +102,10 @@ async function getLatestVersion() {
|
|
|
102
102
|
|
|
103
103
|
// Parse the Atom XML to extract the latest release tag
|
|
104
104
|
const tagMatch = body.match(
|
|
105
|
-
/<id>tag:github\.com,2008:Repository\/\d+\/(
|
|
105
|
+
/<id>tag:github\.com,2008:Repository\/\d+\/v(\d+\.\d+\.\d+)<\/id>/,
|
|
106
106
|
)
|
|
107
107
|
if (tagMatch && tagMatch[1]) {
|
|
108
|
-
return tagMatch[1]
|
|
108
|
+
return tagMatch[1]
|
|
109
109
|
}
|
|
110
110
|
|
|
111
111
|
return null
|
|
@@ -179,6 +179,10 @@ function getCurrentVersion() {
|
|
|
179
179
|
function compareVersions(v1, v2) {
|
|
180
180
|
if (!v1 || !v2) return 0
|
|
181
181
|
|
|
182
|
+
if (!v1.match(/^\d+(\.\d+)*$/)) {
|
|
183
|
+
return -1
|
|
184
|
+
}
|
|
185
|
+
|
|
182
186
|
const parts1 = v1.split('.').map(Number)
|
|
183
187
|
const parts2 = v2.split('.').map(Number)
|
|
184
188
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "codebuff",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.508",
|
|
4
4
|
"description": "AI coding agent",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"bin": {
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
},
|
|
33
33
|
"repository": {
|
|
34
34
|
"type": "git",
|
|
35
|
-
"url": "https://github.com/CodebuffAI/codebuff
|
|
35
|
+
"url": "https://github.com/CodebuffAI/codebuff.git"
|
|
36
36
|
},
|
|
37
37
|
"homepage": "https://codebuff.com",
|
|
38
38
|
"publishConfig": {
|