Mount and unmount/umount images(iso/img) from nautilus (Fixed not mounting in Fedora)

2010-03-09 2 min read Fedora GNOME

Get the Nautilus Script <a href="http://gnome-look.org/content/show.php/moiso?content=84301" target="_blank">here. So what is required is that you have the necessary permission to run mount and umount as normal user with sudo command. If you are using gksu or gnomesu then you can change this in the script that you will get. Once you have got the script then you can run the installer for the script that comes in the package.

If you are running this is Fedora then you would need to make one more change other than the ones done by the installer, which is to allow sudo from non tty devices. Since this will be running from the nautilus so the script will not have any tty device and hence you would need to comment the following in the /etc/sudoers file:

Continue reading

Mod and hack the GNome main menu with automated scripts to create a menu of the directory.

2010-03-04 2 min read GNOME Linux

Problem:
I had a directory with very good collection of my scripts and very organized in folders. The structure is something like this, first I have the broad classification of the category. Then I have the name of the tool/script as the name of the directory. All these are perl/python or shell scripts and luckily labelled so with the extension. I want to add these to the GNome main (Applications) menu.
Solution:
Lets take it stepwise:
1)  Add new menu tools to the Applications menu. Go to /etc/xdg/menus
Open the file applications.menu and add the following before

Continue reading

Setting the title of PuTTY window.

2010-02-04 1 min read GNOME Linux

Setting the title for PuTTY window is quite a simple trick. The trick is to set the PS1 with a escape sequence. When the PS1 is set with the escape sequence the variable will set the title window also. And not only can this trick be used in PuTTY but even on gnome-terminal to set the title dynamically. You can use this in the .bashrc or .bash_profile file to do it whenever you are starting the terminal.

Continue reading

change the terminal title dynamically in X11

2010-01-09 1 min read Bash GNOME Linux

I was actually looking for this for quite sometime. Some years back in my bashrc was the proper setting for setting the terminal title when I did a cd, and I had completely forgotten how to do it. So today I searched quite a few commands the environment variables for doing the same and found it again.

Here it is (Just put this in your bashrc or bash_profile):

export PROMPT_COMMAND=&#8217;echo -ne &#8221;\033]0;`pwd`&#8221;; echo -ne &#8221;\007&#8221;&#8217;

Continue reading

C Prog to change wallpaper in every 30 seconds.

2009-12-08 1 min read GNOME

I wrote a good length of description on the below but somehow my browser closed without saving that. So I am just putting the program below:

#include <stdio.h>
#include <sys/types.h>
#include <dirent.h>
#include <string.h>
#include <gconf/gconf-client.h>

int main(int argc, char ** argv)
{
DIR *dp;
struct dirent ep;
char dirname[80];
GConfClient
client;
int s;

if (argc<=1)
{
printf(&#8221;%d is argc\n&#8221;, argc);
fflush (stdout);
dp = opendir(&#8221;.&#8221;);
strcpy(dirname, &#8221;.&#8221;);
}
else
{
dp = opendir(argv[1]);
strcpy(dirname, argv[1]);
}
if (argc <=2 )
s = 30;
else if ( argc >2 ) s = atoi(argv[2]);
//g_type_init();
client = gconf_client_get_default();
//client = gconf_client_get_for_engine (gconf_engine_get_default());

Continue reading

gnome-shell and gnome-do on F11 Screenshots

2009-12-02 1 min read Fedora GNOME

Here are some screenshots of gnome-shell :

<a href="http://blog.amit-agarwal.co.in/wp-content/uploads/2010/08/screenshot_0011.jpe"><img class="size-full wp-image-1246" title="Gnome Shell" src="http://blog.amit-agarwal.co.in/wp-content/uploads/2010/08/screenshot_0011.jpe" alt="Gnome Shell" width="840" height="525" />

<a href="http://blog.amit-agarwal.co.in/wp-content/uploads/2010/08/Screenshot.png"><img class="size-full wp-image-1247" title="Gnome Shell" src="http://blog.amit-agarwal.co.in/wp-content/uploads/2010/08/Screenshot.png" alt="Gnome Shell" width="840" height="525" />

<a href="http://blog.amit-agarwal.co.in/wp-content/uploads/2010/08/Screenshot-1.png"><img class="size-full wp-image-1248" title="Gnome Shell" src="http://blog.amit-agarwal.co.in/wp-content/uploads/2010/08/Screenshot-1.png" alt="Gnome Shell" width="840" height="525" />

<a href="http://blog.amit-agarwal.co.in/wp-content/uploads/2010/08/Screenshot-2.png"><img class="size-full wp-image-1249" title="Gnome Shell" src="http://blog.amit-agarwal.co.in/wp-content/uploads/2010/08/Screenshot-2.png" alt="Gnome Shell" width="840" height="525" />

Older posts Newer posts