Skip to content


Subversion checkout URL

You can clone with
Download ZIP
Commits on Apr 27, 2015
  1. @tenderlove

    never delete from the spec fetcher, only add

    tenderlove authored
    this reduces the number of places where we are mutating the things
    stored in cache.  The clear command was typically used to just add a gem
    file to the gem cache, then clear the specs from rubygems's in-memory
    cache.  Since we just want the gem file stored in the cache, this commit
    introduces a new method for "downloading" a gem but not installing it.
    Then we can remove the "clear" command since we don't ever need to clear
    the cache
  2. @tenderlove

    Merge pull request #1209 from segiddins/seg-symlink

    tenderlove authored
    Add support for packaging specs that contain symlinks
  3. @tenderlove

    Merge pull request #1233 from jcvernaleo/bitrig

    tenderlove authored
    Add Bitrig to platforms.
Commits on Apr 26, 2015
  1. @zzak

    Merge pull request #1228 from chancancode/fix_gem_list_docs

    zzak authored
    Fix doc for `gem list` (follow-up for #905)
Commits on Apr 25, 2015
  1. @zzak

    Merge pull request #1200 from ms-ati/more-dry-list

    zzak authored
    DRY up Gem::List in utils
Commits on Apr 23, 2015
  1. @jcvernaleo

    Add Bitrig to platforms.

    jcvernaleo authored
Commits on Apr 20, 2015
  1. @chancancode
Commits on Apr 18, 2015
  1. @tenderlove

    fix updating index generation

    tenderlove authored
    this also removes another call to add_specs
  2. @tenderlove

    don't mutate spec cache in generate_index

    tenderlove authored
    since generate_index must be pointed at a list of gems, just store the
    list of specs in a variable and pass the variable around rather than
    setting globals inside rubygems.
    This allows us to get rid of another call to add_specs
  3. @tenderlove

    clear unresolved_deps on test teardown

    tenderlove authored
    some tests leave unresolved deps when the test is finished.  The next
    time a require happens [like during test setup](
    it will try to resolve those specs, but since they've been removed, it
    will result in a nil spec and everything blows up
  4. @tenderlove

    always restore loaded features

    tenderlove authored
    we should try to make sure that all globals are returned to their
    previous state
Commits on Apr 17, 2015
  1. @tenderlove
Commits on Apr 15, 2015
  1. @tenderlove

    eliminate regexp support from `matching_specs`

    tenderlove authored
    pull the regexp support up to the caller so that Dependency doesn't need
    to deal with regular expressions when looking up specs
  2. @tenderlove

    use the installer to install specs

    tenderlove authored
    We should use the Installer to install specs.  This commit allows the
    tests to pass without caching all the specs in `@@specs` and gives the
    tests a more "realistic" view of how gems are installed and used.
    This means that you must install the specs in the correct order (so that
    dependencies are met).
  3. @ms-tg @ms-ati

    DRY up util Gem::List

    ms-tg authored ms-ati committed
    1. Methods `#find` and `#to_a` can use the implementations
    defined in Enumerable. 
    2. The inclusion of Enumerable in Struct was the obstacle,
    so remove the Struct and define a constructor instead, in
    roughly the same number of lines of code.
    3. Avoid potential N^2 behavior in previous `to_a` implementation.
    Why? `Array#unshift` has linear performance, so iteratively
    building a reversed array by unshifting risks N^2 performance.
    Instead, do a single `#reverse` for linear at worst.
    (I head about this code from #1188 via Ruby Weekly news)
  4. @tenderlove

    loaded_from should change depending on if it's a default gem

    tenderlove authored
    we should set loaded_from do the default_spec_file if we're installing a
    default gem.
  5. @tenderlove

    puts the knowledge of the default spec dir in one place

    tenderlove authored
    The default spec directory was written to [using gem_home](, but read [from a different path](  In other words, it was possible to write a default specification that would never be read.
    This commit consolidates the information so that default gems will be
    written and read from the same place.
  6. @tenderlove

    speed up default_gem? on stub specifications

    tenderlove authored
    we know at instantiation time that certain specifications are for
    default gems.  `default_gem?` recalculates that info.  Since we already
    have this information, we can set it on the spec instance at the time of
    creation and save recalculation costs.
    we *may* want to extend this to the specification instances too, but
    since Specification instances are allocated inside gemspec files, it
    seems dangerous to change their constructors.
Commits on Apr 12, 2015
  1. @Elffers

    Make GemDependencyAPI available after .use_gemdeps

    Elffers authored
    Previously, the files specified with the `:require` option in a Gemfile
    were not accesible to plugin authors. Now, the GemDependencyAPI object
    provides access to them via `Gem.gemdeps.requires`.
    Fixes #1213
  2. @GeekOnCoffee
  3. @tenderlove

    add mkmf.log location to failure output

    tenderlove authored
    When an extension fails, usually you need to look at the mkmf.log file
    to figure out what went wrong.  This commit adds the location of the
    mkmf.log file to the error output so that you can copy and paste the
    location and see what went wrong.
Commits on Apr 10, 2015
  1. @tenderlove

    remove extra caching on `spec`

    tenderlove authored
    The package object already caches the spec object, so we don't need to
    do it multiple times.  Also introduce a consturctor for in-memory
    installations so that we can rm the `spec` setter method
  2. @tenderlove

    backwards compatibility

    tenderlove authored
  3. @tenderlove

    pass the security policy to the package constructor

    tenderlove authored
    this means we don't have to mutate the package object in the Installer's
    constructor.  Also, we can remove some dead code.
  4. @tenderlove

    add an installer constructor for paths

    tenderlove authored
    This allows us to provide objects that quack like a `Gem::Package` to
    the installer class via `new`.
  5. @tenderlove

    ask the package object to copy the files

    tenderlove authored
    This way the installer doesn't need to hold a reference to the file path
    of the .gem file
Commits on Mar 31, 2015
  1. @segiddins
  2. @segiddins
Commits on Mar 30, 2015
  1. @tenderlove

    change loaded_from to an attr_accessor

    tenderlove authored
    `loaded_from=` was the top bottleneck on Rails boot.  I tested by doing
    this on an empty app:
    $ RUBYOPT='-I/Users/aaron/git/stackprof/lib:~/git/rubygems/lib -rstackprof/process' rake environment
    Where stackprof/process.rb contained:
    require 'stackprof'
    at_exit {
      StackProf.stop'OUT', 'wb') { |f|
        f.write Marshal.dump StackProf.results
    StackProf.start mode: :wall
    This dropped startup by about 2%, but more importantly removed logic
    from the setter methods.
  2. @tenderlove

    pull internal initialization to a function

    tenderlove authored
    Gem::Specification knows that it will be setting loaded_from to be
    `nil`.  This commit avoids that nil check and just sets ivars
  3. @tenderlove
  4. @tenderlove

    Merge pull request #1202 from mfazekas/test-and-fix-find_in_unresolve…

    tenderlove authored
    Fixes for find_in_unresolved_tree
  5. @hsbt
Commits on Mar 26, 2015
  1. @segiddins
Commits on Mar 23, 2015
  1. @mfazekas

    Added a new implementation of find_in_unresolved_tree

    mfazekas authored
    Bugs fixed in original one:
    - next was not skipping rest of walk, so now returns :next so caller knows there is a conflict so no need to walk this branch
    - we prevent visiting the same spec twice, using visited set. While this means we dont process all paths processing all path is exponential and we dont want that
    - we do walk in a greedy way taking the latest versions of specs first and we return as soon as we find something rather than processing all paths and soring it to return the latest (also original was used wrong number of reserve so it did not actually returned the latest)
    - we need to check conflict in all the to be activated gems and not only in the last elem of the path(trail)
    find_in_unresolved is called when we have some gems already activated and the required file is not found in any of them. It has the following requirements:
    - should prefer gems in direct/indirect dependencies (vs gems outside the dependency tree)
    - should prefer latest versions
    - should avoid conflicts but we also want it to be performant
Something went wrong with that request. Please try again.