* Alexander Kapshuk <alexander.kaps...@gmail.com> [150831 15:35]:
> Having read the email exchange on the possibility of using
> 'package.use' as a directory, I thought I would give that a try.
> 
> Here is what I have attempted so far.
> 
> cd /etc/portage
> mv package.use package.use.COPY
> mkdir package.use
> cd package.use
> awk -F'[/\t ]+' '{printf("echo \047%s\047 >> ", $0); sub("-[0-9]+.*",
> "", $2); print $2}' ../package.use.COPY
> 
> NOTE; the awk output just generates the command lines for the shell to
> run. If the output is acceptable, it should be piped through to the
> shell.
> 
> Here is the contents of the original 'package.use' file:
> 
> cat package.use
> =dev-lang/python-2.7.9-r1 sqlite
> >=dev-ruby/json-1.8.2-r1 ruby_targets_ruby21
> >=dev-ruby/racc-1.4.11 ruby_targets_ruby21
> >=dev-ruby/rake-0.9.6-r1 ruby_targets_ruby21
> >=dev-ruby/rdoc-4.0.1-r2 ruby_targets_ruby21
> >=dev-ruby/rubygems-2.2.5-r1 ruby_targets_ruby21
> >=media-libs/harfbuzz-0.9.38 icu
> >=media-video/ffmpeg-2.6.3 theora
> >=sys-libs/zlib-1.2.8-r1 minizip
> >=virtual/rubygems-10 ruby_targets_ruby21
> gnome-base/gvfs -http gphoto2 mtp
> media-video/vlc a52 aac bidi cdda cdio dts dvd flac freetype gnutls
> httpd libass live lua mad matroska mpeg ogg oggvorbis qt4 stream svga
> theora vcd vlm wxwindows xv
> net-print/hplip scanner qt4
> sys-apps/busybox -pam
> sys-devel/gcc objc
> sys-process/cronie anacron
> x11-base/xorg-server udev
> xfce-extra/xfce4-power-manager -udisks
> xfce-extra/xfce4-sensors-plugin hddtemp lm_sensors
> 
> NOTE: There are two entries for 'rubygems' there.
> 
> Here is the awk script output:
> 
> echo '=dev-lang/python-2.7.9-r1 sqlite' >> python
> echo '>=dev-ruby/json-1.8.2-r1 ruby_targets_ruby21' >> json
> echo '>=dev-ruby/racc-1.4.11 ruby_targets_ruby21' >> racc
> echo '>=dev-ruby/rake-0.9.6-r1 ruby_targets_ruby21' >> rake
> echo '>=dev-ruby/rdoc-4.0.1-r2 ruby_targets_ruby21' >> rdoc
> echo '>=dev-ruby/rubygems-2.2.5-r1 ruby_targets_ruby21' >> rubygems
> echo '>=media-libs/harfbuzz-0.9.38 icu' >> harfbuzz
> echo '>=media-video/ffmpeg-2.6.3 theora' >> ffmpeg
> echo '>=sys-libs/zlib-1.2.8-r1 minizip' >> zlib
> echo '>=virtual/rubygems-10 ruby_targets_ruby21' >> rubygems
> echo 'gnome-base/gvfs -http gphoto2 mtp' >> gvfs
> echo 'media-video/vlc a52 aac bidi cdda cdio dts dvd flac freetype
> gnutls httpd libass live lua mad matroska mpeg ogg oggvorbis qt4
> stream svga theora vcd vlm wxwindows xv' >> vlc
> echo 'net-print/hplip scanner qt4' >> hplip
> echo 'sys-apps/busybox -pam' >> busybox
> echo 'sys-devel/gcc objc' >> gcc
> echo 'sys-process/cronie anacron' >> cronie
> echo 'x11-base/xorg-server udev' >> xorg-server
> echo 'xfce-extra/xfce4-power-manager -udisks' >> xfce4-power-manager
> echo 'xfce-extra/xfce4-sensors-plugin hddtemp lm_sensors' >>
> xfce4-sensors-plugin
> 
> The two 'rubygems' entries I had in the original 'package.use' file
> went into a single 'rubygems' file:
> 
> cat rubygems
> >=dev-ruby/rubygems-2.2.5-r1 ruby_targets_ruby21
> >=virtual/rubygems-10 ruby_targets_ruby21
> 
> Is this format acceptable? Or should I have used two separate files,
> one for 'dev-lang/rubygems', and another for 'virtual/rubygems'?
> 
> I have run 'emerge -auUND @world' since the transition, which voiced
> no complaints so far.
> 
> The list's input would be appreciated.

Those should all be fine.  I tend to make a file per package but I think
you could have just moved your original package.use into the
/etc/portage/package.use directory and everything would be fine (aside
from you not gaining any benefit from separate files.)

Todd

Reply via email to