Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

How to Automate Background Tweak?

  • 27-07-2008 5:22pm
    #1
    Registered Users, Registered Users 2 Posts: 748 ✭✭✭


    I've just installed Ubuntu 8.04 on my laptop and was reading up on tweaks and customisations online, I came across one that allowed you to set a screensaver as you wallpaper which liked the idea of so I followed the instructions and now have the scrolling matrix code as my wallpaper. However, I have to set this going each time I start my machine. I tried to add it as a command in system > preferences > sessions but this didn't work as the command must be run as root.

    The command must be run from a particular directory so currently to set it going I use the following two commands:

    cd xwinwrap
    sudo nice -n 15 ./xwinwrap -ni -o 0.20 -fs -s -sp -st -b -nf -- /usr/lib/xscreensaver/glmatrix -root -window-id WID&

    I was wondering if there is other way to automate this process, I've also tried adding them to rc.local but it seemed to have zero net effect.

    Thanks for any suggestions :)


Comments

  • Registered Users, Registered Users 2 Posts: 37,485 ✭✭✭✭Khannie


    Can you tell me why the command has to be run as root? It might be possible to work around that part of it.

    It's possible to disable sudo password checking, but that is dangerous. You can also disable sudo password checking for individual processes (less dangerous).


  • Registered Users, Registered Users 2 Posts: 748 ✭✭✭Zounds


    I've actually gotten it to run with out root, by giving it a better path. Now running it as:

    nice -n 15 /home/username/xwinwrap/xwinwrap -ni -o 0.20 -fs -s -sp -st -b -nf -- /usr/lib/xscreensaver/glmatrix -root -window-id WID&

    It works away fine without sudo-ing, however if I put this into session manager as a start-up application it seems to break gnome. (Menus don't disappear, things open very slowly, won't switch desktops etc).

    My working theory is that it's loading this before gnome or other applications it's dependent on are loaded but I haven't found another way of automating it.


  • Closed Accounts Posts: 1,377 ✭✭✭An Fear Aniar


    You could create a start-up script for the bash shell. I don't know a lot about it but I'm aware of it.

    http://www.thekip.nl/2007/08/17/how-to-setup-startup-scripts-in-ubuntu/

    You can use gedit text editor.

    Important thing is:
    make sure it starts with
    #!/bin/bash

    and
    copy your script to /etc/init.d/<filename>


    Also, I have a startup script for my Conky display - which I got by simply following the instructions in this thread:
    Then (Compiz users) place a startup script called .conky_start.sh in your home directory:

    Code:
    #!/bin/bash
    sleep 60 && conky;
    
    This would start conky after 60 seconds of your login. That way, compiz doesn't draw shadows around conky.

    Make sure the script is executable:
    chmod a+x .conky_start.sh
    

    and add it to your startup programs (menu: system->preferences->session->startup programs).

    In this case, I just put the file "conky_start.sh" in my home folder and added it as a start-up session. I don't know a lot about it but it works.

    Might be the way to go for you.

    .


  • Registered Users, Registered Users 2 Posts: 748 ✭✭✭Zounds


    I tried that an it apparently did nothing.

    Thanks anyway


  • Closed Accounts Posts: 1,377 ✭✭✭An Fear Aniar


    Zounds wrote: »
    I tried that an it apparently did nothing.

    Thanks anyway

    OK, I'm sure that there's someone on these forums thast knows how to do that - if not, try the Ubuntu Forums.

    With my Conky example, the command I have in the startup Sessions list is

    sh /home/"whoever you are"/.conky_start.sh


    .


  • Advertisement
Advertisement