repo
stringlengths
5
92
file_url
stringlengths
80
287
file_path
stringlengths
5
197
content
stringlengths
0
32.8k
language
stringclasses
1 value
license
stringclasses
7 values
commit_sha
stringlengths
40
40
retrieved_at
stringdate
2026-01-04 15:37:27
2026-01-04 17:58:21
truncated
bool
2 classes
phacks/notion-ruby-client
https://github.com/phacks/notion-ruby-client/blob/f651b70b665358f9001489c1a06325eb70ec3f64/lib/notion/faraday/request.rb
lib/notion/faraday/request.rb
# frozen_string_literal: true module Notion module Faraday module Request def get(path, options = {}) request(:get, path, options) end def patch(path, options = {}) request(:patch, path, options) end def post(path, options = {}) request(:post, path, options)...
ruby
MIT
f651b70b665358f9001489c1a06325eb70ec3f64
2026-01-04T17:51:29.828973Z
false
phacks/notion-ruby-client
https://github.com/phacks/notion-ruby-client/blob/f651b70b665358f9001489c1a06325eb70ec3f64/lib/notion/faraday/response/raise_error.rb
lib/notion/faraday/response/raise_error.rb
# frozen_string_literal: true module Notion module Faraday module Response class RaiseError < ::Faraday::Response::Json def on_complete(env) raise Notion::Api::Errors::TooManyRequests, env.response if env.status == 429 return if env.success? body = env.body ...
ruby
MIT
f651b70b665358f9001489c1a06325eb70ec3f64
2026-01-04T17:51:29.828973Z
false
phacks/notion-ruby-client
https://github.com/phacks/notion-ruby-client/blob/f651b70b665358f9001489c1a06325eb70ec3f64/lib/notion/faraday/response/wrap_error.rb
lib/notion/faraday/response/wrap_error.rb
# frozen_string_literal: true module Notion module Faraday module Response class WrapError < ::Faraday::Response::Json UNAVAILABLE_ERROR_STATUSES = (500..599).freeze def on_complete(env) return unless UNAVAILABLE_ERROR_STATUSES.cover?(env.status) raise Notion::Api::Erro...
ruby
MIT
f651b70b665358f9001489c1a06325eb70ec3f64
2026-01-04T17:51:29.828973Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/rails_helper.rb
spec/rails_helper.rb
ENV["RAILS_ENV"] ||= 'test' require 'spec_helper' require File.expand_path("../dummy/config/environment", __FILE__) require 'rspec/rails' Dir[Rails.root.join("spec/support/**/*.rb")].each {|f| require f} RSpec.configure do |config| config.infer_base_class_for_anonymous_controllers = false config.infer_spec_type_f...
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/spec_helper.rb
spec/spec_helper.rb
RSpec.configure do |config| config.expect_with(:rspec) do |c| c.syntax = :should end end
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/support/patch.rb
spec/support/patch.rb
# Rails 4.2 call `initialize` inside `recycle!`. However Ruby 2.6 doesn't allow calling `initialize` twice. # See for detail: https://github.com/rails/rails/issues/34790 if RUBY_VERSION.to_f >= 2.6 && Rails::VERSION::MAJOR == 4 class ActionController::TestResponse prepend Module.new { def recycle! @...
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/controllers/examples_controller_spec.rb
spec/controllers/examples_controller_spec.rb
require "rails_helper" describe ExamplesController do describe "#index" do context "when render as HTML" do subject do get :index end context "when RenderWithPathComment is not attached" do before do ViewSourceMap.detach end it "does not show partial ...
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/dummy/app/helpers/application_helper.rb
spec/dummy/app/helpers/application_helper.rb
module ApplicationHelper end
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/dummy/app/controllers/examples_controller.rb
spec/dummy/app/controllers/examples_controller.rb
class ExamplesController < ApplicationController protect_from_forgery def index end end
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/dummy/app/controllers/application_controller.rb
spec/dummy/app/controllers/application_controller.rb
class ApplicationController < ActionController::Base protect_from_forgery end
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/dummy/config/application.rb
spec/dummy/config/application.rb
require File.expand_path('../boot', __FILE__) # Pick the frameworks you want: # require "active_record/railtie" require "action_controller/railtie" require "action_mailer/railtie" require "sprockets/railtie" # require "rails/test_unit/railtie" Bundler.require require "view_source_map" module Dummy class Applicatio...
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/dummy/config/environment.rb
spec/dummy/config/environment.rb
# Load the rails application require File.expand_path('../application', __FILE__) # Initialize the rails application Dummy::Application.initialize!
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/dummy/config/routes.rb
spec/dummy/config/routes.rb
Dummy::Application.routes.draw do resources :examples, :only => :index end
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/dummy/config/boot.rb
spec/dummy/config/boot.rb
require 'rubygems' gemfile = File.expand_path('../../../../Gemfile', __FILE__) if File.exist?(gemfile) ENV['BUNDLE_GEMFILE'] = gemfile require 'bundler' Bundler.setup end $:.unshift File.expand_path('../../../../lib', __FILE__)
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/dummy/config/initializers/session_store.rb
spec/dummy/config/initializers/session_store.rb
# Be sure to restart your server when you modify this file. Dummy::Application.config.session_store :cookie_store, :key => '_dummy_session' # Use the database for sessions instead of the cookie-based default, # which shouldn't be used to store highly confidential information # (create the session table with "rails ge...
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/dummy/config/initializers/wrap_parameters.rb
spec/dummy/config/initializers/wrap_parameters.rb
# Be sure to restart your server when you modify this file. # # This file contains settings for ActionController::ParamsWrapper which # is enabled by default. # Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array. ActiveSupport.on_load(:action_controller) do wrap_parameters ...
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/dummy/config/initializers/inflections.rb
spec/dummy/config/initializers/inflections.rb
# Be sure to restart your server when you modify this file. # Add new inflection rules using the following format # (all these examples are active by default): # ActiveSupport::Inflector.inflections do |inflect| # inflect.plural /^(ox)$/i, '\1en' # inflect.singular /^(ox)en/i, '\1' # inflect.irregular 'person', ...
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/dummy/config/initializers/backtrace_silencers.rb
spec/dummy/config/initializers/backtrace_silencers.rb
# Be sure to restart your server when you modify this file. # You can add backtrace silencers for libraries that you're using but don't wish to see in your backtraces. # Rails.backtrace_cleaner.add_silencer { |line| line =~ /my_noisy_library/ } # You can also remove all the silencers if you're trying to debug a probl...
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/dummy/config/initializers/mime_types.rb
spec/dummy/config/initializers/mime_types.rb
# Be sure to restart your server when you modify this file. # Add new mime types for use in respond_to blocks: # Mime::Type.register "text/richtext", :rtf # Mime::Type.register_alias "text/html", :iphone
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/dummy/config/initializers/secret_token.rb
spec/dummy/config/initializers/secret_token.rb
# Be sure to restart your server when you modify this file. # Your secret key for verifying the integrity of signed cookies. # If you change this key, all old signed cookies will become invalid! # Make sure the secret is at least 30 characters and all random, # no regular words or you'll be exposed to dictionary attac...
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/dummy/config/environments/test.rb
spec/dummy/config/environments/test.rb
Dummy::Application.configure do # Settings specified here will take precedence over those in config/application.rb # The test environment is used exclusively to run your application's # test suite. You never need to work with it otherwise. Remember that # your test database is "scratch space" for the test suit...
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/dummy/config/environments/development.rb
spec/dummy/config/environments/development.rb
Dummy::Application.configure do # Settings specified here will take precedence over those in config/application.rb # In the development environment your application's code is reloaded on # every request. This slows down response time but is perfect for development # since you don't have to restart the web serv...
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/spec/dummy/config/environments/production.rb
spec/dummy/config/environments/production.rb
Dummy::Application.configure do # Settings specified here will take precedence over those in config/application.rb # Code is not reloaded between requests config.cache_classes = true # Full error reports are disabled and caching is turned on config.consider_all_requests_local = false config.action_c...
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/lib/view_source_map_rails_6_0.rb
lib/view_source_map_rails_6_0.rb
module ViewSourceMap def self.attach return if defined?(@attached) && @attached @attached = true ActionView::PartialRenderer.class_eval do def render_with_path_comment(context, options, block) content = render_without_path_comment(context, options, block) return content if ViewSourc...
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/lib/view_source_map_rails_4_and_5.rb
lib/view_source_map_rails_4_and_5.rb
module ViewSourceMap def self.attach return if defined?(@attached) && @attached @attached = true ActionView::PartialRenderer.class_eval do def render_with_path_comment(context, options, block) content = render_without_path_comment(context, options, block) return content if ViewSourc...
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/lib/view_source_map.rb
lib/view_source_map.rb
require 'view_source_map/railtie' if Rails.gem_version >= Gem::Version.new('6.1') require 'view_source_map_rails_6' elsif Rails.gem_version >= Gem::Version.new('6.0') require 'view_source_map_rails_6_0' else require 'view_source_map_rails_4_and_5' end module ViewSourceMap def self.detach return unless @at...
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/lib/view_source_map_rails_6.rb
lib/view_source_map_rails_6.rb
module ViewSourceMap def self.attach return if defined?(@attached) && @attached @attached = true ActionView::PartialRenderer.class_eval do def render_with_path_comment(partial, context, block) content = render_without_path_comment(partial, context, block) return content if ViewSourc...
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/lib/view_source_map/version.rb
lib/view_source_map/version.rb
module ViewSourceMap VERSION = "0.3.0" end
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
r7kamura/view_source_map
https://github.com/r7kamura/view_source_map/blob/75b99802cdc2efc4481967dc0e484c45d865b3b1/lib/view_source_map/railtie.rb
lib/view_source_map/railtie.rb
module ViewSourceMap class Railtie < Rails::Railtie initializer "render_with_path_comment.initialize" do if !ENV["DISABLE_VIEW_SOURCE_MAP"] && Rails.env.development? ViewSourceMap.attach end end end end
ruby
MIT
75b99802cdc2efc4481967dc0e484c45d865b3b1
2026-01-04T17:51:33.791483Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/spec_helper.rb
spec/spec_helper.rb
ENV["RAILS_ENV"] = "test" ENV["DB"] ||= "sqlite3" require 'rails' require "pagy_cursor" require "dummy/config/environment" ActiveRecord::Migration.verbose = false ActiveRecord::Tasks::DatabaseTasks.drop_current 'test' ActiveRecord::Tasks::DatabaseTasks.create_current 'test' ActiveRecord::Migration.maintain_test_schema...
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/app/jobs/application_job.rb
spec/dummy/app/jobs/application_job.rb
class ApplicationJob < ActiveJob::Base end
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/app/helpers/application_helper.rb
spec/dummy/app/helpers/application_helper.rb
module ApplicationHelper end
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/app/controllers/application_controller.rb
spec/dummy/app/controllers/application_controller.rb
class ApplicationController < ActionController::Base end
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/app/models/post.rb
spec/dummy/app/models/post.rb
class Post < ApplicationRecord before_create :set_uuid # for test with uuid def set_uuid self.id = SecureRandom.uuid end end
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/app/models/application_record.rb
spec/dummy/app/models/application_record.rb
class ApplicationRecord < ActiveRecord::Base self.abstract_class = true end
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/app/models/user.rb
spec/dummy/app/models/user.rb
class User < ApplicationRecord end
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/app/mailers/application_mailer.rb
spec/dummy/app/mailers/application_mailer.rb
class ApplicationMailer < ActionMailer::Base default from: 'from@example.com' layout 'mailer' end
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/app/channels/application_cable/channel.rb
spec/dummy/app/channels/application_cable/channel.rb
module ApplicationCable class Channel < ActionCable::Channel::Base end end
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/app/channels/application_cable/connection.rb
spec/dummy/app/channels/application_cable/connection.rb
module ApplicationCable class Connection < ActionCable::Connection::Base end end
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/db/schema.rb
spec/dummy/db/schema.rb
# encoding: UTF-8 # frozen_string_literal: true # This file is auto-generated from the current state of the database. Instead # of editing this file, please use the migrations feature of Active Record to # incrementally modify your database, and then regenerate this schema definition. # # Note that this schema.rb defi...
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/db/migrate/20190307102949_create_tables.rb
spec/dummy/db/migrate/20190307102949_create_tables.rb
class CreateTables < ActiveRecord::Migration[5.0] def self.up create_table(:users) do |t| t.string :name t.timestamps end create_table(:posts, id: false) do |t| t.string :id, limit: 36, primary_key: true, null: false t.string :title t.timestamps end end def self.do...
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/config/application.rb
spec/dummy/config/application.rb
require_relative 'boot' require 'rails/all' Bundler.require(*Rails.groups) require "pagy_cursor" module Dummy class Application < Rails::Application # Settings in config/environments/* take precedence over those specified here. # Application configuration can go into files in config/initializers # -- a...
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/config/environment.rb
spec/dummy/config/environment.rb
# Load the Rails application. require_relative 'application' # Initialize the Rails application. Rails.application.initialize!
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/config/puma.rb
spec/dummy/config/puma.rb
# Puma can serve each request in a thread from an internal thread pool. # The `threads` method setting takes two numbers: a minimum and maximum. # Any libraries that use thread pools should be configured to match # the maximum value specified for Puma. Default is set to 5 threads for minimum # and maximum; this matches...
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/config/routes.rb
spec/dummy/config/routes.rb
Rails.application.routes.draw do # For details on the DSL available within this file, see http://guides.rubyonrails.org/routing.html end
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/config/spring.rb
spec/dummy/config/spring.rb
%w[ .ruby-version .rbenv-vars tmp/restart.txt tmp/caching-dev.txt ].each { |path| Spring.watch(path) }
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/config/boot.rb
spec/dummy/config/boot.rb
# Set up gems listed in the Gemfile. ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../../Gemfile', __dir__) require 'bundler/setup' if File.exist?(ENV['BUNDLE_GEMFILE']) $LOAD_PATH.unshift File.expand_path('../../../lib', __dir__)
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/config/initializers/content_security_policy.rb
spec/dummy/config/initializers/content_security_policy.rb
# Be sure to restart your server when you modify this file. # Define an application-wide content security policy # For further information see the following documentation # https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy # Rails.application.config.content_security_policy do |policy| ...
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/config/initializers/filter_parameter_logging.rb
spec/dummy/config/initializers/filter_parameter_logging.rb
# Be sure to restart your server when you modify this file. # Configure sensitive parameters which will be filtered from the log file. Rails.application.config.filter_parameters += [:password]
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/config/initializers/application_controller_renderer.rb
spec/dummy/config/initializers/application_controller_renderer.rb
# Be sure to restart your server when you modify this file. # ActiveSupport::Reloader.to_prepare do # ApplicationController.renderer.defaults.merge!( # http_host: 'example.org', # https: false # ) # end
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/config/initializers/wrap_parameters.rb
spec/dummy/config/initializers/wrap_parameters.rb
# Be sure to restart your server when you modify this file. # This file contains settings for ActionController::ParamsWrapper which # is enabled by default. # Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array. ActiveSupport.on_load(:action_controller) do wrap_parameters f...
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/config/initializers/inflections.rb
spec/dummy/config/initializers/inflections.rb
# Be sure to restart your server when you modify this file. # Add new inflection rules using the following format. Inflections # are locale specific, and you may define rules for as many different # locales as you wish. All of these examples are active by default: # ActiveSupport::Inflector.inflections(:en) do |inflec...
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/config/initializers/cookies_serializer.rb
spec/dummy/config/initializers/cookies_serializer.rb
# Be sure to restart your server when you modify this file. # Specify a serializer for the signed and encrypted cookie jars. # Valid options are :json, :marshal, and :hybrid. Rails.application.config.action_dispatch.cookies_serializer = :json
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/config/initializers/backtrace_silencers.rb
spec/dummy/config/initializers/backtrace_silencers.rb
# Be sure to restart your server when you modify this file. # You can add backtrace silencers for libraries that you're using but don't wish to see in your backtraces. # Rails.backtrace_cleaner.add_silencer { |line| line =~ /my_noisy_library/ } # You can also remove all the silencers if you're trying to debug a probl...
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/config/initializers/mime_types.rb
spec/dummy/config/initializers/mime_types.rb
# Be sure to restart your server when you modify this file. # Add new mime types for use in respond_to blocks: # Mime::Type.register "text/richtext", :rtf
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/config/environments/test.rb
spec/dummy/config/environments/test.rb
Rails.application.configure do # Settings specified here will take precedence over those in config/application.rb. # The test environment is used exclusively to run your application's # test suite. You never need to work with it otherwise. Remember that # your test database is "scratch space" for the test suit...
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/config/environments/development.rb
spec/dummy/config/environments/development.rb
Rails.application.configure do # Settings specified here will take precedence over those in config/application.rb. # In the development environment your application's code is reloaded on # every request. This slows down response time but is perfect for development # since you don't have to restart the web serv...
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/dummy/config/environments/production.rb
spec/dummy/config/environments/production.rb
Rails.application.configure do # Settings specified here will take precedence over those in config/application.rb. # Code is not reloaded between requests. config.cache_classes = true # Eager load code on boot. This eager loads most of Rails and # your application in memory, allowing both threaded web serve...
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/pagy_cursor/cursor_spec.rb
spec/pagy_cursor/cursor_spec.rb
require "spec_helper" require "pagy_cursor/pagy/extras/cursor" RSpec.describe Pagy::Backend do let(:backend) { TestController.new } context 'no records' do it 'returns an empty collection' do pagy, records = backend.send(:pagy_cursor, User.all) expect(records).to be_empty expect(pagy.has_mo...
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/spec/pagy_cursor/uuid_cursor_spec.rb
spec/pagy_cursor/uuid_cursor_spec.rb
require "spec_helper" require "pagy_cursor/pagy/extras/uuid_cursor" RSpec.describe PagyCursor do let(:backend) { TestController.new } context 'no records' do it 'returns an empty collection' do pagy, records = backend.send(:pagy_uuid_cursor, Post.all) expect(records).to be_empty expect(pagy....
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/lib/pagy_cursor.rb
lib/pagy_cursor.rb
# frozen_string_literal: true require "pagy" require "pagy_cursor/pagy/cursor" require "pagy_cursor/pagy/extras/cursor" require "pagy_cursor/pagy/extras/uuid_cursor" require "pagy_cursor/version" module PagyCursor end
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/lib/pagy_cursor/version.rb
lib/pagy_cursor/version.rb
# frozen_string_literal: true module PagyCursor VERSION = "0.8.0" end
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/lib/pagy_cursor/pagy/cursor.rb
lib/pagy_cursor/pagy/cursor.rb
# frozen_string_literal: true class Pagy class Cursor < Pagy attr_reader :before, :after, :arel_table, :primary_key, :order, :comparison, :position attr_accessor :has_more alias_method :has_more?, :has_more def initialize(vars) @vars = DEFAULT.merge(vars.delete_if { |_, v| v.nil? || v == "" })...
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/lib/pagy_cursor/pagy/extras/cursor.rb
lib/pagy_cursor/pagy/extras/cursor.rb
# frozen_string_literal: true class Pagy module Backend; private # the whole module is private so no problem with including it in a controller # Return Pagy object and items def pagy_cursor(collection, vars = {}) pagy = Pagy::Cursor.new(pagy_cursor_get_vars(collection, vars)) items = pagy_cursor...
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
Uysim/pagy-cursor
https://github.com/Uysim/pagy-cursor/blob/104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a/lib/pagy_cursor/pagy/extras/uuid_cursor.rb
lib/pagy_cursor/pagy/extras/uuid_cursor.rb
# frozen_string_literal: true class Pagy module Backend; private # the whole module is private so no problem with including it in a controller # Return Pagy object and items def pagy_uuid_cursor(collection, vars = {}) pagy = Pagy::Cursor.new(pagy_uuid_cursor_get_vars(collection, vars)) items = pa...
ruby
MIT
104c9cb2a15ac5e9cdd75e8ac276173a998d5a7a
2026-01-04T17:51:32.347526Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/spec/endpoint_spec.rb
spec/endpoint_spec.rb
# frozen_string_literal: true require_relative 'spec_helper' describe 'Dalli::Elasticache::AutoDiscovery::Endpoint' do let(:endpoint) do Dalli::Elasticache::AutoDiscovery::Endpoint.new(arg_string) end describe '.new' do context 'when the string includes both host and port' do let(:arg_string) { '...
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/spec/stats_response_spec.rb
spec/stats_response_spec.rb
# frozen_string_literal: true require_relative 'spec_helper' describe 'Dalli::Elasticache::AutoDiscovery::StatsResponse' do let(:response) { Dalli::Elasticache::AutoDiscovery::StatsResponse.new(response_text) } describe '#engine_version' do context 'when the version number is a number' do let(:engine_v...
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/spec/config_command_spec.rb
spec/config_command_spec.rb
# frozen_string_literal: true require_relative 'spec_helper' describe 'Dalli::Elasticache::AutoDiscovery::ConfigCommand' do let(:host) { Faker::Internet.domain_name(subdomain: true) } let(:port) { rand(1024..16_023) } let(:command) { Dalli::Elasticache::AutoDiscovery::ConfigCommand.new(host, port, engine_versio...
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/spec/stats_command_spec.rb
spec/stats_command_spec.rb
# frozen_string_literal: true require_relative 'spec_helper' describe 'Dalli::Elasticache::AutoDiscovery::StatsCommand' do let(:host) { 'example.com' } let(:port) { 12_345 } let(:command) { Dalli::Elasticache::AutoDiscovery::StatsCommand.new(host, port) } let(:engine_version) { ['1.4.5', '1.4.14', '1.5.6', '1...
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/spec/config_response_spec.rb
spec/config_response_spec.rb
# frozen_string_literal: true require_relative 'spec_helper' describe 'Dalli::Elasticache::AutoDiscovery::ConfigResponse' do let :response do text = "CONFIG cluster 0 141\r\n12\nmycluster.0001.cache.amazonaws.com|10.112.21.1|11211 " \ 'mycluster.0002.cache.amazonaws.com|10.112.21.2|11211 ' \ ...
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/spec/elasticache_spec.rb
spec/elasticache_spec.rb
# frozen_string_literal: true require_relative 'spec_helper' describe 'Dalli::ElastiCache::Endpoint' do let(:dalli_options) do { expires_in: 24 * 60 * 60, namespace: 'my_app', compress: true } end let(:host) { 'my-cluster.cfg.use1.cache.amazonaws.com' } let(:port) { 11_211 } let(:...
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/spec/spec_helper.rb
spec/spec_helper.rb
# frozen_string_literal: true require 'bundler/setup' require 'dalli/elasticache' require 'securerandom' require 'faker' RSpec.configure
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/spec/node_spec.rb
spec/node_spec.rb
# frozen_string_literal: true require_relative 'spec_helper' describe 'Dalli::Elasticache::AutoDiscovery::Node' do context 'when comparing with equals' do let(:host1) { Faker::Internet.domain_name(subdomain: true) } let(:ip1) { Faker::Internet.public_ip_v4_address } let(:port1) { rand(1024..16_023) } ...
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/lib/dalli-elasticache.rb
lib/dalli-elasticache.rb
# frozen_string_literal: true # Support default bundler require path require_relative 'dalli/elasticache'
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/lib/dalli/elasticache.rb
lib/dalli/elasticache.rb
# frozen_string_literal: true require 'dalli' require 'socket' require_relative 'elasticache/version' require_relative 'elasticache/auto_discovery/endpoint' require_relative 'elasticache/auto_discovery/base_command' require_relative 'elasticache/auto_discovery/node' require_relative 'elasticache/auto_discovery/config_...
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/lib/dalli/elasticache/version.rb
lib/dalli/elasticache/version.rb
# frozen_string_literal: true module Dalli class ElastiCache VERSION = '1.0.1' end end
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/lib/dalli/elasticache/auto_discovery/base_command.rb
lib/dalli/elasticache/auto_discovery/base_command.rb
# frozen_string_literal: true module Dalli module Elasticache module AutoDiscovery ## # Base command class for configuration endpoint # command. Contains the network logic. ## class BaseCommand attr_reader :host, :port def initialize(host, port) @host = h...
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/lib/dalli/elasticache/auto_discovery/node.rb
lib/dalli/elasticache/auto_discovery/node.rb
# frozen_string_literal: true module Dalli module Elasticache module AutoDiscovery ## # Represents a single memcached node in the # cluster. ## class Node attr_reader :host, :ip, :port def initialize(host, ip, port) @host = host @ip = ip ...
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/lib/dalli/elasticache/auto_discovery/config_response.rb
lib/dalli/elasticache/auto_discovery/config_response.rb
# frozen_string_literal: true module Dalli module Elasticache module AutoDiscovery # This class wraps the raw ASCII response from an Auto Discovery endpoint # and provides methods for extracting data from that response. # # http://docs.aws.amazon.com/AmazonElastiCache/latest/UserGuide/Aut...
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/lib/dalli/elasticache/auto_discovery/stats_command.rb
lib/dalli/elasticache/auto_discovery/stats_command.rb
# frozen_string_literal: true module Dalli module Elasticache module AutoDiscovery ## # Encapsulates execution of the 'stats' command, which is used to # extract the engine_version ## class StatsCommand < BaseCommand STATS_COMMAND = "stats\r\n" def response ...
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/lib/dalli/elasticache/auto_discovery/config_command.rb
lib/dalli/elasticache/auto_discovery/config_command.rb
# frozen_string_literal: true module Dalli module Elasticache module AutoDiscovery ## # Encapsulates execution of the 'config' command, which is used to # extract the list of nodes and determine if that list of nodes has changed. ## class ConfigCommand < BaseCommand attr_rea...
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/lib/dalli/elasticache/auto_discovery/endpoint.rb
lib/dalli/elasticache/auto_discovery/endpoint.rb
# frozen_string_literal: true module Dalli module Elasticache module AutoDiscovery ## # This is a representation of the configuration endpoint for # a memcached cluster. It encapsulates information returned from # that endpoint. ## class Endpoint # Endpoint configurat...
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
ktheory/dalli-elasticache
https://github.com/ktheory/dalli-elasticache/blob/100fe160eca65a4fa9f81ce607b4190b1f73687c/lib/dalli/elasticache/auto_discovery/stats_response.rb
lib/dalli/elasticache/auto_discovery/stats_response.rb
# frozen_string_literal: true module Dalli module Elasticache module AutoDiscovery # This class wraps the raw ASCII response from a stats call to an # Auto Discovery endpoint and provides methods for extracting data # from that response. # # http://docs.aws.amazon.com/AmazonElastiCa...
ruby
MIT
100fe160eca65a4fa9f81ce607b4190b1f73687c
2026-01-04T17:51:34.942242Z
false
tmiyamon/acts-as-taggable-array-on
https://github.com/tmiyamon/acts-as-taggable-array-on/blob/16078cd5b8d2db60f64bbfc443d773879fe10e4f/spec_helper.rb
spec_helper.rb
require "rubygems" RSpec::Matchers.define :my_matcher do |expected| match do |actual| true end end
ruby
MIT
16078cd5b8d2db60f64bbfc443d773879fe10e4f
2026-01-04T17:51:37.298787Z
false
tmiyamon/acts-as-taggable-array-on
https://github.com/tmiyamon/acts-as-taggable-array-on/blob/16078cd5b8d2db60f64bbfc443d773879fe10e4f/spec/spec_helper.rb
spec/spec_helper.rb
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), "..", "lib")) $LOAD_PATH.unshift(File.dirname(__FILE__)) require "rspec" require "active_record/railtie" ActiveRecord::Base.logger = Logger.new(STDERR) ActiveRecord::Base.logger.level = 3 require "acts-as-taggable-array-on" # Dir["#{File.dirname(__FILE__)}/support/...
ruby
MIT
16078cd5b8d2db60f64bbfc443d773879fe10e4f
2026-01-04T17:51:37.298787Z
false
tmiyamon/acts-as-taggable-array-on
https://github.com/tmiyamon/acts-as-taggable-array-on/blob/16078cd5b8d2db60f64bbfc443d773879fe10e4f/spec/acts_as_tag_pgarray/taggable_spec.rb
spec/acts_as_tag_pgarray/taggable_spec.rb
require "spec_helper" describe ActsAsTaggableArrayOn::Taggable do before do @user1 = User.create name: "Tom", colors: ["red", "blue"], sizes: ["medium", "large"], codes: [456, 789], roles: ["user"], references: ["308f35c6-f819-4faa-9bba-2457de1dde25"] @user2 = User.create name: "Ken", colors: ["black", "whit...
ruby
MIT
16078cd5b8d2db60f64bbfc443d773879fe10e4f
2026-01-04T17:51:37.298787Z
false
tmiyamon/acts-as-taggable-array-on
https://github.com/tmiyamon/acts-as-taggable-array-on/blob/16078cd5b8d2db60f64bbfc443d773879fe10e4f/spec/acts_as_tag_pgarray/parser_spec.rb
spec/acts_as_tag_pgarray/parser_spec.rb
require "spec_helper" describe ActsAsTaggableArrayOn::Parser do let(:parser) { ActsAsTaggableArrayOn.parser } describe "#parse" do it "return unprocessed tags if array" do tags = %w[red green] expect(parser.parse(tags)).to eq tags end it "return parsed tags if comma separated string" do ...
ruby
MIT
16078cd5b8d2db60f64bbfc443d773879fe10e4f
2026-01-04T17:51:37.298787Z
false
tmiyamon/acts-as-taggable-array-on
https://github.com/tmiyamon/acts-as-taggable-array-on/blob/16078cd5b8d2db60f64bbfc443d773879fe10e4f/lib/acts-as-taggable-array-on.rb
lib/acts-as-taggable-array-on.rb
require "active_record" require "acts-as-taggable-array-on/version" require "acts-as-taggable-array-on/taggable" require "acts-as-taggable-array-on/parser" ActiveSupport.on_load(:active_record) do include ActsAsTaggableArrayOn::Taggable end
ruby
MIT
16078cd5b8d2db60f64bbfc443d773879fe10e4f
2026-01-04T17:51:37.298787Z
false
tmiyamon/acts-as-taggable-array-on
https://github.com/tmiyamon/acts-as-taggable-array-on/blob/16078cd5b8d2db60f64bbfc443d773879fe10e4f/lib/acts-as-taggable-array-on/version.rb
lib/acts-as-taggable-array-on/version.rb
module ActsAsTagPgarray VERSION = "0.7.0" end
ruby
MIT
16078cd5b8d2db60f64bbfc443d773879fe10e4f
2026-01-04T17:51:37.298787Z
false
tmiyamon/acts-as-taggable-array-on
https://github.com/tmiyamon/acts-as-taggable-array-on/blob/16078cd5b8d2db60f64bbfc443d773879fe10e4f/lib/acts-as-taggable-array-on/parser.rb
lib/acts-as-taggable-array-on/parser.rb
# frozen_string_literal: true module ActsAsTaggableArrayOn class Parser def parse tags case tags when String tags.split(/ *, */) else tags end end end def self.parser @parser ||= Parser.new end end
ruby
MIT
16078cd5b8d2db60f64bbfc443d773879fe10e4f
2026-01-04T17:51:37.298787Z
false
tmiyamon/acts-as-taggable-array-on
https://github.com/tmiyamon/acts-as-taggable-array-on/blob/16078cd5b8d2db60f64bbfc443d773879fe10e4f/lib/acts-as-taggable-array-on/taggable.rb
lib/acts-as-taggable-array-on/taggable.rb
# frozen_string_literal: true module ActsAsTaggableArrayOn module Taggable def self.included(base) base.extend(ClassMethod) end TYPE_MATCHER = {string: "varchar", text: "text", integer: "integer", citext: "citext", uuid: "uuid"} module ClassMethod def acts_as_taggable_array_on(tag_name,...
ruby
MIT
16078cd5b8d2db60f64bbfc443d773879fe10e4f
2026-01-04T17:51:37.298787Z
false
papertrail/remote_syslog_logger
https://github.com/papertrail/remote_syslog_logger/blob/506bba071f09082106aacd6d3cc3e17423d99dac/test/test_remote_syslog_logger.rb
test/test_remote_syslog_logger.rb
require File.expand_path('../helper', __FILE__) class TestRemoteSyslogLogger < Test::Unit::TestCase def setup @server_port = rand(50000) + 1024 @socket = UDPSocket.new @socket.bind('127.0.0.1', @server_port) end def test_logger @logger = RemoteSyslogLogger.new('127.0.0.1', @server_port) @l...
ruby
MIT
506bba071f09082106aacd6d3cc3e17423d99dac
2026-01-04T17:51:42.772724Z
false
papertrail/remote_syslog_logger
https://github.com/papertrail/remote_syslog_logger/blob/506bba071f09082106aacd6d3cc3e17423d99dac/test/helper.rb
test/helper.rb
$:.unshift File.expand_path('../../lib', __FILE__) unless ENV['BUNDLE_GEMFILE'] require 'rubygems' require 'bundler' Bundler.setup Bundler.require end require 'remote_syslog_logger' require 'test/unit'
ruby
MIT
506bba071f09082106aacd6d3cc3e17423d99dac
2026-01-04T17:51:42.772724Z
false
papertrail/remote_syslog_logger
https://github.com/papertrail/remote_syslog_logger/blob/506bba071f09082106aacd6d3cc3e17423d99dac/lib/remote_syslog_logger.rb
lib/remote_syslog_logger.rb
require 'remote_syslog_logger/udp_sender' require 'logger' module RemoteSyslogLogger VERSION = '1.0.4' def self.new(remote_hostname, remote_port, options = {}) Logger.new(RemoteSyslogLogger::UdpSender.new(remote_hostname, remote_port, options)) end end
ruby
MIT
506bba071f09082106aacd6d3cc3e17423d99dac
2026-01-04T17:51:42.772724Z
false
papertrail/remote_syslog_logger
https://github.com/papertrail/remote_syslog_logger/blob/506bba071f09082106aacd6d3cc3e17423d99dac/lib/remote_syslog_logger/udp_sender.rb
lib/remote_syslog_logger/udp_sender.rb
require 'socket' require 'syslog_protocol' module RemoteSyslogLogger class UdpSender def initialize(remote_hostname, remote_port, options = {}) @remote_hostname = remote_hostname @remote_port = remote_port @whinyerrors = options[:whinyerrors] @max_size = options[:max_size] ...
ruby
MIT
506bba071f09082106aacd6d3cc3e17423d99dac
2026-01-04T17:51:42.772724Z
false
grubby/grubby
https://github.com/grubby/grubby/blob/e582a835a585db590ca5df80aca3d5f1cbd1e774/lib/tk.rb
lib/tk.rb
# # tk.rb - Tk interface module using tcltklib # by Yukihiro Matsumoto <matz@netlab.jp> # use Shigehiro's tcltklib require 'tcltklib' require 'tkutil' # autoload require 'tk/autoload' # for Mutex require 'thread' class TclTkIp # backup original (without encoding) _eval and _inv...
ruby
MIT
e582a835a585db590ca5df80aca3d5f1cbd1e774
2026-01-04T17:51:36.659653Z
true
grubby/grubby
https://github.com/grubby/grubby/blob/e582a835a585db590ca5df80aca3d5f1cbd1e774/lib/abbrev.rb
lib/abbrev.rb
#!/usr/bin/env ruby #-- # Copyright (c) 2001,2003 Akinori MUSHA <knu@iDaemons.org> # # All rights reserved. You can redistribute and/or modify it under # the same terms as Ruby. # # $Idaemons: /home/cvs/rb/abbrev.rb,v 1.2 2001/05/30 09:37:45 knu Exp $ # $RoughId: abbrev.rb,v 1.4 2003/10/14 19:45:42 knu Exp $ # $Id: ab...
ruby
MIT
e582a835a585db590ca5df80aca3d5f1cbd1e774
2026-01-04T17:51:36.659653Z
false
grubby/grubby
https://github.com/grubby/grubby/blob/e582a835a585db590ca5df80aca3d5f1cbd1e774/lib/find.rb
lib/find.rb
# # find.rb: the Find module for processing all files under a given directory. # # # The +Find+ module supports the top-down traversal of a set of file paths. # # For example, to total the size of all files under your home directory, # ignoring anything in a "dot" directory (e.g. $HOME/.ssh): # # require 'find' # # ...
ruby
MIT
e582a835a585db590ca5df80aca3d5f1cbd1e774
2026-01-04T17:51:36.659653Z
false
grubby/grubby
https://github.com/grubby/grubby/blob/e582a835a585db590ca5df80aca3d5f1cbd1e774/lib/tsort.rb
lib/tsort.rb
#-- # tsort.rb - provides a module for topological sorting and strongly connected components. #++ # # # TSort implements topological sorting using Tarjan's algorithm for # strongly connected components. # # TSort is designed to be able to be used with any object which can be # interpreted as a directed graph. # # TSor...
ruby
MIT
e582a835a585db590ca5df80aca3d5f1cbd1e774
2026-01-04T17:51:36.659653Z
false
grubby/grubby
https://github.com/grubby/grubby/blob/e582a835a585db590ca5df80aca3d5f1cbd1e774/lib/multi-tk.rb
lib/multi-tk.rb
# # multi-tk.rb - supports multi Tk interpreters # by Hidetoshi NAGAI <nagai@ai.kyutech.ac.jp> require 'tcltklib' require 'tkutil' require 'thread' if defined? Tk fail RuntimeError,"'multi-tk' library must be required before requiring 'tk'" end ##################################...
ruby
MIT
e582a835a585db590ca5df80aca3d5f1cbd1e774
2026-01-04T17:51:36.659653Z
true