Skip to content

Commit

Permalink
remove spotify user and password
Browse files Browse the repository at this point in the history
  • Loading branch information
s-martin committed Dec 20, 2024
1 parent d8ab338 commit 1847f56
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 14 deletions.
2 changes: 0 additions & 2 deletions misc/sampleconfigs/mopidy.conf.sample
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@ locale = de_DE

[spotify]
enabled = true
username = %spotify_username%
password = %spotify_password%
client_id = %spotify_client_id%
client_secret = %spotify_client_secret%
#bitrate = 160
Expand Down
8 changes: 0 additions & 8 deletions scripts/installscripts/install-jukebox.sh
Original file line number Diff line number Diff line change
Expand Up @@ -618,8 +618,6 @@ config_spotify() {
# Please note your client_id and client_secret!
#
"
read -rp "Type your Spotify username: " SPOTIuser
read -rp "Type your Spotify password: " SPOTIpass
read -rp "Type your client_id: " SPOTIclientid
read -rp "Type your client_secret: " SPOTIclientsecret
;;
Expand All @@ -631,8 +629,6 @@ config_spotify() {
# append variables to config file
{
echo "SPOTinstall=\"$(_escape_for_shell "$SPOTinstall")\"";
echo "SPOTIuser=\"$(_escape_for_shell "$SPOTIuser")\"";
echo "SPOTIpass=\"$(_escape_for_shell "$SPOTIpass")\"";
echo "SPOTIclientid=\"$(_escape_for_shell "$SPOTIclientid")\"";
echo "SPOTIclientsecret=\"$(_escape_for_shell "$SPOTIclientsecret")\""
} >> "${HOME_DIR}/PhonieboxInstall.conf"
Expand Down Expand Up @@ -756,8 +752,6 @@ check_config_file() {
echo "ERROR: \$SPOTinstall is missing or not set!" && fail=true
else
if [ "$SPOTinstall" == "YES" ]; then
check_variable "SPOTIuser"
check_variable "SPOTIpass"
check_variable "SPOTIclientid"
check_variable "SPOTIclientsecret"
fi
Expand Down Expand Up @@ -1096,8 +1090,6 @@ install_main() {
sudo locale-gen
sudo cp "${jukebox_dir}"/misc/sampleconfigs/mopidy.conf.sample "${mopidy_conf}"
# Change vars to match install config
sudo sed -i 's|%spotify_username%|'"$(escape_for_sed "$SPOTIuser")"'|' "${mopidy_conf}"
sudo sed -i 's|%spotify_password%|'"$(escape_for_sed "$SPOTIpass")"'|' "${mopidy_conf}"
sudo sed -i 's|%spotify_client_id%|'"$(escape_for_sed "$SPOTIclientid")"'|' "${mopidy_conf}"
sudo sed -i 's|%spotify_client_secret%|'"$(escape_for_sed "$SPOTIclientsecret")"'|' "${mopidy_conf}"
# for $DIRaudioFolders using | as alternate regex delimiter because of the folder path slash
Expand Down
4 changes: 0 additions & 4 deletions scripts/installscripts/tests/test_installation.sh
Original file line number Diff line number Diff line change
Expand Up @@ -170,8 +170,6 @@ verify_conf_file() {
else
echo "\$SPOTinstall is set to '$SPOTinstall'"
if [ "$SPOTinstall" == "YES" ]; then
check_variable "SPOTIuser"
check_variable "SPOTIpass"
check_variable "SPOTIclientid"
check_variable "SPOTIclientsecret"
fi
Expand Down Expand Up @@ -459,8 +457,6 @@ verify_spotify_config() {

printf "\nTESTING spotify config...\n\n"

check_file_contains_string "username = ${SPOTIuser}" "${mopidy_conf}"
check_file_contains_string "password = ${SPOTIpass}" "${mopidy_conf}"
check_file_contains_string "client_id = ${SPOTIclientid}" "${mopidy_conf}"
check_file_contains_string "client_secret = ${SPOTIclientsecret}" "${mopidy_conf}"
check_file_contains_string "media_dir = ${DIRaudioFolders}" "${mopidy_conf}"
Expand Down

0 comments on commit 1847f56

Please sign in to comment.