File tree Expand file tree Collapse file tree 3 files changed +12
-6
lines changed Expand file tree Collapse file tree 3 files changed +12
-6
lines changed Original file line number Diff line number Diff line change
1
+ ---
2
+ " algohub " : patch:fix
3
+ ---
4
+
5
+ Fix git ssh key read and write permission issue when publishing to AUR.
Original file line number Diff line number Diff line change @@ -28,3 +28,6 @@ components.d.ts
28
28
29
29
# Tailwind CSS
30
30
tailwind.css
31
+
32
+ # Autogenerated files
33
+ .aur_ssh_key
Original file line number Diff line number Diff line change @@ -68,20 +68,18 @@ const releaseAur = defineCommand({
68
68
return ;
69
69
}
70
70
71
- writeFileSync ( `${ process . env . HOME } /.ssh/aur` , AUR_SSH_KEY + "\n" ) ;
72
- execSync ( "chmod 600 ~/.ssh/aur" ) ;
73
- execSync ( `git -C aur config core.sshCommand "ssh -i ~/.ssh/aur"` ) ;
74
-
71
+ writeFileSync ( `.aur_ssh_key` , AUR_SSH_KEY + "\n" ) ;
72
+ execSync ( `chmod 400 .aur_ssh_key` )
75
73
if ( ! existsSync ( "aur" ) ) {
76
74
execSync (
77
- `git -c init.defaultBranch=master -c core.sshCommand="ssh -i ~/.ssh/aur " clone ssh://aur@aur.archlinux.org/algohub.git aur`
75
+ `git -c init.defaultBranch=master -c core.sshCommand="ssh -i ../.aur_ssh_key " clone ssh://aur@aur.archlinux.org/algohub.git aur`
78
76
) ;
79
77
}
78
+ execSync ( `git -C aur config core.sshCommand "ssh -i ../.aur_ssh_key"` ) ;
80
79
81
80
const { version } = ctx . args ;
82
81
83
82
const url = `https://github.com/swpu-acm/algohub/releases/download/algohub-v${ version } /algohub_${ version } _amd64.deb` ;
84
- // const url = `https://github.com/swpu-acm/algohub/releases/download/algohub-v${version}/algohub_0.1.0_amd64.deb`;
85
83
try {
86
84
console . log ( `Downloading ${ url } ...` ) ;
87
85
const response = await axios . get ( url , {
You can’t perform that action at this time.
0 commit comments