Terminal – ls-like command for http directories?

Johnny Rosenberg gurus.knugum at gmail.com
Sat May 25 12:20:57 UTC 2013


Is this possible?

Okay, an example:
I have a script that downloads and installs unetbootin to my system. I
run the script like this:

./Install.sh 583

This downloads and ”installs” Unetbootin 5.83, which means it uses
wget to download the file, then moves the file to a proper place and
finally adds a link to it in ~/bin so I can run it by only typing:
unetbootin

Now, for this to work, I first need to find out what is the latest
version, for instance by looking it up in my web browser. Then I can
run my install script.

Of course it would be more convenient if the script could find the
latest version for me.

The latest version (today, 2013-05-25) is:
http://tenet.dl.sourceforge.net/project/unetbootin/UNetbootin/583/unetbootin-linux-583

So what I need is a command like:
some_ls-like_command
"http://tenet.dl.sourceforge.net/project/unetbootin/UNetbootin/"
Then I guess I would have a loop that determines the highest value
somehow, but I guess I will figure that part out.

That directory currently looks like this:
180/	-	21-Jul-2009 00:18
189/	-	17-Jul-2009 23:46
191/	-	17-Jul-2009 23:46
201/	-	17-Jul-2009 23:46
214/	-	29-Aug-2012 00:37
215/	-	06-Sep-2012 00:38
216/	-	27-Aug-2012 00:37
225/	-	17-Jul-2009 23:46
229/	-	17-Jul-2009 23:46
235/	-	17-Jul-2009 23:46
241/	-	17-Jul-2009 23:46
243/	-	17-Jul-2009 23:46
248/	-	27-Nov-2012 01:18
262/	-	10-Jul-2012 05:27
265/	-	17-Jul-2009 23:46
272/	-	11-Jul-2012 03:42
274/	-	17-Jul-2009 23:46
275/	-	12-Jul-2012 00:43
281/	-	17-Jul-2009 23:46
282/	-	13-Nov-2012 07:35
299/	-	03-Oct-2012 00:35
304/	-	22-Nov-2012 00:43
306/	-	08-Nov-2012 00:39
307/	-	12-Aug-2012 00:37
310/	-	17-Jul-2009 23:46
312/	-	15-Aug-2012 00:41
319/	-	18-Aug-2012 01:04
323/	-	01-Nov-2012 00:21
344/	-	01-Sep-2012 00:37
356/	-	17-Jul-2009 23:46
372/	-	20-Sep-2009 21:22
377/	-	28-Oct-2009 23:21
391/	-	01-Feb-2010 06:07
393/	-	15-Oct-2012 02:13
408/	-	13-Feb-2010 22:20
419/	-	11-Oct-2012 00:40
424/	-	27-Mar-2010 21:10
429/	-	27-Jan-2013 03:04
433/	-	19-Oct-2012 00:35
436/	-	22-Oct-2012 00:30
442/	-	23-Oct-2012 00:29
466/	-	03-Jun-2010 07:11
471/	-	31-Oct-2012 00:22
485/	-	03-Nov-2012 00:25
490/	-	01-Dec-2012 00:25
491/	-	02-Dec-2012 00:56
494/	-	11-Oct-2010 01:04
502/	-	22-Dec-2012 06:28
506/	-	14-Jan-2013 02:11
527/	-	27-Mar-2011 03:29
549/	-	15-Jan-2013 00:23
555/	-	17-Mar-2013 00:48
563/	-	27-Apr-2013 00:18
568/	-	21-May-2013 00:26
575/	-	28-Apr-2012 08:02
577/	-	13-Jul-2012 04:06
578/	-	15-Jul-2012 02:25
581/	-	27-Aug-2012 07:07
583/	-	24-Dec-2012 08:45
Custom/


Johnny Rosenberg




More information about the ubuntu-users mailing list