Linux and downloading music from Vkontakte — bring to mind a script?

0 like 0 dislike
16 views
First the story, which is quite a pull on miniature topic.


So your music collection is Vkontakte, and you wanted her to pull to hard as I wanted. The bulk of the offer on the Internet solutions — all sorts of left utility under Win, which need to feed data to your account (yep, someone to give them on a silver platter). These utility to each song add the button "download", offering (again) a stupid manual labor.


On the web was found to have the following script:

#!/bin/bashgets=`curl -s --data "email=yourmailhere@some.mail&pass=yourpassword" http://login.vk.com/?act=login | egrep -o \\([a-z]\\|[0-9]\\){20\\,}`curl-v --cookie-jar /tmp/vkcookie --data "s=$gets&op=slogin&redirect=1&expire=0&to=0" http://vkontakte.ru/login.phpcurl-v --cookie /tmp/vkcookie vkontakte.ru/audio.php | grep -o 'http.*mp3' | wget-i -* This source code was highlighted with Source Code Highlighter.



This script is just 3 lines pull the music from the page "audio" user. Instead of lines
vkontakte.ru/audio.php
you can enter any wcontactos link, for example, on the page "recordings" of any group (I checked, it works).

And now a question, or rather request to knowing people — help to bring the script to mind.

The fact that the music he keeps in files with names fd8787fdsf98.mp3 (with tags!), and if at some point communication was lost, or hung wget, or you accidentally closed the terminal will either have to deal with sorting out the "stolen" for the purpose of removing from the records Vkontakte songs that have already been downloaded, or to download all over again. Neustra and shakes it — I'm not special in the settings wget', but even the Manager downloads Opera gives usedonmost speed.


That is, you need to add a check whether the file already downloaded.


Among other things, I'm not entirely sure the script goes where-beyond the first page with a list of music to check this fact were not taken, for too long, it shakes even the first page.


It would be nice to have any interface using zenity or gxmessage — to drive account information in the window, and not to include in the body of the script, since the latter is unsafe (I nearly published a script with my username and password, if that). Well, the source selection page of the user audio recordings, or records of any group (enough to pass the script only the GID to form a link), or enter the entire address manually (for example, a link on someone's wall where you want to get laid music). In the process of grabbing, you can issue a completion of downloading of the music via notify-send, or use the progress bar to zenity.


Maybe this problem someone from the Linux guru interested?


PS the original script is not my work, authorship is difficult to specify found on the web here and is obviously a collective work.
asked by | 16 views

7 Answers

0 like 0 dislike
A graphical interface according to the problem you can't use it?
If you can, there is another option Exaile+script for Vkontakte. This is certainly not the path of the guru, but with a small number of tracks works well. With great I have not tried it, but, on idea, too should be fine. Track names are normally written. Plus, you can choose what to download and what not to download.
answered by
0 like 0 dislike
I have a working solution in php+mysql, and not brought to the state of the site service. Happy to share if relevant. There authorization and proper naming of files.
answered by
0 like 0 dislike
I would have done: launched DragonFly in Opera, and ponazhimat on the button would play all the compositions, then the resulting links are poparitsya in a rocking chair Opera. Yes, manual labor, but simple and clear.
answered by
0 like 0 dislike
Guys, it's all the same crutches. The points
solution with exaile at first glance cute, but it's not unix-way, the same exaile I don't have (and really do not want to put on my minimalist arcic) well, a few complaints, starting with the fact that the task is pulling music from a specific page specified. That is, you came to the group, pressed the "audio" — there their pieces 20. Highlighted link or only the group id from it, ran the script, got a gtk-esque box (zenity or gxmessage provides this functionality for *sh-scripts). You drive to your login, password and inserted into the third field of the link, and it pulls out all the tracks.
\r
— php+mysql is also not unix-way, more like driving nails with a microscope in my case. That is, at the moment, but instead almost cope the bash-script in 3 lines. Is it reasonable to compare it with the setup and configuration of the ligament Apache+PHP+MySQL?
\r
About the dragonfly is similar. If I have a large collection of records, you have to sit like a crab in the galleys.
answered by
0 like 0 dislike
In order not swayed the files for a second time, enough to pass wget the-c switch.
\r
Can help with data entry. As I understand it, you need to ask the user:
— email
password
— type of the page
— id
Right?
\r
Give examples of links corresponding to different election of the user. And then I contact not sitting, I'm too lazy to look up where any links.
answered by
0 like 0 dislike
> and if at some point communication was lost, or hung wget, or you accidentally closed the terminal
\r
wget-c
answered by
0 like 0 dislike
how about mielophone.com/?
\r
1) available under Linux for Adobe AIR
2) in the settings you can choose as a source — api.vk.com that does not require any logins and passwords
3) allows you to download the entire library in 2 clicks of a button, while retaining the original names of the songs
4) very easy to use and has many additional features
answered by

Related questions

0 like 0 dislike
7 answers
0 like 0 dislike
5 answers
asked Sep 28, 2018 by beduin01
0 like 0 dislike
1 answer
0 like 0 dislike
1 answer
asked Oct 25, 2018 by MadDeee
24,509 questions
45,932 answers
0 comments
352 users