View previous topic :: View next topic |
Author |
Message |
Circuitsoft Tux's lil' helper
Joined: 14 Jul 2004 Posts: 112
|
Posted: Wed Sep 05, 2007 5:55 am Post subject: USE flag organization. |
|
|
Came up with a way to keep my use flags a little more readable. Wonder what everyone else thinks:
USE="gtk qt qt3 qt4 fltk tk neXt -gnome -kde startup-notification fontconfig" # Desktop Options
USE="$USE mmx sse alsa -oss dbus hal fam acpi caps pcmcia disk-partition X xv opengl xcomposite fbcon directfb ieee1394" # Platform
USE="$USE ldap samba slp kerberos winbind sasl srp authdaemond avahi gnutls httpd upnp network" # Networking options
USE="$USE vim-syntax bash-completion plugins spell nsplugin skins encode" # App Options
USE="$USE audiofile libsamplerate sndfile sdl imlib t1lib lcms cairo glitz" # Media Libraries
USE="$USE xml truetype pango libnotify xcb djbfft bzip2 rle gd expat sqlite" # Other Libraries
USE="$USE cscope gs graphviz tcl jack" # Application support
USE="$USE jpeg jbig jpeg2k exif svg png mng gif tiff djvu wmf pdf xpm xface fpx hdri openexr q8 q32" # Image formats
USE="$USE mpeg theora win32codecs x264 xvid quicktime real" # Video formats
USE="$USE a52 aac amr dts flac mod mp3 musepack speex vorbis" # Audio formats
USE="$USE cdda daap dc1394 dvb dvd live matroska ogg rtsp shout stream vcd cddb" # Media containers/transports |
|
Back to top |
|
|
omp Retired Dev
Joined: 10 Sep 2005 Posts: 1018 Location: Glendale, California
|
Posted: Wed Sep 05, 2007 6:03 am Post subject: |
|
|
Pretty nice, I must say.
I personally have nowhere near as many global USE flags set, so I just keep it in one long alphabetised line, with flags that are on and flags that are off separated. _________________ meow. |
|
Back to top |
|
|
Deem3n n00b
Joined: 15 Jun 2007 Posts: 20
|
|
Back to top |
|
|
Circuitsoft Tux's lil' helper
Joined: 14 Jul 2004 Posts: 112
|
Posted: Wed Sep 05, 2007 7:07 am Post subject: |
|
|
omp wrote: | I personally have nowhere near as many global USE flags set, so I just keep it in one long alphabetised line, with flags that are on and flags that are off separated. |
Do you attempt to have a complete desktop/office/multimedia system? Yes, I may have quite a few flags turned on, but I have a reason for each one, and each one in make.conf is used in more than one ebuild. I have as much in /etc/portage/package.use as I can, but many just need to be global. (the few, such as win32codecs, which seem like they would go in package.use are here because I use more than one media player) |
|
Back to top |
|
|
rgk Tux's lil' helper
Joined: 06 Apr 2007 Posts: 140 Location: ny
|
Posted: Wed Sep 05, 2007 7:08 am Post subject: |
|
|
mine is a complete mess, i have been wanting to organize it but i never did, i will now _________________ MadGizmo.com is awesome. |
|
Back to top |
|
|
enderandrew l33t
Joined: 25 Oct 2005 Posts: 731
|
Posted: Wed Sep 05, 2007 7:11 am Post subject: |
|
|
I used to use a similar method, but these days I just sort them alphabetically rather than in groups. _________________ Nihilism makes me smile. |
|
Back to top |
|
|
steveL Watchman
Joined: 13 Sep 2006 Posts: 5153 Location: The Peanut Gallery
|
Posted: Wed Sep 05, 2007 10:43 am Post subject: |
|
|
Nice :-)
You can use: USE+="blah blah" in bash (which all ebuilds are.) _________________
creaker wrote: | systemd. It is a really ass pain |
update - "a most excellent portage wrapper"
#friendly-coders -- We're still here for you™ ;) |
|
Back to top |
|
|
pdr l33t
Joined: 20 Mar 2004 Posts: 618
|
Posted: Wed Sep 05, 2007 11:25 am Post subject: |
|
|
I also alphabetize (easier to find if a flag is in there or not), but recently went to multiple lines in my workstation by using line continuation (backslash as last character on the line) - made it easier to edit than hitting 'b' or 'e' in command mode a whole bunch of times in vi.. Example:
Code: | USE="one two three \
four five six \
seven eight nine"
|
However, now I use cream as root to edit, so its not a navigation thing any more (can just click to move cursor), just for readability |
|
Back to top |
|
|
d2_racing Bodhisattva
Joined: 25 Apr 2005 Posts: 13047 Location: Ste-Foy,Canada
|
Posted: Wed Sep 05, 2007 11:30 am Post subject: |
|
|
Yeah, this is a great idea...a saw a lot a personal variable, but the use=#use + your use flag is great ! |
|
Back to top |
|
|
aidanjt Veteran
Joined: 20 Feb 2005 Posts: 1118 Location: Rep. of Ireland
|
Posted: Wed Sep 05, 2007 11:44 am Post subject: |
|
|
/etc/portage/package.use/${major-grouping}.use
make.conf sucks for anything but globally applicable USE flags options, and ufed does a fine job of managing them. :/ _________________
juniper wrote: | you experience political reality dilation when travelling at american political speeds. it's in einstein's formulas. it's not their fault. |
|
|
Back to top |
|
|
steveL Watchman
Joined: 13 Sep 2006 Posts: 5153 Location: The Peanut Gallery
|
Posted: Wed Sep 05, 2007 12:19 pm Post subject: |
|
|
AidanJT wrote: | make.conf sucks for anything but globally applicable USE flags options, and ufed does a fine job of managing them. :/ |
Agreed, although I think the OP answered that concern.
The \ character isn't needed at the end of the line, pdr, as bash does multi-line strings quite happily. |
|
Back to top |
|
|
jabol Apprentice
Joined: 05 Oct 2005 Posts: 269
|
Posted: Wed Sep 05, 2007 3:14 pm Post subject: |
|
|
And I use euse . You may imagine how does this look like |
|
Back to top |
|
|
hielvc Advocate
Joined: 19 Apr 2002 Posts: 2805 Location: Oceanside, Ca
|
Posted: Wed Sep 05, 2007 3:17 pm Post subject: |
|
|
Quote: | The \ character isn't needed at the end of the line, pdr, as bash does multi-line strings quite happily. | But nano do _________________ An A-Z Index of the Linux BASH command line |
|
Back to top |
|
|
Suicidal l33t
Joined: 30 Jul 2003 Posts: 959 Location: /dev/null
|
Posted: Wed Sep 05, 2007 3:26 pm Post subject: |
|
|
Wow my laziness knows no bounds, I just use ufed to manage $USE |
|
Back to top |
|
|
aidanjt Veteran
Joined: 20 Feb 2005 Posts: 1118 Location: Rep. of Ireland
|
Posted: Wed Sep 05, 2007 8:38 pm Post subject: |
|
|
Suicidal wrote: | Wow my laziness knows no bounds, I just use ufed to manage $USE |
So do I for the global stuff. Else I just use /etc/portgage/package.use/*, I've been meaning to do a script for minor/perpackage flags but I haven't got around to it yet. _________________
juniper wrote: | you experience political reality dilation when travelling at american political speeds. it's in einstein's formulas. it's not their fault. |
|
|
Back to top |
|
|
omp Retired Dev
Joined: 10 Sep 2005 Posts: 1018 Location: Glendale, California
|
Posted: Wed Sep 05, 2007 9:04 pm Post subject: |
|
|
Circuitsoft wrote: | omp wrote: | I personally have nowhere near as many global USE flags set, so I just keep it in one long alphabetised line, with flags that are on and flags that are off separated. |
Do you attempt to have a complete desktop/office/multimedia system? |
Well, I have enough applications to satisfy my daily usage.
My flags, in case you are interested:
Code: | */* aac aalib alsa cairo firefox flac gif gtk imap jpeg mp3 nptl nptlonly ogg opengl pango png theora tiff truetype unicode vim-syntax vorbis X -cups
*/* INPUT_DEVICES: -* evdev keyboard mouse
*/* VIDEO_CARDS: -* nvidia
app-crypt/pinentry -gtk -ncurses
dev-cpp/gtkmm accessibility
dev-libs/pwlib ldap
mail-client/mozilla-thunderbird -crypt
media-gfx/gimp jpeg png tiff
media-sound/lame -gtk
media-sound/mixxx -python
media-sound/ncmpc artist-screen key-screen search-screen
media-video/mplayer xv xvid
net-im/pidgin spell
sys-apps/paludis bash-completion inquisitio qa ruby |
_________________ meow. |
|
Back to top |
|
|
steveL Watchman
Joined: 13 Sep 2006 Posts: 5153 Location: The Peanut Gallery
|
Posted: Wed Sep 05, 2007 10:00 pm Post subject: |
|
|
hielvc wrote: | Quote: | The \ character isn't needed at the end of the line, pdr, as bash does multi-line strings quite happily. | But nano do :lol: |
I have alias nano='nano -w' in /etc/bash/bashrc (and ufed seems to keep the variable nicely formatted in any case -- without slashes ;) |
|
Back to top |
|
|
96140 Retired Dev
Joined: 23 Jan 2005 Posts: 1324
|
Posted: Wed Sep 05, 2007 11:58 pm Post subject: |
|
|
--
Last edited by 96140 on Fri Sep 13, 2013 9:06 am; edited 1 time in total |
|
Back to top |
|
|
omp Retired Dev
Joined: 10 Sep 2005 Posts: 1018 Location: Glendale, California
|
Posted: Thu Sep 06, 2007 12:17 am Post subject: |
|
|
nightmorph wrote: | It's so easy to cat foo >> /etc/portage/package.use, but that means going in every month or two to reorganize by category/packagename. |
Can't you just do something along the lines of the following to sort it?
Code: | sort /etc/portage/package.use > /etc/portage/package.use |
[edit] Apparently you shouldn't do this... _________________ meow.
Last edited by omp on Thu Sep 06, 2007 1:01 am; edited 1 time in total |
|
Back to top |
|
|
96140 Retired Dev
Joined: 23 Jan 2005 Posts: 1324
|
Posted: Thu Sep 06, 2007 12:47 am Post subject: |
|
|
--
Last edited by 96140 on Fri Sep 13, 2013 9:06 am; edited 1 time in total |
|
Back to top |
|
|
Tolstoi l33t
Joined: 20 May 2004 Posts: 678
|
Posted: Thu Sep 06, 2007 6:30 pm Post subject: |
|
|
I just ordered my use flags in make.conf alphabetically recently, that does it for me. |
|
Back to top |
|
|
libero Tux's lil' helper
Joined: 26 Mar 2004 Posts: 87 Location: Tokyo
|
|
Back to top |
|
|
steveL Watchman
Joined: 13 Sep 2006 Posts: 5153 Location: The Peanut Gallery
|
Posted: Fri Sep 14, 2007 8:28 am Post subject: |
|
|
omp wrote: | nightmorph wrote: | It's so easy to cat foo >> /etc/portage/package.use, but that means going in every month or two to reorganize by category/packagename. |
Can't you just do something along the lines of the following to sort it?
Code: | sort /etc/portage/package.use > /etc/portage/package.use |
[edit] Apparently you shouldn't do this... :lol: |
The redirect clobbers the file before the command starts so all you do is delete the file.
Code: | sort -k1 /etc/portage/package.use > newFile |
nightmorph wrote: | Lame. Rather than using a bash hack that you can't get around, just use /etc/nanorc -- that's what it's there for. |
Gee whiz, how old are you?! ;P Why on earth would I ever want to run nano with word wrap? I only use it occasionally in the console, but thanks for the pointer to the config file. I still don't want to use it though, after having looked at it. There was an interesting post about ebuild highlighting, but I do that in Kate anyhow (I should edit that with a newer version i think at some point) or vim in the console if I have no gui.
And BTW the alias isn't BASH-specific, I just happen to like the Bourne-Again SHell. |
|
Back to top |
|
|
Kyro n00b
Joined: 20 Dec 2002 Posts: 56 Location: Over here
|
Posted: Fri Sep 14, 2007 8:27 pm Post subject: |
|
|
Mine's ordered the following way
1_USE="3dnow 3dnowext 7zip"
A_USE="a52 aac ace acpi (etc...)"
B_USE="bash-completion bcmath (etc...)"
down to
Z_USE="zip zlib"
and
EX_USE="-arts"
where I put stuff I explicitly don't want. This is then followed by a simple:
USE="${A_USE} ${B_USE} ${C_USE} ... ${Z_USE} ${EX_USE}" line, which gathers it all together.
Makes it easy to read and easy to manage, in my opinion. _________________ Quis custodiet ipsos custodes? |
|
Back to top |
|
|
ocin Guru
Joined: 01 Jan 2006 Posts: 500
|
Posted: Sat Sep 15, 2007 1:19 am Post subject: |
|
|
I use ufed :p |
|
Back to top |
|
|
|