
amarokNowPlayingImproved
Source (link to git-repo or to original if based on someone elses unmodified work): Add the source-code for this project on opencode.net
This is a re-write of amarokNowPlaying by Daniel Dormann. It generates an image of the currently playing media using ImageMagick's convert and then uploads it to a remote host. The image includes the album cover, artist, album name, and track title. It also shows if the engine is paused, and creates a cusomizable "offline" message when the engine is stopped.
The script uses cURL in order to upload the image to a remote host, and supports both FTP and HTTP POST methods, as well as a local filesystem option.
Requirements: cURL, ImageMagick
Please view the README file in the archive for more information.
To those that rate my script, please leave feedback as to why you like/dislike it. That's the only way I can know where to improve!
15 years ago
0.1 - Initial release
0.1b - Bugfix: Script no longer makes calls to dcop unless amarok signals a state change. This fixes a condition of the script consuming resources.
15 years ago
0.1 - Initial release
0.1b - Bugfix: Script no longer makes calls to dcop unless amarok signals a state change. This fixes a condition of the script consuming resources.
TommyHLW
13 years ago
Report
stifi
14 years ago
What about adding scp support to the script. i.e.
elif [ ${method} = scp ];then
scp -i ${keyfile} /tmp/amarokNowPlaying_image.png "${user}@${host}:${path}"
Report
rokkford
15 years ago
is there a chance to add an extra info to the pic, i.e. bitrate in a 4th row?
Report
placidpsychosis
15 years ago
Report
rokkford
15 years ago
Report
placidpsychosis
15 years ago
There are a few variables to update in the configuration. You'll need to set http_image_var to the variable the script is using for the upload. If you so choose, you can configure your script to require a password, in which case http_secure_var and http_secure_value need to be set. Again, the included example shows the usage of these variables.
Other than that, it should be good to go. I use the HTTP method myself, as I find it faster than FTP and I get a little more control on the server side.
Report
rokkford
15 years ago
really nice script! i've build my own, but this is much more complex with the info and the cover!
Report
placidpsychosis
15 years ago
If your script looks for the image to be posted to NAME_OF_YOUR_VARIABLE, like this:
then http_image_var needs to be set to NAME_OF_YOUR_VARIABLE
Your script will need to be written to move the uploaded file to where you want it and name it properly.
The "You are not authorized" message from the example script is caused by your http_secure_var and your http_secure_value not being set correctly. I beleive the example requires:
http_secure_var=secure_key
http_secure_value=amarok
It's basicly an optional security mechanism to prevent people from just being able to upload random images to your Web server.
The example script will create the file now_playing.png in the directory the script resides, so if you put the example script here:
http://yoursite.com/amarok_upload.php
then your image would then become:
http://yoursite.com/now_playing.png
The example script is not meant to be viewed in a browser.
Report
rokkford
15 years ago
i use your example script and all that i've changed is the http_url via the config.
although it's all set up, like it should be, it doesn't work.
and shouldn't have the config have effect on the /.kde/share/apps/amarok/scripts/amarokNowPlayingImproved/amarokNowPlayingImproved.sh as well?
what am i missing?
Report
placidpsychosis
15 years ago
I apologize for the trouble, but I thank you for helping me improve on this script!
Report
rokkford
15 years ago
Report
markey
15 years ago
Report
placidpsychosis
15 years ago
Report