Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

gemcache

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gemcache

  • 0.1.1
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

GemCache

GemCache is a plugin for Rails that caches Ruby gems from any rubygems.org compatible host. It is built primarly to work with GemApi, which in turn is utilized by Gemstruct.

Installation

To use GemCache in your rails project, first:

bundle add gemcache

then:

rails g gemcache:install

Usage

class Gemfu
  include GemCache

  attr_reader :name, :requirements, :info_file, :stories, :versions, :version, :info, :quick_file, :gem_file

  def initialize(gem)
    @name = gem.name
    @requirements = gem.requirements_list

    @info_file = fetch_info
    @stories = InfoParser.parse(@info_file)
    @versions = SemVerParser.new(@stories, @requirements, @name)
    @version = @versions.available.first
    @info = InfoParser.info(@version, @stories)

    @quick_file = fetch_quick
    @gem_file = fetch_gem
  end
end

gem = Gem::Dependency.new("colorize", Gem::Requirement.new(["~> 1.0"]))
gemfu = Gemfu.new(gem)

File.binwrite("path/to/colorize.gem", gemfu.gem_file)

Contributing

Bug reports and pull requests are welcome on Github at https://github.com/pinecat/gemcache/issues and https://github.com/pinecat/gemcache/pulls, respectively.

License

The gem is available as open source under the terms of the BSD 3-Clause License.

FAQs

Package last updated on 24 Aug 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc