diff --git a/MyMusicBoxApi/service/playlist.go b/MyMusicBoxApi/service/playlist.go index a2ff3c7..d351407 100644 --- a/MyMusicBoxApi/service/playlist.go +++ b/MyMusicBoxApi/service/playlist.go @@ -114,7 +114,7 @@ func downloadPlaylist( for id := range downloadCount { name := names[id] - if canDownload(name) { + if canDownload(name) && !existInArchive(archiveFileName, ids[id]) { childTask, _ := tasklogTable.CreateChildTaskLog(parentTask) diff --git a/MyMusicBoxApi/update b/MyMusicBoxApi/update index bcb93c4..0a74b36 100755 --- a/MyMusicBoxApi/update +++ b/MyMusicBoxApi/update @@ -38,9 +38,9 @@ cp selenium/* "$COOKIES_FOLDER" echo "=== Updating executable ===" go build -trimpath -buildvcs=false -ldflags="-s -w" -o "$RELEASE_FOLDER" -# echo "=== Reducing executable size ===" -# cd "$RELEASE_FOLDER" -# upx --best --lzma musicboxapi +echo "=== Reducing executable size ===" +cd "$RELEASE_FOLDER" +upx --best --lzma musicboxapi echo "=== Restarting mymusic service ===" sudo systemctl stop mymusic || echo "Service 'mymusic' was not running."