#!/usr/bin/jruby
require "java"
def help
p "cnvrt<...>"
end
if (ARGV.size > 0)
begin
charset = java.nio.charset.Charset.for_name ARGV[0]
ARGV.delete_at 0
ARGV.each {|a|
bytes = java.lang.String.new(a).getBytes
buffer = java.nio.ByteBuffer.wrap(bytes)
puts charset.decode(buffer)
}
rescue
p $!
end
else
help
end
Software Developer
Friday, June 26, 2009
Simple but very flexible and usefull terminal encoding converter
Sunday, May 10, 2009
Rapidshare terminal downloader for linux
rapiddownloader - is a small rapidshare console utility for linux written in JRuby. What it can do - is to handle multiple links and wait for timing in free account. So you can just leave it with a bunch of urls and be busy with your stuff.
Usage is quite simple:
Just place it in your $PATH location, make it executable and thats it.
Depends on JRuby, Java and Wget
Usage is quite simple:
rapiddownloader.rb {site1} {site2} {site3}
Just place it in your $PATH location, make it executable and thats it.
Depends on JRuby, Java and Wget
Google Site
I have made my google site where i plan to upload my dotfiles and utilities.
Here is the link
Here is the link
Monday, May 4, 2009
Adobe Flex Builder Alpha is available for Linux
I am very happy that it is already possible (seems like it is available already for a long time - but somehow I couldn't find it before):
http://labs.adobe.com/downloads/flexbuilder_linux.html
But note that eclipse 3.3.x is required
P.S.
1/ workaround: http://bugs.adobe.com/jira/browse/FBE-306?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
2/ there is a patch - but probably for the eariler version:
(Some details about mxml editor and eclipse 3.4: http://www.tekool.net/blog/2008/06/28/flex-builder-3-plugin-dont-work-with-eclipse-34/ )
http://labs.adobe.com/downloads/flexbuilder_linux.html
But note that eclipse 3.3.x is required
P.S.
1/ workaround: http://bugs.adobe.com/jira/browse/FBE-306?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
2/ there is a patch - but probably for the eariler version:
(Some details about mxml editor and eclipse 3.4: http://www.tekool.net/blog/2008/06/28/flex-builder-3-plugin-dont-work-with-eclipse-34/ )
Wednesday, March 25, 2009
my small last.fm script
it's a pity that lastfm is not going to be free anymore but still... here is my small script that i usually use to listen to last.fm:
(In order to use you need to install also a small "shell-fm" application.)
#!/usr/bin/env bash
# shell-fm helper
#* lastfm://user/${user}/loved
#* lastfm://user/${user}/personal
#* lastfm://usertags/${user}/${usertag}
#* lastfm://artist/${artist}/similarartists
#* lastfm://artist/${artist}/fans
#* lastfm://globaltags/${globaltag}
killall -9 shell-fm
function usage() {
printf "Usage: %s: [-u username] [[-p(ersonal)] [-l(oved)]] [-g globaltag] [-a artist]\n" $(basename $0) >&2
}
command="lastfm:/"
artflag=
while getopts 'u:plg:a' OPTION
do
case $OPTION in
u) command="$command/user/$OPTARG"
;;
l) command="$command/loved"
break
;;
p) command="$command/personal"
break
;;
a) artflag=1
command="$command/artist/$artist"
break
;;
?) usage
exit 2
;;
esac
done
#printf "Remaining arguments are: %s\n" "$*"
shift $(($OPTIND - 1))
rest=""
if [ $artflag ]
then
while [ $# -ge 1 ]; do
if [ "$rest" != "" ]; then
rest="$rest+"
fi
rest="$rest${1}"
shift
done
fi
shell-fm -d $command$rest
(In order to use you need to install also a small "shell-fm" application.)
Thursday, January 22, 2009
Youtube feature
Have found a new feature in youtube - adding the following parameter to the url will improve the quality of music (and probably video as well):
Didn't play that much and don't know if it works for all the videos - probably not.
&fmt=18
Didn't play that much and don't know if it works for all the videos - probably not.
Subscribe to:
Posts (Atom)