create magic.conf for gentoox pro

Request new features that might make using Gentoox better.
Post Reply
User avatar
Schultz
Novice
Posts: 40
Joined: Wed Mar 31, 2004 1:58 am

create magic.conf for gentoox pro

Post by Schultz » Fri Jan 07, 2005 7:28 pm

I was thinking about this and creating this so that you don't have to answre if you want to install kde, xfree, mplayer etc. every time that you run magic. so what when you actually wanted it changed you could edit a file and then run magic..

User avatar
ShALLaX
Site Admin
Posts: 1973
Joined: Sun Aug 10, 2003 9:25 pm
Location: England
Contact:

Post by ShALLaX » Sat Jan 08, 2005 12:30 am

yes "no" | magic
The original Xbox adaptation of Gentoo

User avatar
Schultz
Novice
Posts: 40
Joined: Wed Mar 31, 2004 1:58 am

Post by Schultz » Sat Jan 08, 2005 1:38 am

yea but i was wanting to be lazy and not have to type that every time.. but either way i can live.. Nothing too big.. thanks for listening anyways.

User avatar
nobspangle
Gentoox Guru!
Posts: 1681
Joined: Sun Sep 28, 2003 11:59 am
Location: Manchester, UK

Post by nobspangle » Sat Jan 08, 2005 11:24 am

Code: Select all

echo alias\ magic=\"yes \\\"no\\\" \| magic\" >> /root/.bash_profile

I haven't tested that you may need less \ around the no
If you keep an open mind, will your brain fall out?

User avatar
Schultz
Novice
Posts: 40
Joined: Wed Mar 31, 2004 1:58 am

Post by Schultz » Sat Jan 08, 2005 2:38 pm

nobspangle wrote:

Code: Select all

echo alias\ magic="yes \\"no\\" \| magic" >> /root/.bash_profile

I haven't tested that you may need less \ around the no


wow i its been a while since i really heavly used linux.. forgot about bash profile.. (pretty much setup server and left it alone till now really starting to work with gentoox)

thanks for the replies..

The only problem with that i can see is i woudn't want to run sync every time especially since magic updates itself and re-run's itself sometimes after being updated or during some of the updates could run again causing a resync which possibly could lead you to getting temp banned from gentoo's rsync servers.

but it was an idea and shallax said no need. So i will just not be as lazy and type yes,no,no,no a few more times..

User avatar
ShALLaX
Site Admin
Posts: 1973
Joined: Sun Aug 10, 2003 9:25 pm
Location: England
Contact:

Post by ShALLaX » Sat Jan 08, 2005 3:56 pm

/bin/magic-wrapper:

Code: Select all

#!/bin/bash
if [ ! -z $WANTSYNC ]; then
   emerge sync
fi
WANTSYNC=""

yes "no" | magic


Then, just run: WANTSYNC="yes" magic-wrapper
when you want it to sync.

A bit of a hack, but does the job.
The original Xbox adaptation of Gentoo

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest