aiblueprint-cli 1.4.18 → 1.4.19

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.
Files changed (2) hide show
  1. package/dist/cli.js +6 -6
  2. package/package.json +1 -1
package/dist/cli.js CHANGED
@@ -34858,9 +34858,9 @@ var PREMIUM_BRANCH = "main";
34858
34858
  function getCacheRepoDir() {
34859
34859
  return path11.join(os10.homedir(), ".config", "aiblueprint", "pro-repos", "aiblueprint-cli-premium");
34860
34860
  }
34861
- async function execGitWithAuth(command, token, cwd) {
34862
- const authConfig = `http.https://github.com/.extraheader=AUTHORIZATION: token ${token}`;
34863
- const fullCommand = `git -c "${authConfig}" ${command}`;
34861
+ async function execGitWithAuth(command, token, repoUrl, cwd) {
34862
+ const authenticatedUrl = `https://x-access-token:${token}@${repoUrl.replace(/^https?:\/\//, "")}`;
34863
+ const fullCommand = `git ${command.replace(repoUrl, authenticatedUrl)}`;
34864
34864
  try {
34865
34865
  await execAsync(fullCommand, { cwd, timeout: 120000 });
34866
34866
  } catch (error) {
@@ -34872,15 +34872,15 @@ async function cloneOrUpdateRepo(token) {
34872
34872
  const repoUrl = `https://github.com/${PREMIUM_REPO}.git`;
34873
34873
  if (await import_fs_extra9.default.pathExists(path11.join(cacheDir, ".git"))) {
34874
34874
  try {
34875
- await execGitWithAuth("pull", token, cacheDir);
34875
+ await execGitWithAuth("pull", token, repoUrl, cacheDir);
34876
34876
  } catch (error) {
34877
34877
  await import_fs_extra9.default.remove(cacheDir);
34878
34878
  await import_fs_extra9.default.ensureDir(path11.dirname(cacheDir));
34879
- await execGitWithAuth(`clone ${repoUrl} ${cacheDir}`, token);
34879
+ await execGitWithAuth(`clone ${repoUrl} ${cacheDir}`, token, repoUrl);
34880
34880
  }
34881
34881
  } else {
34882
34882
  await import_fs_extra9.default.ensureDir(path11.dirname(cacheDir));
34883
- await execGitWithAuth(`clone ${repoUrl} ${cacheDir}`, token);
34883
+ await execGitWithAuth(`clone ${repoUrl} ${cacheDir}`, token, repoUrl);
34884
34884
  }
34885
34885
  return path11.join(cacheDir, "claude-code-config");
34886
34886
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "aiblueprint-cli",
3
- "version": "1.4.18",
3
+ "version": "1.4.19",
4
4
  "description": "AIBlueprint CLI for setting up Claude Code configurations",
5
5
  "author": "AIBlueprint",
6
6
  "license": "MIT",