Skip to content

Commit

Permalink
fixed docker build
Browse files Browse the repository at this point in the history
Replaced git-get with native git.
  • Loading branch information
tellmeY18 committed Oct 24, 2024
1 parent ce8d4aa commit c747c82
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion scripts/setup-care-apps.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,20 @@ const installApp = (app) => {
const appDir = path.join(appsDir, app.package.split("/")[1]);

console.log(`Cloning ${app.package}...`);

// Form the clone URL
const cloneUrl = `https://github.com/${app.package.replace("github:", "")}.git`;

// Use git clone instead of gitget to ensure .git folder is present
const branchOption = app.branch ? `--branch ${app.branch}` : "";

execSync(
`npx -y gitget ${app.package}${app.branch ? `#${app.branch}` : ""} apps/${app.package.split("/")[1]} `,
`git clone ${branchOption} ${cloneUrl} ${appDir}`,

Check warning

Code scanning / CodeQL

Shell command built from environment values Medium

This shell command depends on an uncontrolled
absolute path
.
{
stdio: "inherit",
},
);

// Create a care-package.lock file
fs.writeFileSync(
path.join(appDir, "care-package.lock"),
Expand Down

0 comments on commit c747c82

Please sign in to comment.