https://www.destroyallsoftware.com/talks/wat
#wat?
tar -c -M -L 262144 --file=archive.{tar,tar-{1..100}} [files to be archived]
Tar [files to be archived]
in multiple 262144Kb tar files named archive.tar.x.
tar -xMv --file=archive.{tar,tar-{1..100}} [files to be extracted]
Extract [files to be extracted]
from multi volume archive.
Resources:
Wouter Coekaerts » Java Puzzle 3: Car.
That’s fun!
Unfortunately OpenJDK gives me headaches (eclipse crash in PDT and java applets not starting) in everyday work and I had to switch to OracleJDK (at least for now).
OpenJDK is a dependency on multiple Arch Linux packages so just installing Oracle’s JDK wasn’t enough.
First had to remove icedtea-web
sudo pacman -R icedtea-web
Then build Oracle JRE AUR package,
Before installing OracleJRE I had to remove openjdk6
manually and ignore dependencies:
[argy@Freak jre]$ sudo pacman -Rdd openjdk6
Install OracleJRE
sudo pacman -U jre-7u2-1-i686.pkg.tar.xz
Build and Install JDK AUR package:
sudo pacman -U jdk-7u2-1-i686.pkg.tar.xz
Logout and Login so the PATH gets updated and we are ready to go.
UPDATE: Actually Eclipse crashing had nothing to do with OpenJDK or PDT, but an issue with the installed xulrunner. Workaround available here: 6.1 Autocompletion and javadoc render crash
Resources:
I find really useful to switch keyboard layout while holding a key. That way I can easily type an English while writing in Greek. Left Windows key is good option for me as I don’t really need it on my Arch Linux powered laptop.
Can be easily setup in /etc/X11/xorg.conf.d/01-keyboard-layout.conf
:
Section "InputClass" Identifier "keyboard-layout" Driver "evdev" MatchIsKeyboard "yes" Option "XkbLayout" "us,gr" Option "XkbOptions" "grp:alt_caps_toggle,grp:lwin_switch" EndSection
A full list is available in /usr/share/X11/xkb/rules/xorg.lst
Edit the following in ~/.config/openbox/lxde-rc.xml:
<keybind key="Print"> <action name="Execute"> <command>screenshot-desktop.sh</command> </action> </keybind> <keybind key="A-Print"> <action name="Execute"> <command>screenshot-window.sh</command> </action> </keybind>
To take a full desktop screenshot:
#!/bin/bash DATE=`date +%Y-%m-%d\ %H\:%M\:%S` xwd -root | convert - "$HOME/Desktop/Screenshot-$DATE.png" notify-send "Desktop screenshot saved!" "A descktop screenshot was saved on your Desktop as:\n Screenshot-$DATE.png" -i /usr/share/icons/Tango/scalable/devices/camera.svg
screenshot-desktop.sh
To take the current window screenshot:
#!/bin/bash activeWinLine=$(xprop -root | grep "_NET_ACTIVE_WINDOW(WINDOW)") activeWinId="${activeWinLine:40}" activeWinTitle=$(xwininfo -id $activeWinId | grep 'Window id:' | cut -d"\"" -f2) COUNTER=0 FILENAME="$HOME/Desktop/$activeWinTitle-Screenshot.png" while [ -f "$FILENAME" ]; do let COUNTER=COUNTER+1 FILENAME="$HOME/Desktop/$activeWinTitle-Screenshot-$COUNTER.png" done import -window $activeWinId "$FILENAME" notify-send "Window screenshot saved!" "Windows screenshot was saved on your Desktop as:\n $FILENAME" -i /usr/share/icons/Tango/scalable/devices/camera.svg
screenshot-window.sh
Apache Pivot is an open-source platform for building rich web applications in Java. I was looking for a modern UI toolkit and Pivot is exactly that. I’m willing to give a try so I tried to setup some Pivot projects in Eclipse. It actually comes with an Eclipse plugin that simplifies development of Pivot applications.
So here is a quick guide to setup Eclipse for the development of Pivot applications
Continue reading Setup an Apache Pivot project in Eclipse