can I populate the download_history without actualy downloading
Dave Widgery
dave.widgery at gmail.com
Wed Sep 7 05:27:09 PDT 2016
Cheers Jimmy,
That is exactly what I needed, tried it and it has done the trick, I
currently use a batch file containing the following line.
for /F "tokens=*" %%A in (tvprog.txt) do get_iplayer --get %%A
--tvmode=flashbetter --output=c:\iplayer\tv\
--file-prefix="<name>-<episode>"
and a text file "tvprog,txt" that I just add keywords like eggheads or
"university challenge" or even --pid=XXXXXXXX if I need to.
(I have a similar setup for radio programs)
This gets run each night as a windows scheduled task, there are lots
of programs in my tvprog.txt file that are not current at the moment,
but it picks them up automaticaly if there is a new series or
somthing. I am sure that I have reinvedted the wheel, but it works for
me.
So I just ran my batch file with your modification and it has
populated the history file with anything that is current and in my
tvprog list.
Again thanks to anyone who had a think about my problem.
Dave
On 7 September 2016 at 10:13, Jimmy Aitken <jimmy.aitken at gmail.com> wrote:
> On Tue, Sep 6, 2016 at 7:45 PM, Dave Widgery <dave.widgery at gmail.com> wrote:
>>
>> Hi thanks for the suggestion, but I am running windows not linux, i
>> will give it a try but not sure that it will work.
>>
>> Dave
>>
>> On 6 September 2016 at 17:10, David Walters <david at jellybaby.net> wrote:
>> > On Tue, Sep 6, 2016 at 3:45 PM, Dave Widgery <dave.widgery at gmail.com> wrote:
>> >>
>> >> get_iplayer creates the entries in the file each time it has a
>> >> sucsessful downloads a file,
>> >
>
> A quick (in code change, not in execution) and dirty way to do this
> would be to add the following line to the function
> mode_ver_download_retry_loop
> at around 4377 of get_iplayer version 2.95. Add the following line
> after the one "my $retcode;"
>
> $hist->add($prog);return;
>
> This will never download any program, but will update your history
> file instead. Now call get_iplayer with whatever programmes you want
> to have added to your history file and it will be updated.
> e.g. get_iplayer -g .
> will add everything that is current to the history file.
> get_iplayer -g egg
> will only add programmes that match 'egg' to the history file
>
> It will take a long time, and the code to add to the history file is
> not optimised to do this sort of write since it rewrites the complete
> history file for each file it finds, and there are doubtless many
> other ways to do this.
>
> Howerver, this does has the advantage of just being a one line change
> to the current code, though so it's easy to put in place and revert
> afterwards.
>
> Remember to remove the line after you've finished through....
>
> J.
More information about the get_iplayer
mailing list