@ghyper9023/u2secure 0.3.1 → 0.4.0
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/bin/install.js +6 -1
- package/package.json +1 -1
package/bin/install.js
CHANGED
|
@@ -17,7 +17,12 @@ if (!match) {
|
|
|
17
17
|
console.error(`Failed to parse owner/repo from repository.url: ${repoUrl}`);
|
|
18
18
|
process.exit(1);
|
|
19
19
|
}
|
|
20
|
-
|
|
20
|
+
// 修复:去除可能的 .git 后缀
|
|
21
|
+
let repo = match[1];
|
|
22
|
+
if (repo.endsWith('.git')) {
|
|
23
|
+
repo = repo.slice(0, -4);
|
|
24
|
+
}
|
|
25
|
+
|
|
21
26
|
const tag = `v${version}`;
|
|
22
27
|
|
|
23
28
|
function getPlatformAsset() {
|