MCPcopy
hub / github.com/ChineseSubFinder/ChineseSubFinder / CopyFiles2DebugFolder

Function CopyFiles2DebugFolder

pkg/folder.go:55–71  ·  view source on GitHub ↗

CopyFiles2DebugFolder 把文件放入到 Debug 文件夹中,新建 desFolderName 文件夹

(names []string, subFiles []string)

Source from the content-addressed store, hash-verified

53
54// CopyFiles2DebugFolder 把文件放入到 Debug 文件夹中,新建 desFolderName 文件夹
55func CopyFiles2DebugFolder(names []string, subFiles []string) error {
56 debugFolderByName, err := GetDebugFolderByName(names)
57 if err != nil {
58 return err
59 }
60
61 // 复制下载在 tmp 文件夹中的字幕文件到视频文件夹下面
62 for _, subFile := range subFiles {
63 newFn := filepath.Join(debugFolderByName, filepath.Base(subFile))
64 err = CopyFile(subFile, newFn)
65 if err != nil {
66 return err
67 }
68 }
69
70 return nil
71}
72
73// --------------------------------------------------------------
74// Tmp

Callers 1

oneVideoSelectBestSubMethod · 0.92

Calls 2

GetDebugFolderByNameFunction · 0.85
CopyFileFunction · 0.70

Tested by

no test coverage detected