This forum has been archived. All content is frozen. Please use KDE Discuss instead.

KTorrent CLI - new :)

Tags: None
(comma "," separated)
xsawyerx
Registered Member
Posts
4
Karma
0

KTorrent CLI - new :)

Sun Mar 02, 2008 2:43 pm
Hey

I don't know how much this interests other people, and I'm sure there are FAR more important things to do, but I've rewritten the entire CLI shell script for KTorrent. The reason was that I found it a bit crude and not easy to maintain and/or use.

The rewrite is in Perl, which was done for various reasons, including:
- My personal main and favored language, though this shouldn't be a reason.
- Easier to maintain, IMHO.
- Easier to read and debug, IMHO.
- Well structured (global/local variables, functions).
- Curses support (self-updated screen).
- Easier to add advanced features (command line switches, curses, screens, tab completion).

Performance-wise, this shouldn't be favoring either side, IMO, since while Perl takes a bit more CPU time to run, it has Garbage Collection and very clear method of local variables so it doesn't clog the memory. The difference in execution shouldn't be different, since it's simple operations all in all.

I made an effort to try it keep as close as I could with the shell script (function names, variable names, flow - where possible) so it would be familiar to whoever hacked with the shell script.

I plan on continuing this since I was an easy program to use at work to monitor stuff at home and it's a chance to learn more stuff.

Does it interest anyone enough to include it with KTorrent?
George
Moderator
Posts
5421
Karma
1

Sun Mar 02, 2008 4:56 pm
I will give it a try, to see if we can include it.
Segmented
Registered Member
Posts
27
Karma
0

Re: KTorrent CLI - new :)

Sun Mar 02, 2008 7:29 pm
I don't know how much this interests other people, and I'm sure there are FAR more important things to do, but I've rewritten the entire CLI shell script for KTorrent.

Sorry for probably asking the obvious, but did you actually provide an URL to download your script? If so where? If not, how are we supposed to check out your script?

Thanks,
Segmented


Bookmarks



Who is online

Registered users: Bing [Bot], Google [Bot], Yahoo [Bot]