Compare commits

...
This repository has been archived on 2024-06-01. You can view files and clone it, but cannot push or open issues or pull requests.

1 Commits

Author SHA1 Message Date
Lunny Xiao d3bedf74f5
Fix blank line will upload all files 2023-08-10 23:48:52 +08:00
1 changed files with 4 additions and 1 deletions

View File

@ -110,7 +110,10 @@ func getFiles(parentDir, files string) ([]string, error) {
lines := strings.Split(files, "\n")
for _, line := range lines {
line = strings.Trim(line, "'")
line = strings.Trim(line, `"`)
line = strings.TrimSpace(strings.Trim(line, `"`))
if line == "" {
continue
}
if filepath.IsAbs(line) {
return nil, fmt.Errorf("file path %s is absolute", line)
}