Profile

Achievement

first submission:submitting first snipplet

narkisr's Recent Snippets



« Prev 1 2 3
Using http://www.clapper.org/software/java/util/javadocs/util/api/org/clapper/util/classutil/ClassFinder.html in order to find a class in class path.
0 776 posted 14 years ago by narkisr
An easy was to tunnel remote Couchdb instance into a local machine using ssh tunneling, by using the 5893 local port we enable the local instance to run (replication is only a click away).
0 986 posted 14 years ago by narkisr
Tunneling vnc over ssh
0 797 posted 14 years ago by narkisr
Mounting a windows share in Ubuntu (The UI version doesn't seem to offer a mount point).
0 808 posted 14 years ago by narkisr
Using contrib's trace ns in order to debug functions in the REPL
0 933 posted 14 years ago by narkisr
This is how to patch changes from svn into git (should work with other vcs as well).
0 789 posted 14 years ago by narkisr
This is based upon a debian guide, it seems to work well for ubuntu as well, all these steps can be performed via remote ssh (no need to access the machine).
0 759 posted 14 years ago by narkisr
This is excellent for testing (mocking a SOAP server for example), we use an in memory http server in order to answer client requests.
0 1065 posted 14 years ago by narkisr
Sniffing http request & response using pcap in Ruby.
2 836 posted 14 years ago by narkisr
How to setup a remote git repository via SSH.
0 915 posted 14 years ago by narkisr
The required steps in order to install xmlfs on Ubuntu.
0 829 posted 15 years ago by narkisr
A nice example of a function that returns another function.
0 927 posted 15 years ago by narkisr
Groovy has the as keyword which enables the implementation of a Java interface by using the as keyword, its quite easy to mimic this in JRuby.
0 951 posted 15 years ago by narkisr
A Functional quick sort (Java imperative version seems to be quicker).
0 1072 posted 15 years ago by narkisr
An easy way to launch an external process (http://docs.codehaus.org/display/GroovyJSR/Run+Sub-Process+Safely).
1 947 posted 15 years ago by narkisr
Clojsure composition in Groovy (functional style programing). @http://www.ibm.com/developerworks/java/library/j-pg08235/index.html
0 790 posted 15 years ago by narkisr
Creating a object that doesn't have any methods in Ruby (regular objects inherit methods from Object class), useful for Proxies that use method missing (http://onestepback.org/index.cgi/Tech/Ruby/BlankSlate.rdoc).
1 1119 posted 15 years ago by narkisr
An example of utilizing a category in Groovy in order to create withIndexfunctionality on lists each methods (traversing the list and having the index on each step), @ http://markmail.org/message/pa2irg4mvydpxi7c
0 820 posted 15 years ago by narkisr
A nice example of utilizing Groovy closures in order to create a when statement in Groovy (http://www.transentia.com.au/flatpress/?x=entry:entry090311-222726).
0 932 posted 15 years ago by narkisr
This, owner, and delegate: this : as in Java, this refers to the instance of the enclosing class where a Closure is defined owner : the enclosing object (this or a surrounding closure) delegate : by default the same as owner, but changeable. (htt...
1 1032 posted 15 years ago by narkisr
An example of redo statement in Ruby, redo makes an iteration step repeat itself again (http://www.rubyrailways.com/rubys-most-underused-keyword/).
1 789 posted 15 years ago by narkisr
Some nice base aliases, still need to go through them
2 934 posted 15 years ago by narkisr
Groovy ranges works on dates also! (http://kousenit.wordpress.com/2009/02/02/groovy-groundhogs/)
2 924 posted 15 years ago by narkisr
Running a btrace script takes two separate steps by default: 1. Running jps to get the Java process ID. 2. Running btrace on the ID. A simple awk script can merge the two into a single step.
0 785 posted 15 years ago by narkisr
How to run a KVM VM with no X (server environment, originally seen at http://blog.bodhizazen.net/?p=40).
0 733 posted 15 years ago by narkisr
This example shows how to clean up git's reflogs entries in order save space (see http://www.newartisans.com/blog/2008/04/diving-into-git.html).
0 2039 posted 15 years ago by narkisr
This snippet shows how to restore HEAD after using Git's reset method (see http://gitready.com/2009/01/17/restoring-lost-commits.html?disqus_reply=5271828#comment-5271828).
0 757 posted 15 years ago by narkisr
An immutable (a new object is created for each change) Java class builder pattern example.
0 768 posted 15 years ago by narkisr
« Prev 1 2 3