2009年2月17日 星期二

Create Torrent with Multiple Trackers on Linux

RubyTorrent is the best torrent creator, works in both CLI and GUI. download it from http://benclarke.ca/rubytorrent/

1. extract

tar xzf rubytorrent-0.071.tar.gz

2. as it written entirely in the ruby programming language, you have to install ruby and libgtk2-ruby ( for GTK+ interface )

sudo apt-get install ruby libgtk2-ruby

3. command-line program is torrent.rb, the usage is

./torrent.rb -a tracker1 -a tracker2,tracker3 -f FILE -o TORRENT

# try tracker1 then try either tracker2 or tracker3 in random order
# you can specify only one parameter after -f so you will need create a directory for all files and sub-directories you need

2009年2月3日 星期二

Quick command-line Numeral Conversion within Shell

(hex)15A -> (dec)346

echo 'ibase=16;obase=A;15A' | bc

ibase = input base
obase = output base
the default notation for both is decimal
if you want to specify decimal for obase, you should use obase=A ( A in hex = 10 in decimal )
input number must be in upper case