Skip to content

Commit

Permalink
embed: turn source path to absolute for error-less copy
Browse files Browse the repository at this point in the history
Signed-off-by: Mohammed Al Sahaf <[email protected]>
  • Loading branch information
mohammed90 committed Aug 27, 2024
1 parent 7888727 commit 6cbbb5c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions io.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ import (

// copy recursively copies src into dst with src's file modes.
func copy(src, dst string) error {
if !filepath.IsAbs(src) {
src, _ = filepath.Abs(src)
}
src = filepath.ToSlash(src)
dst = filepath.ToSlash(dst)
log.Printf("[INFO] copying files: src=%s dest=%s", src, dst)
Expand Down

0 comments on commit 6cbbb5c

Please sign in to comment.