Posts

Showing posts from June, 2008

Some Photos from my office's Desktop

Image
It is Sunday, and I'm checking my old photos... And then, I found my office's desktop photos. You may want to see them. Sometimes, my desk is clean but sometimes, it get horribly messy... This is the average looks of it. Working on these Wireless Rain Gauge development have build up my skills in linux bash programming and I learn a lot on how Single Board computer works. In the beginning, we just create a daughter board and attach it to a hacked LinkSYS WRT45GS board which I've installed OpenWRT so I can embed my bash script inside. But then, we go for TS-7260 board from embeddedarm.com to get more control on the RainGause for version two. Till now, I'm still upgrading the code for more features and stability. Well, that's all for now. Enjoy what you're doing!!

Fixing Read More link appear on Blogger Fullpost

Image
Thanks to Paul Escolar who really use my code on 'How to create expandable post summaries in Blogger' and spot a bug on that tutorial. Hence my code for this blog is already changed for other additional stuff. Sorry for that silly mistakes . As I went to debug my tutorial, I found that whoever follow that tutorial properly will get the same result as Paul's blog. So, here is the explanation and how to fix it. Please check at the last chunk of code on 'Step #1 - Edit your template code' . The old code should look like this: <b:if cond='data:post.labels'> <b:loop values='data:post.labels' var='label'> <b:if cond='data:label.name == &quot;more&quot;'> <a expr:href='data:post.url'>...<b>Read more</b></a> </b:if> </b:loop> </b:if> where the previous screenshot is this: What this code do is checking the 'more' label and put that

How to create expandable post summaries in Blogger

Image
I've been tweaking my blog template because I've already bored with my old default template that I use previously. While working on this template, I'm thinking that it may be cool to have my long post to be truncated and have the "read more" link . I found the code from Blogger Help to do this. However, there is one issue with their code where the "read more" link will appear regardless of whether a post has been truncated or not. You can check it out at help.blogger.com on How can I create expandable post summaries? . If you have already read them, you should notice the disadvantages under the Note list which says: Disadvantages: Requires changes to the posts themselves, rather than to the template only. However, the "read more" link is in the template, so it will appear regardless of whether a post has been truncated or not. (Modifying this feature is left as an exercise for the reader.) Do you think it is a good exercise? So, how many of

How to Install .rpm packages in Ubuntu

Image
Ubuntu normally use .deb package for application installer. However, if you have an rpm file for a package you wish to install, and if you cannot find a .deb debian package in any of the Ubuntu repositories or elsewhere, you can use the alien package converter application to install the .rpm file. Alien is a program that converts between the rpm, dpkg, stampede slp, and slackware tgz file formats. If you want to use a package from another distribution than the one you have installed on your system, you can use alien to convert it to your preferred package format and install it. Despite the large version number, alien is still (and will probably always be) rather experimental software. It has been used by many people for many years, but there are still many bugs and limitations. Alien should not be used to replace important system packages, like sysvinit, shared libraries, or other things that are essential for the functioning of your system. Many of these packages are set up different

Bash Scripting - Script execution counter

This Linux shell script does nothing than just increasing n value every time it is executed and then keep the value in a file. When the value goes greater than 10, it will drop back to 1. Uhhh... this reminds me to the increasing of the fuel price. But that fuel price will just increase and will never drop back... Lol... Anyway, I wrote this bash script just to make a permanent variable to be used as bash script running counter. With this code, I can count how many time the script have been executed. Here's the code: #!/bin/sh nfilename="./nvalue" n=0 touch $nfilename . $nfilename echo "current n value is $n" n=$(expr $n + 1) if [ $n -gt 10 ]; then n=1 fi echo "new n value is $n" echo "n=$n" > $nfilename Here's the step for testing the script for newbies bash scripter. 1. Create one text file in your home folder. In this example I'm using ncounter as the file name: apogee@apogee-persiasys:~ gedit ncounter 2. Copy and p

PC in a Keyboard

Image
Have you ever wished of having a desktop where your super slim LCD monitor attached to just a keyboard? And nothing else? If you did, it is worth to have a look at this space saving desktop computer from Cybernet , the Computer in a Keyboard . This company has shrunk the CPU behind a regular sized keyboard and it comes complete with an Intel Core 2 Quad chip, DVD drive, hard disk drive, up to 4GB RAM, a touchpad, memory card slots and standard USB ports . Even thou it makes the keyboard bulky, it can be a small tradeoff for all the space saving that the PC achieves. You can plug your standard monitor or even your LCD monitors into this Computer in Keyboard . Isn't that great? As far as I know, the PC in keyboard is fully customizable and will cost around $700 to $1100. Enjoy!!

Howto Create .ISO images from CD or DVD in Linux

Image
In Linux computer , we have a simple tool to create CD or DVD .ISO file. This is very helpfull to backup your CD and DVD into ISO images: To make an ISO from your CD/DVD, place the media in your drive but do not mount it. If it automounts, unmount it. for dvd: $ dd if=/dev/dvd of=mydvd.iso for cdrom: $ dd if=/dev/cdrom of=mycd.iso for scsi cdrom: $ dd if=/dev/scd0 of=mycd.iso And if you wanna make an ISO from files on your hard drive, create a directory which holds the files you want. Then use the mkisofs command. mkisofs -o /tmp/mycd.iso /tmp/directory/ This results in a file called cd.iso in folder /tmp which contains all the files and directories in /tmp/directory/. For more info, see the man pages for mkisofs, losetup, and dd, or see the CD-Writing-HOWTO at http://www.tldp.org. Enjoy Linux!!