feat: update video cut and extract head image job
This commit is contained in:
@@ -31,3 +31,12 @@ func GetFileMd5(file string) (string, error) {
|
||||
|
||||
return fmt.Sprintf("%x", h.Sum(nil)), nil
|
||||
}
|
||||
|
||||
// GetFileSize
|
||||
func GetFileSize(file string) (int64, error) {
|
||||
fi, err := os.Stat(file)
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
return fi.Size(), nil
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user