@tangible/roller
Advanced tools
@@ -86,3 +86,4 @@ /** | ||
| console.log('Files to archive:', files) | ||
| console.log('Files to archive:') | ||
| console.log(files.join('\n')) | ||
@@ -89,0 +90,0 @@ console.log('Archive file:', dest) |
+22
-12
@@ -54,2 +54,20 @@ import path from 'path' | ||
| // Fallback to HTTPS instead of Git/SSH protocol | ||
| const fallbackGit = git.replace('git@github.com:', 'https://github.com/') | ||
| async function runWithFallback(command) { | ||
| const options = { | ||
| cwd: targetPath, | ||
| } | ||
| try { | ||
| console.log(command) | ||
| await run(command, options) | ||
| } catch (e) { | ||
| console.log('Git did\'t work with SSH protocol. Trying fallback with HTTPS.') | ||
| const fallbackCommand = command.replace(git, fallbackGit) | ||
| console.log(fallbackCommand) | ||
| await run(fallbackCommand, options) | ||
| } | ||
| } | ||
| if (await fileExists(targetPath)) { | ||
@@ -62,15 +80,7 @@ if (!shouldUpdate) { | ||
| const command = `git pull --ff-only ${git} ${branch}` | ||
| console.log(command) | ||
| await run(command, { | ||
| cwd: targetPath, | ||
| }) | ||
| await runWithFallback(`git pull --ff-only ${git} ${branch}`) | ||
| } else { | ||
| const command = `git clone --recursive --depth 1 --single-branch --branch ${branch} ${git} ${folderName || slug}` | ||
| console.log(command) | ||
| await run(command, { | ||
| cwd: parentPath, | ||
| }) | ||
| await runWithFallback( | ||
| `git clone --recursive --depth 1 --single-branch --branch ${branch} ${git} ${folderName || slug}`, | ||
| ) | ||
| } | ||
@@ -77,0 +87,0 @@ |
+1
-1
| { | ||
| "name": "@tangible/roller", | ||
| "type": "module", | ||
| "version": "2.1.1", | ||
| "version": "2.1.2", | ||
| "description": "Build project assets using Rollup and ESBuild", | ||
@@ -6,0 +6,0 @@ "homepage": "https://github.com/tangibleinc/tangible-roller", |
Network access
Supply chain riskThis module accesses the network.
Found 3 instances in 1 package
Shell access
Supply chain riskThis module accesses the system shell. Accessing the system shell increases the risk of executing arbitrary code.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 3 instances in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 3 instances in 1 package
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
Found 1 instance in 1 package
Network access
Supply chain riskThis module accesses the network.
Found 3 instances in 1 package
Shell access
Supply chain riskThis module accesses the system shell. Accessing the system shell increases the risk of executing arbitrary code.
Found 1 instance in 1 package
Dynamic require
Supply chain riskDynamic require can indicate the package is performing dangerous or unsafe dynamic code execution.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 3 instances in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 3 instances in 1 package
Long strings
Supply chain riskContains long string literals, which may be a sign of obfuscated or packed code.
Found 1 instance in 1 package
URL strings
Supply chain riskPackage contains fragments of external URLs or IP addresses, which the package may be accessing at runtime.
Found 1 instance in 1 package
210946
0.23%5991
0.18%