You are not logged in.

#1 2009-12-24 04:25:04

MGu3l
Member
From: Medellín, Colombia
Registered: 2009-12-19
Posts: 109

script to Compiz [XFCE]

Good night

I wish someone would help me with a question I have ...

recently started to test the XFCE desktop and I feel very comfortable with, it's fast, easy to operate and achieve compiz:)

to start at the beginning [x_X] without fusion-icon, I have tested the methods described in the wiki and none of them worked ... say it´s not something very serious, but I don't like having the tray full of icons, call it a fad tongue

I now, that running the command "LIBGL_ALWAYS_INDIRECT = 1 INTEL_BATCH = 1 compiz - replace - indirect-rendering - sm-disable ccp &" in the terminal, compiz will run properly. my question is... how can I make a script for my user, to start at the terminal [sakura] and run that command? it is a question a little silly, but the truth ... I am not an engineer, I am a publicist and I never studied anything of informatic or programming languages ... so...

hope you can help me and thanks big_smile


"Dream as if you'll live forever, live as if you'll die today" - James Dean

Offline

#2 2009-12-24 08:29:55

PirateJonno
Forum Fellow
From: New Zealand
Registered: 2009-04-13
Posts: 372

Re: script to Compiz [XFCE]

to make a script, just put something like this in a file:

#!/bin/bash

(put your commands here)

and save it, then do

$ chmod a+x /path/to/script

hope that helps


"You can watch for your administrator to install the latest kernel with watch uname -r" - From the watch man page

Offline

#3 2009-12-24 10:00:02

MGu3l
Member
From: Medellín, Colombia
Registered: 2009-12-19
Posts: 109

Re: script to Compiz [XFCE]

thx for answering!!

so basically my script should look like this?

 

#!/bin/bash

LIBGL_ALWAYS_INDIRECT = 1 INTEL_BATCH = 1 compiz - replace - indirect-rendering - sm-disable ccp &

make it executable and then add it to the aplications that will load at the begining?

and another thing, besides compiz i also need to start MPD, wich doesnt start as a daemon... so i could use one script for both commands, like this?

 

#!/bin/bash

LIBGL_ALWAYS_INDIRECT = 1 INTEL_BATCH = 1 compiz - replace - indirect-rendering - sm-disable ccp &

mpd ~/.mpd/config

or do i need to create one script for compiz, and another to mpd?

Thx for your help

Last edited by MGu3l (2009-12-24 10:00:33)


"Dream as if you'll live forever, live as if you'll die today" - James Dean

Offline

#4 2009-12-24 10:05:48

PirateJonno
Forum Fellow
From: New Zealand
Registered: 2009-04-13
Posts: 372

Re: script to Compiz [XFCE]

that looks about right, but i think it has too many spaces. try this instead:

#!/bin/bash

LIBGL_ALWAYS_INDIRECT=1 INTEL_BATCH=1 compiz -replace -indirect-rendering -sm-disable ccp &

yeah, so chmod makes it executable. on most systems ~/.config/autostart contains the things that get run when you login, but those are .desktop files which have a slightly different format (let me know if you want me to explain).

You should be able to use both of those if you really want to, because the ampersand at the end of the compiz command makes it run in the background. however IIRC mpd is supposed to be run as a system daemon from rc.conf, running it as yourself might not be a good idea (but is probably possible). i think its cleaner to make 2 separate scripts but that's up to you really.


"You can watch for your administrator to install the latest kernel with watch uname -r" - From the watch man page

Offline

#5 2009-12-24 21:52:37

MGu3l
Member
From: Medellín, Colombia
Registered: 2009-12-19
Posts: 109

Re: script to Compiz [XFCE]

jajaj you're right... don't know why it has so much spaces, i just did a ctrl+C ctrl+V

sure, i'll love to hear whats the difference of the .desktop files. so after making it executable should i put it in the autostart folder, or add it to the autostart applications in the settings menu?


well, about mpd... it's posible to run it as myself instead of as a daemon, and the reason why i do it it's because all the mpd files are in my home: config, db, logs, etc. So if i start mpd as a daemon, it tries to read the config file in ...i don't remember excatly, but i think it's /usr/share/mpd or something like that, but there are no files... so instead, i make it run like "mpd ~/.mpd/config" and it starts reading the config file in that folder and works perfectly.


"Dream as if you'll live forever, live as if you'll die today" - James Dean

Offline

Board footer

Powered by FluxBB