@senoldogann/context-manager 0.1.25 → 0.1.26
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 +5 -0
- package/bin/ccm.js +11 -2
- package/package.json +6 -1
package/README.md
CHANGED
|
@@ -190,6 +190,11 @@ Enable `CCM_EMBED_DATA_FILES=1` to include them in semantic search.
|
|
|
190
190
|
|
|
191
191
|
## 📝 Changelog
|
|
192
192
|
|
|
193
|
+
### v0.1.26
|
|
194
|
+
- ✅ Trusted publishing workflow updated for modern Node and npm requirements
|
|
195
|
+
- ✅ Release jobs now skip npm publish when the same version is already live
|
|
196
|
+
- ✅ Safer wrapper binary downloads during concurrent first-run installs
|
|
197
|
+
|
|
193
198
|
### v0.1.25
|
|
194
199
|
- ✅ npm publish now uses GitHub Actions trusted publishing (OIDC)
|
|
195
200
|
- ✅ Clearer first-run verification and release reliability docs
|
package/bin/ccm.js
CHANGED
|
@@ -7,7 +7,7 @@ const os = require('os');
|
|
|
7
7
|
const https = require('https');
|
|
8
8
|
const crypto = require('crypto');
|
|
9
9
|
|
|
10
|
-
const VERSION = "0.1.
|
|
10
|
+
const VERSION = "0.1.26";
|
|
11
11
|
const REPO = 'senoldogann/LLM-Context-Manager';
|
|
12
12
|
const BIN_DIR = path.join(os.homedir(), '.ccm', 'bin');
|
|
13
13
|
const CHECKSUMS_FILE = 'checksums.txt';
|
|
@@ -159,6 +159,10 @@ function installCodexConfig() {
|
|
|
159
159
|
return true;
|
|
160
160
|
}
|
|
161
161
|
|
|
162
|
+
function createUniqueTmpPath(binPath) {
|
|
163
|
+
return `${binPath}.${process.pid}.${Date.now()}.tmp`;
|
|
164
|
+
}
|
|
165
|
+
|
|
162
166
|
async function getBinaryFor(commandName) {
|
|
163
167
|
const platform = os.platform();
|
|
164
168
|
const arch = os.arch();
|
|
@@ -193,12 +197,16 @@ async function getBinaryFor(commandName) {
|
|
|
193
197
|
}
|
|
194
198
|
|
|
195
199
|
const url = `https://github.com/${REPO}/releases/download/v${VERSION}/${commandName}-${target}`;
|
|
196
|
-
const tmpPath =
|
|
200
|
+
const tmpPath = createUniqueTmpPath(binPath);
|
|
197
201
|
|
|
198
202
|
try {
|
|
199
203
|
await downloadFile(url, tmpPath);
|
|
200
204
|
await verifyChecksum(tmpPath, [remoteFilename, binFilename]);
|
|
201
205
|
fs.chmodSync(tmpPath, '755');
|
|
206
|
+
if (fs.existsSync(binPath)) {
|
|
207
|
+
fs.unlinkSync(tmpPath);
|
|
208
|
+
return binPath;
|
|
209
|
+
}
|
|
202
210
|
fs.renameSync(tmpPath, binPath);
|
|
203
211
|
} catch (err) {
|
|
204
212
|
if (fs.existsSync(tmpPath)) fs.unlinkSync(tmpPath);
|
|
@@ -228,6 +236,7 @@ async function getBinary() {
|
|
|
228
236
|
|
|
229
237
|
function downloadFile(url, dest) {
|
|
230
238
|
return new Promise((resolve, reject) => {
|
|
239
|
+
fs.mkdirSync(path.dirname(dest), { recursive: true });
|
|
231
240
|
https.get(url, (response) => {
|
|
232
241
|
if (response.statusCode === 302 || response.statusCode === 301) {
|
|
233
242
|
try {
|
package/package.json
CHANGED
|
@@ -1,7 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@senoldogann/context-manager",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.26",
|
|
4
4
|
"description": "LLM Context Manager MCP Server & CLI wrapper using npx",
|
|
5
|
+
"repository": "https://github.com/senoldogann/LLM-Context-Manager",
|
|
6
|
+
"homepage": "https://github.com/senoldogann/LLM-Context-Manager",
|
|
7
|
+
"bugs": {
|
|
8
|
+
"url": "https://github.com/senoldogann/LLM-Context-Manager/issues"
|
|
9
|
+
},
|
|
5
10
|
"main": "bin/ccm.js",
|
|
6
11
|
"bin": {
|
|
7
12
|
"ccm-cli": "bin/ccm.js",
|