Skip to content

Commit b0a055b

Browse files
committed
Format go code.
1 parent 2a0de65 commit b0a055b

File tree

3 files changed

+10
-10
lines changed

3 files changed

+10
-10
lines changed

main.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -469,7 +469,7 @@ func main() {
469469
}
470470

471471
baseFilename = stringHash(baseFilename)
472-
listFilePath := filepath.Join(tempFolder(), baseFilename + ".files.txt")
472+
listFilePath := filepath.Join(tempFolder(), baseFilename+".files.txt")
473473

474474
listFileContent = header + newline() + newline() + listFileContent
475475
ioutil.WriteFile(listFilePath, []byte(listFileContent), PROFILE_PERM)
@@ -541,7 +541,7 @@ func main() {
541541
dupPaths := duplicatePaths(newFilePaths)
542542
if len(dupPaths) > 0 {
543543
criticalError(errors.New(fmt.Sprint("There are duplicate filenames in the list. To avoid any data loss, the operation has been aborted. You may resume it by running the same command. The duplicate filenames are: ", dupPaths)))
544-
}
544+
}
545545

546546
// -----------------------------------------------------------------------------------
547547
// Rename the files

main_test.go

+7-7
Original file line numberDiff line numberDiff line change
@@ -214,12 +214,12 @@ func Test_filePathsFromListFile(t *testing.T) {
214214

215215
func Test_stripBom(t *testing.T) {
216216
data := [][][]byte{
217-
[][]byte{[]byte{239, 187, 191}, []byte{}},
218-
[][]byte{[]byte{239, 187, 191, 239, 187, 191}, []byte{239, 187, 191}},
219-
[][]byte{[]byte{239, 187, 191, 65, 66}, []byte{65, 66}},
220-
[][]byte{[]byte{239, 191, 65, 66}, []byte{239, 191, 65, 66}},
221-
[][]byte{[]byte{}, []byte{}},
222-
[][]byte{[]byte{65, 239, 187, 191}, []byte{65, 239, 187, 191}},
217+
{{239, 187, 191}, {}},
218+
{{239, 187, 191, 239, 187, 191}, {239, 187, 191}},
219+
{{239, 187, 191, 65, 66}, {65, 66}},
220+
{{239, 191, 65, 66}, {239, 191, 65, 66}},
221+
{{}, {}},
222+
{{65, 239, 187, 191}, {65, 239, 187, 191}},
223223
}
224224

225225
for _, d := range data {
@@ -309,4 +309,4 @@ func Test_duplicatePaths(t *testing.T) {
309309
if len(duplicatePaths([]string{})) != 0 {
310310
t.Error("Wrong duplicate count")
311311
}
312-
}
312+
}

version_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,4 @@ func Test_handleVersionCommand(t *testing.T) {
1010
if err != nil {
1111
t.Fail()
1212
}
13-
}
13+
}

0 commit comments

Comments
 (0)