-
Notifications
You must be signed in to change notification settings - Fork 2.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: scp files #4041
fix: scp files #4041
Conversation
🤖 Generated by lychee actionSummary
Full action output |
Codecov ReportAll modified lines are covered by tests ✅ 📢 Thoughts on this report? Let us know!. |
pkg/ssh/scp.go
Outdated
if err != nil { | ||
return fmt.Errorf("failed to create: %v", err) | ||
destTmp := dest + ".tmp" | ||
copyToTmp := func(tmpName string) error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if err = func() error {
......
}(); err!=nil {
}
using anonymous function is just fine.
/cherry-pick release-v4.4 |
🤖 says: cherry pick action finished successfully 🎉! |
* fix: scp files * fix: scp files * fix: scp files * fix: scp files
* fix: scp files * fix: scp files * fix: scp files * fix: scp files Co-authored-by: 榴莲榴莲 <[email protected]>
* fix: scp files * fix: scp files * fix: scp files * fix: scp files Co-authored-by: 榴莲榴莲 <[email protected]>
return fmt.Errorf("failed to Chmod dst: %v", err) | ||
destTmp := dest + ".tmp" | ||
if err = func(tmpName string) error { | ||
dstfp, err := client.Create(tmpName) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tmpName文件 已经存在了的话呢?
* fix: scp files * fix: scp files * fix: scp files * fix: scp files Co-authored-by: 榴莲榴莲 <[email protected]>
* fix: scp files * fix: scp files * fix: scp files * fix: scp files
fix scp files