openkbs 0.0.83 → 0.0.86
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/package.json
CHANGED
package/src/utils.js
CHANGED
|
@@ -742,7 +742,7 @@ async function downloadFiles(namespaces, kbId, kbToken, location = 'origin', tar
|
|
|
742
742
|
|
|
743
743
|
await Promise.all(filesToDownload.map(async ({ namespace, file, fileName }) => {
|
|
744
744
|
let fileContent;
|
|
745
|
-
if (location === 'origin') {
|
|
745
|
+
if (location === 'origin' || location === 'cache') {
|
|
746
746
|
const presignedURL = await getPresignedURL(namespace, kbId, fileName, 'getObject', kbToken);
|
|
747
747
|
fileContent = await downloadFile(presignedURL);
|
|
748
748
|
} else {
|
|
@@ -1006,7 +1006,7 @@ async function uploadFiles(namespaces, kbId, kbToken, location = 'origin', targe
|
|
|
1006
1006
|
const uploadPromises = filesToUpload.map(async ({ namespace, filePath, fileName }) => {
|
|
1007
1007
|
const fileContent = await fs.readFile(filePath);
|
|
1008
1008
|
console.log(`Uploading: ${fileName}`);
|
|
1009
|
-
if (location === 'origin') {
|
|
1009
|
+
if (location === 'origin' || location === 'cache') {
|
|
1010
1010
|
const presignedURL = await getPresignedURL(namespace, kbId, fileName, 'putObject', kbToken);
|
|
1011
1011
|
await fetch(presignedURL, { method: 'PUT', body: fileContent });
|
|
1012
1012
|
} else {
|
|
@@ -1104,12 +1104,19 @@ async function downloadTemplatesFromS3(targetDir) {
|
|
|
1104
1104
|
// Wait for all downloads to complete
|
|
1105
1105
|
await Promise.all(downloadPromises);
|
|
1106
1106
|
|
|
1107
|
-
// Add .openkbs/* to .gitignore
|
|
1107
|
+
// Add .openkbs/* and .claude to .gitignore
|
|
1108
1108
|
const gitignorePath = path.join(targetDir, '.gitignore');
|
|
1109
1109
|
if (await fs.pathExists(gitignorePath)) {
|
|
1110
1110
|
let content = await fs.readFile(gitignorePath, 'utf8');
|
|
1111
|
+
let additions = '';
|
|
1111
1112
|
if (!content.includes('.openkbs/*')) {
|
|
1112
|
-
|
|
1113
|
+
additions += '.openkbs/*\n';
|
|
1114
|
+
}
|
|
1115
|
+
if (!content.includes('.claude')) {
|
|
1116
|
+
additions += '.claude\n';
|
|
1117
|
+
}
|
|
1118
|
+
if (additions) {
|
|
1119
|
+
await fs.writeFile(gitignorePath, content.trim() + '\n' + additions);
|
|
1113
1120
|
}
|
|
1114
1121
|
}
|
|
1115
1122
|
}
|
|
@@ -1,8 +1,12 @@
|
|
|
1
|
-
|
|
1
|
+
``# OpenKBS Platform Project
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
## MANDATORY FIRST STEP (DO NOT SKIP)
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
**CRITICAL: You MUST load the openkbs skill AT THE VERY START of every session, before doing anything else. No exceptions. Do not skip, defer, or ignore this step.**
|
|
6
|
+
|
|
7
|
+
**Run this first:** `/openkbs`
|
|
8
|
+
|
|
9
|
+
This step is required before any other work begins. If you skip it, your actions may fail or produce incorrect results.
|
|
6
10
|
|
|
7
11
|
## Setup Flow
|
|
8
12
|
|
package/version.json
CHANGED