Friday, October 7, 2011

How to : Turn Autokey into super search application

First make script for "search invoke" and "search". There are 2 ways "search invoke", user input or direct search. For user Input I use this script:


result, text = dialog.input_dialog(title="Search", message="What do you want to search?")
if (result == 0  and text != ""):
    engine.run_script("search")


For direct search:



text = clipboard.get_selection()
if (text != ""):
    engine.run_script("search")



Please note that the text in blue is the name of the "search" script. You also have to bind keys to this script. As an example I use "super" + "space" for user input and "super"+"shift"+"space" for direct search because my experience on Gnome-Do, where they use the same button. But you can bind it any keys, that you find more comfortable.
The second part is the "search" script. The idea is actually pretty simple here. You have the text you want to search, you want to search that on the web and later your want web browser to open the page. Here is the default of my little super search application:

#First part - Youtube search

if(text[0:2]== "y "):
    text = text.replace(' ','+')
    system.exec_command("chromium-browser http://www.youtube.com/results?search_query=%s" %text[2:])
#Second part - default 
else:
    text = text.replace(' ','+')
    system.exec_command("chromium-browser http://www.google.de/webhp#q=%s" %text)   


Now I can search on specific website. But to do that I have to put some code to put it at work. In this case, to search on youtube I have to write "y " first, then after that the text I want to search. For default I will use google search.
These also some example of what it can do. Just copy paste it between first part and second part.

#Update computer

elif(text=="update"):
    system.exec_command("gksudo apt-get update && gksudo apt-get upgrade")

#Open multiple website
elif(text=="pack1"):
    system.exec_command("chromium-browser https://mail.google.com/mail/")
    system.exec_command("chromium-browser https://www.google.com/reader")
    system.exec_command("chromium-browser https://www.google.com/calendar/")

#Tell time or date
elif(text=="time"):
    date=system.exec_command("date +%T")    
    result, text = dialog.input_dialog(title="%s" %date, message="What do you want to search?")
    if (result == 0  and text != ""):
        engine.run_script("search")
elif(text=="date"):
    date=system.exec_command("date +%F")    
    result, text = dialog.input_dialog(title="%s" %date, message="What do you want to search?")
    if (result == 0  and text != ""):
        engine.run_script("search")

#Open application with our own keyword
elif(text=="terminal"):
    system.exec_command("gnome-terminal")


Please note that this code work if you have chromium browser. For another browser you have to change the word "chromium-browser" in the last line with another browser command.

Tuesday, September 13, 2011

How to : Recover forgotten password on windows

Resetarea parolelor Windows Pictures, Images and Photos
Good first two words
Yup, as it said, don't panic. If this case happen to you this maybe the answer.

Offline NT Password und Registry Editor


I have already used it, and it works great. You can download on their main page here. Don't forget to read the walkthrough, here.

Monday, August 15, 2011

Misc : Ubuntu 11.10

Another countdown Banner for Ubuntu 11.10 
Ubuntu 11.10 days to go

Saturday, August 13, 2011

Customize Lubuntu part 1 : My personal customization for powerful, fast and comfortable OS

lubuntu Pictures, Images and Photos
My hope for low spec computer
It is another hobby of mine to mess around with my OS, but in the end I got bored and want some light yet fast OS. Microsoft Windows is definitely no option and after some research it come down to Lubuntu. Here I will record of what I did for this new project. First part would be installing the Lubuntu desktop
  1. This is the most important step BACKUP YOUR DATA. 
  2. Clean the application. Psychocats have good command line for that here. You might also check other command or good tutorial from him. In this case if you not sure from which Ubuntu derivative you are coming, just combine all the command there. 
  3. After finish you get your new OS.
But these step are only installation part. But as the title said
customization for powerful, fast and comfortable OS
Lubuntu default applications are great, but I need something more. So I have to research through a lot of package, change some setting and make some list of what I need

  • Jdownloader and Autokey. Both are my important applications.
    • For Autokey to autostart at the beginning, I simply change /etc/xdg/lxsession/Lubuntu/autostart (credit to this post here)
  • Find the alternative for Ubuntu software source. here I use Kpackagekit. Muon could be another alternative.
  • Install Kate, because I need some firepower on simple everyday text editing. Sorry Leafpad
  • Ubuntu Tweak is tool that you cant miss for this session. Since I need option from this application to change the default application for specific extension.
  • Install Browsers, Opera, Firefox, Chrome, Chromium. It seems overkill but it work. Put an exception to chrome, because it always need a lot of resource at the start of program. I may have to work without it. I already uninstall it and switch to chromium. Note for Opera, if it cant be installed from repository, you have to install from official website.
  • I just have Deadbeef and Audacious as the default mp3 player. But Deadbeef have this last.fm plugin, so I choose this as default mp3 player.
  • Same thing also happen by Gnome Mplayer to VLC
  • This would be difficult, Pcmanfm or Nautilus. Both are simply good file manager, but I prefer Nautilus. After installing Nautilus, you cant change 100% to it but I though of another way.
    • Change file manager shortcut from "pcmanfm" to "nautilus --no-desktop" 
    • edit /home/user/.config/openbox/lubuntu-rc.xml by change every "pcmanfm" command to "nautilus --no-desktop"
    • Download Nautilus script from g-scripts, another nautilus script site. I take this website because they have archiver-unarchiver which can replace default extract here option
  • XArchive and File Rollerare not a good file archiver application, and Q7z isnt working on lubuntu. My last choice come to Peazip. It is good application when you handle with CJK filename.
  • I install LxMenuEditor to arrange my menu
Miscellaneous thing that I find when writing about this post
  • Calibre, a good ebook manager. If you have a lot of ebook this application will help you to sort them.
  • I also install Dropbox integration to nautilus.
Things that cant be done with lubuntu
  • Easystroke or mouse gesture application in general is not supported on Lubuntu. I am still researching about this one. when I found a good application, I will report here. Another alternative is installing add on for every browser.
For now I think thats all. My lubuntu is ready. If everything is worked as planned then maybe there will be no second part of this.

Sunday, June 12, 2011

Berlin Expedition part 2: first upload

train station by foreturiga
train station, a photo by foreturiga on Flickr.
here is the first photo. this one is edited with hugin software. it was pretty easy to do it and you can make it too.
download the software here
the next photo hopefully will be up for the next month along with the expedition post along it.

Via Flickr:
taken at S-Bahn Beusselstrasse. it my first photo i uploaded on flickr

Sunday, May 22, 2011

Berlin Expedition part 1 : setting up

longwalk.. Pictures, Images and Photos
next time I will upload my own foto


I got bored yesterday and I just got an idea about take a tour around Berlin. but the normal tour would be normal (obviously), so i take some rule and made my exploration of Berlin a special one.

My target is actually all S-Bahn and U-Bahn in Berlin, because they are easy to find. So rule is that i have to walk from one Bahn to another one. no minimal amount of Bahn that i have to take for every play as long as they are integer and bigger than one. If i have reach a Bahn, then that Bahn will be my save point. i can continue my exploration from this Bahn with any transportation available and walk to next Bahn. It is actually pretty simple so anyone can try.

while the exploration i will also take some photo and post them here.

My arsenal for this project will my ultimate camera Kodak C913 silver, old lovely Nokia, Ipod shuffle 2GB, and my wallet.

so the next problem is how i post here. For now i will use google map to show the route i have take. The photo will be uploaded in Photobucket, hope they have good online photo editor.

Friday, April 15, 2011

Misc : Ubuntu 11.04

Here is the countdown banner for ubuntu 11.04
The next version of Ubuntu is coming soon

now I am excited to see the new ubuntu.

Wednesday, March 2, 2011

Misc : Blog note

This blog is not dead, i am just busy with my real life and didn't give too much time on this one. I may add another post this month.
in the meantime i also do some project on my holiday, you can follow it on my facebook page. the report and everything else will be back to here to be compiled and prepared for another project. see you next time.