Now with apache ivy, there's no need for maven, and I can easily rewrite Ant targets in xml without diving into extending maven. However, I still miss maven's "Convention over Configuration", and I hate reconfiguring every single war file, when using ANT+IVY combo. Gradle looked promising, but hey, when will I stop learning new build systems ? How many build system available and all of them address one single problem. If ant+ivy can do it, then they are good enough for me.
Plus, I was hit with gradle limitation, the third day I started using it and tried to extend it.
runnig task programmatically
To me, nothing is more transparent than ant and easier to customize, except those repetitive configurations.
May be it's the time for a simple antlib that saves me for writing those configuration again and again.
Tuesday, January 24, 2012
Saturday, June 18, 2011
Connecting to samba share from windows guest on KVM
- Install samba server. I will not explain this here as it depends on your linux distribution.
- Configure it: cat /etc/samba/smb.conf
[WorkShare]
comment = Host Share
path = /home/mansour/work/
valid users = mansour
public = yes
writable = yes
printable = no
- Now we need add "mansour" to samba users. If you don't this, you wont be able to login to the share!
smbpasswd -a mansour
- start your KVM :
kvm -m 2G -vga std -smp 2 -net nic,vlan=1 -net user,vlan=1 my-window-xp-pro.im
- From window Start --> Run : \\10.0.2.2\WorkShare
enter the username and password, and you should be able to view the files in your share.
For reference: Use Windows XP on Gentoo Linux with KVM
Sunday, June 12, 2011
Installing Perl Modules with CPAN
I was trying to install the latest version of XSH2. Really a very neat utility, and a must for each XML programmer. The previous revision had a bug, and I didn't know that I can install the latest from CPAN, just like I install any other software with emerge, yum, RPM, or ruby gem. Ok, so here's the steps:
- Login as root.
- Initialize the CPAN configuration. This is easily done with:
perl -MCPAN -we 'shell'
Accepting all the defaults is ok.
- Now run
install XML::XSH2
And you are good to go.
Tuesday, April 5, 2011
Copy the selected text in visual mode to search
I many cases I like to search for other occurrence of some text in a file, under vim. Here's are the steps:
- Yank with y
- Start the search with the forward slash "/"
- CTRL-r then type "
Monday, March 28, 2011
Applying Mutt function to multiple messages
Sometimes you may need to apply a function to more than one message in mutt. Let's say mark all the messages in a folder as read. In this case, you need to tag all the messages. SHIFT-T will ask you for the pattern. Just type "all". Then, use the tag-prefix command ";" to apply the function.
The function to mark a message as read is "W r". The letter "W" to clear a flag. And the letter "N" is the flag indicating a New Message. When you hit enter these keys combination after tagging messages, you will notice all messages has been processed.
The function to mark a message as read is "W r". The letter "W" to clear a flag. And the letter "N" is the flag indicating a New Message. When you hit enter these keys combination after tagging messages, you will notice all messages has been processed.
Wednesday, March 24, 2010
crossdev on gentoo and pkg-config
I was trying to link against libraries on gentoo for windows. Using mingw32 and the crossdev tools made things easier, but they were not too smooth. One of the problems was getting pkg-config prefix.
For example:
I wanted to link against dbus, so in my makefile I should use:
LIBS=$(shell pkg-config --cflags --libs dbus-1)
For none cross compile, this would work, however, for cross compile this is not the case.
Refering to the :http://en.gentoo-wiki.com/wiki/Crossdev
I crated a script in /usr/bin/i686-mingw32
For example:
I wanted to link against dbus, so in my makefile I should use:
LIBS=$(shell pkg-config --cflags --libs dbus-1)
For none cross compile, this would work, however, for cross compile this is not the case.
Refering to the :http://en.gentoo-wiki.com/wiki/Crossdev
I crated a script in /usr/bin/i686-mingw32
#!/bin/sh
SYSROOT="/usr/i686-mingw32"
export PKG_CONFIG_LIBDIR="${SYSROOT}/usr/lib/pkgconfig"
unset PKG_CONFIG_PATH PKG_CONFIG_ALLOW_SYSTEM_CFLAGS PKG_CONFIG_ALLOW_SYSTEM_LIBS
exec pkg-config "$@"but things didn't work as expected:
03:23:39 @ test $ i686-mingw32-pkg-config --cflags dbus-1 -I/usr/include/dbus-1.0 -I/usr/lib/dbus-1.0/include
hum, still pointing to the wrong one !
logged in as root, and :
mars ~ # cd /usr/i686-mingw32/usr/lib/pkgconfig/
mars pkgconfig # sed 's/prefix=\/usr/prefix=\/usr\/i686-mingw32\/usr/g' -i *.pc
logged in as a user again, and:
03:31:06 @ test $ i686-mingw32-pkg-config --cflags dbus-glib-1 -I/usr/i686-mingw32/usr/include/dbus-1.0 -I/usr/i686-mingw32/usr/lib/dbus-1.0/include -I/usr/i686-mingw32/usr/include/glib-2.0 -I/usr/i686-mingw32/usr/lib/glib-2.0/include
Wonderfull, pointing to the right place.
Subscribe to:
Posts (Atom)