Wednesday, February 6, 2013

OpenJDK and ubuntu

So I am attempting to modify yuicompressor so I can use it and not spawn 10k instances of it while iterating over files (yes i know it takes a file list but i need to do pre-processing of each file).

$ sudo apt-get install openjdk-7-jdk
ant can't find tools.jar , ok
$ export  JAVA_HOME=/usr/lib/jvm/java-7-openjdk-amd64
ok now ant build works, but
$ java -version
says i'm running 1.6 ... wtf ...
http://askubuntu.com/questions/141791/is-there-a-way-to-update-all-java-related-alternatives
ok, aparently there is a whole system of how to manage alternatives in ubuntu ... cool ...
$ java -version
1.7 ... nice :)

Monday, January 21, 2013

Google IO

Been watching tons of videos from Google IO 2012, and before if the topic perked my interest.  So many cool uses of technology to do some crazy things.  This is just a laundry list of some of the tools/apps/etc... listed that could help with day to day stuff

google drive and the crazy integration they are doing with docs
  • lucid chart - could be useful for making ERD DB diagrams
  • hellofax - could finally get rid of that fax machine & phone line
  • slide rocket - who doesn't love some great bullet points

HTML 5 games

  • texture packer - used to make the atlas sheets for packing sprites etc... could be very useful in improving the load performance of "regular" web pages too thou...
  • https://github.com/kripken/emscripten translate LLVM bitcode into js ... wow ...


Tuesday, July 31, 2012

ctrl+tab style tabs in gvim

Forget where i first saw this but here it is, the win7 vim path is currently
C:\Program Files (x86)\Vim
and inside this folder the file _vimrc should have these lines 

:nmap <C-S-tab> :tabprevious<cr>
:nmap <C-tab> :tabnext<cr>
:map <C-S-tab> :tabprevious<cr>
:map <C-tab> :tabnext<cr>
:imap <C-S-tab> <ESC>:tabprevious<cr>i
:imap <C-tab> <ESC>:tabnext<cr>i
:nmap <C-t> :tabnew<cr>
:imap <C-t> <ESC>:tabnew<cr> 

After this change, restart vim, hit ctrl+tab, enjoy.

Monday, March 5, 2012

Big O

Quick and dirty explanation of Big O. Interesting for someone like myself w/o a huge math background.
http://c2.com/cgi/wiki?BigOh

Monday, February 20, 2012

Ruby (and rails)

So I've decided to learn Ruby and Rails. Just some links I've found useful in getting started.

Of course there is all the *nix/win32 env install crap, rvm seems to be THE choice, and since I'm using linux, it's easy enough.

Good entry point for a web developer.

A cross platform textmate like editor that may be worth looking into.

Further reading

Neat for the lazy learner. Threads are short here but interesting.

Comming with considerable php experience this was nice to see how CGI has been plugged into Ruby (Ruby->Rack->Rails)

more to come ...

Sunday, February 19, 2012

Bash string replace

I was using sed for template substitution recently and it seemed that no matter what regex delimiter I chose, that char existed in the template and caused my template population (sed replace) to fail. Fortunately bash has string substitution built right in, albeit with some slightly strange syntax.

# replace all @ chars with \@
x=${x//@/\\@}

now we can freely sub in values for our template variables w/o having to worry if they contain @ characters

#$1 = file name
#$2 = template variable name
sed -i s@$2@$x@g templates/$1