Skip to content

Commit

Permalink
feat(navidrome): add source and dest ids to navidrome playlist output
Browse files Browse the repository at this point in the history
  • Loading branch information
Zibbp committed Feb 8, 2025
1 parent def0c41 commit 3dce7a2
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 6 deletions.
3 changes: 2 additions & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
"mtxr.sqltools",
"eamodio.gitlens",
"golang.go",
"mtxr.sqltools-driver-sqlite"
"mtxr.sqltools-driver-sqlite",
"github.vscode-github-actions"
]
}
}
Expand Down
6 changes: 4 additions & 2 deletions convert/spotify_tidal.go
Original file line number Diff line number Diff line change
Expand Up @@ -248,8 +248,10 @@ func (s *Service) SpotifyToTidal(saveMissingTracks bool, saveTidalPlaylist bool,
}

navidromePlaylist := navidrome.Playlist{
Name: spotifyPlaylist.Name,
Description: spotifyPlaylist.Description,
SourceId: spotifyPlaylist.ID.String(),
DestinationId: tidalPlaylist.UUID,
Name: spotifyPlaylist.Name,
Description: spotifyPlaylist.Description,
}

for _, track := range tPlaylist.Tracks {
Expand Down
8 changes: 5 additions & 3 deletions navidrome/navidrome.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,11 @@ import (
)

type Playlist struct {
Name string `json:"name"`
Description string `json:"description"`
Tracks []Track `json:"tracks"`
SourceId string `json:"source_id"`
DestinationId string `json:"destination_id"`
Name string `json:"name"`
Description string `json:"description"`
Tracks []Track `json:"tracks"`
}

type Track struct {
Expand Down

0 comments on commit 3dce7a2

Please sign in to comment.