[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Mldonkey-users] Renaming downloads - please check (my ocaml is bad)
From: |
mld_thomas |
Subject: |
[Mldonkey-users] Renaming downloads - please check (my ocaml is bad) |
Date: |
Mon, 17 Mar 2003 22:18:18 +0100 |
Hi,
my ocaml isn't quite good, so please look at this patch - is it ok?
But don't hit me, if not... ;-)
-- snip --
--- donkey/donkeyInteractive.ml 2003-03-13 21:25:01 +0100
+++ donkey/donkeyInteractive.ml 2003-03-17 22:09:50 +0100
@@ -494,6 +494,15 @@
), ":\t\t\t\t\tview upload credits";
+ "ren", Arg_two (fun arg new_name o ->
+ let num = int_of_string arg in
+ try
+ let file = file_find num in
+ set_file_best_name file new_name;
+ Printf.sprintf "Download %i renamed to %s" num new_name;
+ with _ -> failwith (Printf.sprintf "No file number %i" num);
+ ""
+ ), "<num> <new name> :\t\t\tchange name of download <num> to <new name>";
"comments", Arg_one (fun filename o ->
let buf = o.conn_buf in
-- snip --
Greets
Thomas
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Mldonkey-users] Renaming downloads - please check (my ocaml is bad),
mld_thomas <=