Skip to content

Commit

Permalink
fix(util): Call ToSlash for Windows filename (#111)
Browse files Browse the repository at this point in the history
#### Description (required)

Turns all the `src\app\filename` to `src/app/filename`.

#### Related issues & labels (optional)

- Closes ZEA-4045
- Suggested label: `bug`
  • Loading branch information
Yuanlin Lin authored Sep 10, 2024
2 parents 63a211c + 6bd50cb commit 604b21a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions internal/util/pack.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,9 @@ func PackZipWithoutGitIgnoreFiles() ([]byte, error) {
return err
}

// For Windows, we should replace the backslashes with forward slashes
header.Name = filepath.ToSlash(header.Name)

if info.IsDir() {
header.Name += string(filepath.Separator)
} else {
Expand Down

0 comments on commit 604b21a

Please sign in to comment.