[Rubygems-developers] Quick feature request: cd to directory of a gem

Gavin Sinclair gsinclair at soyabean.com.au
Tue Jul 13 08:07:32 EDT 2004

On Tuesday, July 13, 2004, 8:47:14 PM, Chad wrote:

> Regarding your unpack idea, Gavin, perhaps you could wait until we're
> doing .tar.gz and just use your operating system's native .tar.gz 
> unpacking mechanism?  The exact reason that you want this feature is
> what led me to repropose Mauricio's format-change suggestion.

Sorry dude; just added it.  The format of the gem is irrelevant to the
feature.  I'd rather not deal with gem files directly, no matter how
they're represented.

  $ gem unpack rake
  Unpacked gem: 'rake-0.4.3'

  $ gem unpack rake -v '< 0.4'
  Unpacked gem: 'rake-0.3.1'

  $ gem unpack rak
  ERROR:  Gem 'rak' not installed.

  $ ls -l
  drwxr-xr-x+   6 Gavin Si None            0 Jul 13 22:02 rake-0.3.1
  drwxr-xr-x+   6 Gavin Si None            0 Jul 13 22:02 rake-0.4.3

  $ gem help unpack
  Usage: gem unpack GEMNAME [options]

      -v, --version VERSION            Specify version of gem to unpack

    Common Options:
      -p, --[no-]http-proxy [URL]      Use HTTP proxy for remote operations
      -h, --help                       Get help on this command
          --config-file FILE           Use this config file instead of default
          --backtrace                  Show stack backtrace on errors

      GEMNAME       Name of the gem to unpack

      Unpack an installed gem to the current directory

      --version '> 0'

Thoughts?  I *really* like it.


More information about the Rubygems-developers mailing list