hexsha
stringlengths
40
40
size
int64
2
1.01M
content
stringlengths
2
1.01M
avg_line_length
float64
1.5
100
max_line_length
int64
2
1k
alphanum_fraction
float64
0.25
1
79590b144214135b18b1b8a1bdd6f3788cb8d911
1,002
class AtlassianCli < Formula desc "Command-line interface clients for Atlassian products" homepage "https://bobswift.atlassian.net/wiki/pages/viewpage.action?pageId=1966101" url "https://bobswift.atlassian.net/wiki/download/attachments/16285777/atlassian-cli-9.1.0-distribution.zip" sha256 "60c01f984a75b4e4071ec...
34.551724
110
0.700599
919e2c2f1408a503ee9f16e6411e0c6c5cbcafac
1,533
# # Copyright 2013-2014 Chef Software, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed ...
32.617021
76
0.734508
288a274598c063c91654171d315e58474aed2ef1
308
require 'rubygems' require 'simplecov' SimpleCov.start do add_filter "/spec/" end require 'rspec' require 'rspec/its' Dir[File.expand_path(File.join(File.dirname(__FILE__),'support','**','*.rb'))].each {|f| require f} require 'conjur/api' require 'conjur-asset-aws' require 'conjur-asset-host-factory'
19.25
99
0.727273
0342dc2c56f3e29c4003e89fe72b88bfd54dd158
7,193
module Aam class Annotation MAGIC_COMMENT_LINE = "# -*- coding: utf-8 -*-\n" attr_accessor :counts, :options def self.run(options = {}) new(options).run end def initialize(options = {}) @options = { :root_dir => Rails.root, :dry_run => false, :skip_columns =>...
31.138528
103
0.565133
39d8a987eadec44bca6ccad8741e95cff0cbe88d
330
class Subethaedit < Cask url 'http://www.codingmonkeys.de/subethaedit/SubEthaEdit.zip' appcast 'http://www.codingmonkeys.de/subethaedit/appcast.rss' homepage 'http://www.codingmonkeys.de/subethaedit/' version '3.5.4' sha256 '72d3948e5da167ac3113ec8f56aa424965b0ec153df4ba8042ce5893a547e290' link 'SubEthaEdit...
36.666667
75
0.793939
188f6cf6c4338a2c0c89fa9ce40bf02edcbce77d
336
# frozen_string_literal: false module SensuPluginsMeta # The version of this Sensu plugin. module Version # The major version. MAJOR = 1 # The minor version. MINOR = 0 # The patch version. PATCH = 10 # Concat them into a version string VER_STRING = [MAJOR, MINOR, PATCH].compact.join...
21
56
0.660714
6a2aeaabe978f45223975f904293488808e3c9c9
2,404
require 'rails_helper' RSpec.describe 'Participants::Devise::Sessions', type: :feature do let(:user) { create(:client) } describe 'reset password' do context 'with valid email' do it 'update password' do visit new_client_password_path(user) fill_in 'client_email', with: user.email ...
34.84058
97
0.682196
bb6196782d067aa944264d9cdf7299278fa71cf0
1,002
require_relative 'boot' require 'rails' require 'active_model/railtie' require 'active_job/railtie' require 'active_record/railtie' require 'action_controller/railtie' require 'action_mailer/railtie' require 'action_view/railtie' require 'sprockets/railtie' require 'rails/test_unit/railtie' # Require the gems listed ...
31.3125
79
0.772455
28b3658a681f006467c64acaa143cb4918fa8c96
1,485
# -*- encoding: utf-8 -*- # stub: jekyll-mentions 1.4.1 ruby lib Gem::Specification.new do |s| s.name = "jekyll-mentions".freeze s.version = "1.4.1" s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version= s.require_paths = ["lib".freeze] s.authors = ["G...
38.076923
112
0.670034
6a3fbea7d10ace58c6167f11287c38577f3bae5b
626
def solution(n, p, q) primes = Array.new(n + 1, 0) 2.upto(Math.sqrt(n)) do |i| next if primes[i] > 0 (i + i..n).step(i) do |j| next if primes[j] > 0 primes[j] = i end end semiprimes = Array.new(n + 1, 0) 2.upto(n) do |i| x = i while primes[x] > 0 x = x / primes[x] ...
20.193548
49
0.520767
915f84ceacdf6722f9e88d9d279481d72dc4a271
1,024
# frozen_string_literal: true require 'pry' require 'bundler/setup' require 'k_fileset' # require 'k_usecases' RSpec.configure do |config| # Enable flags like --only-failures and --next-failure config.example_status_persistence_file_path = '.rspec_status' config.filter_run_when_matching :focus # Disable RSpe...
24.380952
76
0.580078
1d86daff0be2dfea10e90a85b8351b40b15df65b
1,058
# frozen_string_literal: true module SolidusShipstation module Api class Client class << self def from_config new( request_runner: RequestRunner.from_config, error_handler: SolidusShipstation.config.error_handler, shipment_serializer: SolidusShipstation...
27.128205
83
0.660681
4a10f8e981b290de09e9f936c6b717c1c1fd1d0d
3,670
# $Id$ #Meterpreter script for running WMIC commands on Windows 2003, Windows Vista # and Windows XP and Windows 2008 targets. #Provided by Carlos Perez at carlos_perez[at]darkoperator[dot]com #Verion: 0.1 ################## Variable Declarations ################## session = client wininfo = client.sys.config.sysinfo #...
28.230769
137
0.66376
ed4d0bccfc1589886cfa5906c20929d6c740dc7e
175
class HomeController < ApplicationController skip_before_action :authenticate_user!, only: [:index] def index @photos = Photo.all @user = current_user end end
19.444444
56
0.731429
bb848be6e92634e8a8dc68b3f702fda239d3d40e
1,000
# typed: true class Mutations::Stores::DeleteStore < Mutations::BaseMutation description "Delete a game store. **Only available to moderators and admins using a first-party OAuth Application.**" argument :store_id, ID, required: true, description: 'The ID of the store to delete.' field :deleted, Boolean, null: ...
33.333333
141
0.719
61fbb4f8243a8dd48755351eac77fc99e3022871
291
require 'gabba' require 'rspec' require 'webmock/rspec' WebMock.disable_net_connect! def stub_analytics(expected_params) stub_request( :get, /www.google-analytics.com\/__utm.gif\?utmac=#{expected_params[:utmac]}&.*/ ).to_return(:status => 200, :body => '', :headers => {}) end
22.384615
78
0.694158
1ac4f37834bc459930d7f83983de4afe57965755
4,508
# frozen_string_literal: true module EE module API module Helpers module SettingsHelpers extend ActiveSupport::Concern prepended do params :optional_params_ee do optional :elasticsearch_aws, type: Grape::API::Boolean, desc: 'Enable support for AWS hosted elasticsearch...
71.555556
216
0.712733
e93a4e62244f33fbe1716ac00251ee8ee4cef1ad
57,930
require 'spec_helper' describe Project, models: true do describe 'associations' do it { is_expected.to belong_to(:group) } it { is_expected.to belong_to(:namespace) } it { is_expected.to belong_to(:creator).class_name('User') } it { is_expected.to have_many(:users) } it { is_expected.to have_many...
32.802945
123
0.680994
ff8c544d1c5e984fd4b99855c06bdc848627d48b
1,754
class TaxonNameRelationship::Iczn::Invalidating::Homonym::Secondary::Secondary1961 < TaxonNameRelationship::Iczn::Invalidating::Homonym::Secondary NOMEN_URI='http://purl.obolibrary.org/obo/NOMEN_0000292'.freeze soft_validate(:sv_year_of_description, set: :specific_relationship, has_fix: false) soft_validate(:s...
30.241379
160
0.782212
1a04f60eca1e0a9b795890dea9c3d75ffc7aa69d
556
$small_hash = { [[770637937]] => 18, [442227972, :E2WngMu6vy] => 5, :jaWa => 0, :E0R5HN7hX => 14, 700648627 => 6, 639030613 => 12, 348421750 => 16, [[:qpMHyZacFmMU]] => 8, :SlBkyplxcZ => 17, 144371495 => 1, [596739929] => 9, 385412024 => 4, [673910393] => 19, 471761289 => 13, [:E7, 9492130...
23.166667
114
0.548561
1dc2b97ff98cc497f1003a7c553058a4dfe6ca22
804
# This file should contain all the record creation needed to seed the database with its default values. # The data can then be loaded with the rails db:seed command (or created alongside the database with db:setup). # # Examples: # # movies = Movie.create([{ name: 'Star Wars' }, { name: 'Lord of the Rings' }]) # Ch...
28.714286
111
0.699005
08ddd2b100445f064b3d9de6260441a6ec4d49e7
458
class Teacher < ActiveRecord::Base before_save { self.email = email.downcase } VALID_EMAIL_REGEX = /\A[\w+\-.]+@[a-z\d\-.]+\.[a-z]+\z/i validates :name, presence: true, length: { maximum: 50 } validates :email, presence: true, length: { maximum: 250}, format: { with: VALID_EMAIL_REGEX }, ...
32.714286
61
0.646288
6116cf641b24f247be2a41d374e1aa4b1016e325
537
cask 'radarr' do version '0.2.0.654' sha256 'c0aa3875ee49383e06b34abcfb86b5d1bce746970e0a20dd396d5a6c076b77d4' # github.com/Radarr/Radarr was verified as official when first introduced to the cask url "https://github.com/Radarr/Radarr/releases/download/v#{version}/Radarr.develop.#{version}.osx-app.zip" appca...
38.357143
108
0.772812
f8a37d952930dffff3a99665ecf35ee4bfea76c4
590
class <%= migration_class_name %> < ActiveRecord::Migration<%= migration_version %> def change create_table :<%= job_log_table_name %> do |t| t.string :sidekiq_jid, :null => false t.string :status t.string :item_type t.text :args, limit: 4294967295 t.boolean :retry, null: false, defa...
31.052632
83
0.652542
184eec4faae473f0f16b9dba82b3facf5701f94f
1,485
Pod::Spec.new do |s| s.name = 'NJDYPlayer' s.version = '1.0.0' s.summary = 'NJDYPlayer, NJDYPlayer' s.homepage = 'https://github.com/njhu/NJDYPlayer' s.license = { :type => 'MIT', :file => 'LICENSE' } s.author = { 'njhu' => '64hp@163.com' } s.social_media_url =...
24.75
98
0.63569
ace2ad24e3c562b76446e1eec0be79a4064771b4
8,832
# # Author:: AJ Christensen (<aj@hjksolutions.com>) # Copyright:: Copyright (c) 2008 Opscode, Inc. # License:: Apache License, Version 2.0 # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # #...
41.464789
152
0.710145
6af295243e559d4b71127da6367261d3ce277e20
3,100
# frozen_string_literal: true #------------------------------------------------------------------------- # # Copyright (c) Microsoft and contributors. All rights reserved. # # The MIT License(MIT) # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated ...
47.692308
150
0.700968
bbe3d4d044abd692ef433dd0f58534bf4e806253
3,778
require 'rspec' require_relative './renderer.rb' describe 'Renderer' do describe '#render' do subject(:renderer) { Renderer.new } let(:binary_update_1) do update = double('BinaryUpdate') allow(update).to receive(:old_version) { '1.1.0' } allow(update).to receive(:new_version) { '1.3.0' } ...
34.345455
116
0.650873
e256d5858452ab4cf418cd42b6cb3739518b23f8
200
require 'spec_helper' describe TvTonight do it 'has a version number' do expect(TvTonight::VERSION).not_to be nil end it 'does something useful' do expect(false).to eq(true) end end
16.666667
44
0.71
01cf78beec0e0f3b9e1113cfc4b1b48c588d2f1a
12,050
require 'spec_helper' describe 'apache::mod::passenger', :type => :class do let :pre_condition do 'include apache' end context "on a Debian OS" do let :facts do { :osfamily => 'Debian', :operatingsystemrelease => '6', :kernel => 'Linux', ...
42.429577
150
0.568133
33a028a4c27e44b5e83c021c6505d149569b8cfd
1,810
class NavigationPolicy attr_accessor :user, :navigation def initialize(user, navigation) @user = user @navigation = navigation add_dynamic_methods ensure_admin end def registered? ! user.nil? end def allow_local_signup? NavigationPolicy.configured_for_local_signup? end def s...
24.459459
97
0.687293
e20cee13bfa20933352decc7fd674d06585c6eb1
986
class FixLineDirections < ActiveRecord::Migration[5.2] def change flushingn = ExpressLineDirection.joins(:line).find_by(lines: {name: "Flushing"}, direction: 1) flushingn.last_branch_stop = "701N" # Flushing–Main St flushingn.last_alternate_branch_stop = "702N" # Mets–Willets Pt flushingn.save! f...
44.818182
121
0.733266
03ca73f257ada535e7b1e9bbfd3dc855eea7d16e
1,569
# encoding: utf-8 # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may cause incorrect behavior and will be lost if the code is # regenerated. module Azure::Compute::Mgmt::V2019_07_01 module Models # # The List Virtual Machine operation response. # class VirtualMachineSizeListResu...
28.017857
78
0.525175
0320f819dcddba4469f8ed25e6e5f29f8cc66860
10,576
# ********** Copyright Viacom, Inc. Apache 2.0 ********** require_relative "../test_helper.rb" module RokuBuilder class PackagerTest < Minitest::Test def setup Logger.set_testing RokuBuilder.class_variable_set(:@@dev, false) RokuBuilder.setup_plugins register_plugins(Packager) @req...
38.739927
157
0.635401
d51bc0007b8c21f3db9624ecf8620cb7acdcfe7a
2,251
# Tests in this file ensure that: # # * plugin controller actions are found # * actions defined in application controllers take precedence over those in plugins # * actions in controllers in subsequently loaded plugins take precendence over those in previously loaded plugins # * this works for actions in namespaced con...
43.288462
114
0.838294
7911e741a541b129a14e46e8af379c988f534744
893
# Get twilio-ruby from twilio.com/docs/ruby/install require 'rubygems' # This line not needed for ruby > 1.8 require 'twilio-ruby' # Get your Account Sid and Auth Token from twilio.com/user/account account_sid = 'ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX' auth_token = 'your_auth_token' workspace_sid = 'WSXXXXXXXXX...
38.826087
71
0.690929
ab14c23360ce7b15d471f6b1fd59389e26968a2a
175
class AddSelectionProcessToEvents < ActiveRecord::Migration[5.1] def change add_column :events, :selection_by_organizer, :boolean, default: false, null: false end end
29.166667
86
0.777143
b9ec8621e99ea99fac16416879e5d3b7d4e49288
1,357
module StripeClerk module ChargesHelper # determine if the given user has ordered by card and if so return the charge # given user may be nil, in which case nil is returned (save caller checking) # nil is also returned if no stripe order was placed # from the returned charge one may get the card (to ...
36.675676
98
0.676492
877cb6e21f237d1b97a895605612165bf51ba293
1,372
#coding: utf-8 $:.unshift File.expand_path("../lib", __FILE__) require 'server_scripts/version.rb' def self.get_files files = [] ['ext', 'lib', 'spec'].each do |folder| files.concat Dir.glob "#{folder}/**/*" end files.concat( ["Gemfile", "server_scripts.gemspec", "README.md", "Rakefile"]) files ...
29.826087
87
0.6793
7a295c24a4ca14d6096b1fe505fbaa47535b1e18
199
class Twig module Util def self.numeric?(value) !!Float(value) rescue false end def self.truthy?(value) %w[true yes y on 1].include?(value.to_s.downcase) end end end
16.583333
55
0.628141
3388e9ae9c036fa7bb9e9de350987c68335dd675
2,167
require "#{File.join(File.dirname(__FILE__),'..','spec_helper.rb')}" describe 'url_parse' do describe 'Test Url Components parsing' do it 'should return correct scheme' do should run.with_params('ftp://www.example.com/test','scheme').and_return('ftp') end it 'should return correct userinfo' do ...
49.25
146
0.699585
3824354bdba290b5d99a75f15f1d5eade4138e38
809
require_relative "jekyll-open-sdg-plugins/version" require_relative "jekyll-open-sdg-plugins/site_configuration" require_relative "jekyll-open-sdg-plugins/validate_site_config" require_relative "jekyll-open-sdg-plugins/fetch_remote_data" require_relative "jekyll-open-sdg-plugins/translate_key" require_relative "jekyll-...
47.588235
68
0.866502
26fe4583e5fa8ba8410137b48691094309944312
1,526
# frozen_string_literal: true require_relative "component/composable" require_relative "component/intersection" module Same # This module should be included in every component in your application. # # Components are data holders. Each component class defines a small set of data that it holds. Then entities can ...
29.921569
117
0.700524
6a3e68c6b4655f61462d1f040be9f9c640e704ab
264
require "merb-core" require "merb-mailer/mailer" require "merb-mailer/mail_controller" require "merb-mailer/mailer_mixin" Merb::Controller.send(:include, Merb::MailerMixin) Merb.add_generators(File.join(File.dirname(__FILE__), 'generators', 'mailer_generator'))
29.333333
88
0.795455
ed745eb11bae2b3a1acb684f0036f39a34717344
165
def task367(n) a = [1..3] b = [1..3, 1..3] for i in n..3 for j in n..3 b[i, j] = a[i] - 3 * a[j] puts(b[i, j]) end end end task367(33)
11.785714
31
0.412121
e869364c5be21daf5771c9499f3e8dcbd88c1fd6
2,684
# typed: ignore require 'datadog/tracing/contrib/rails/rails_helper' require 'datadog/tracing/contrib/rails/framework' require 'datadog/tracing/contrib/rails/middlewares' require 'datadog/tracing/contrib/rack/middlewares' RSpec.describe 'Rails Railtie' do before { skip 'Test not compatible with Rails < 4.0' if Rails...
30.157303
111
0.682191
87d9f5cdf8ecd29ce1a9799d0ae71d8056cdde22
20,037
require 'spiderfw/controller/controller_io' require 'spiderfw/controller/request' require 'spiderfw/controller/response' require 'spiderfw/controller/scene' require 'spiderfw/controller/controller_exceptions' require 'spiderfw/controller/first_responder' require 'spiderfw/controller/controller_mixin' require 'spiderf...
39.994012
110
0.554025
39c189ef8e8690ee133493c6e9913b0bc6ba463b
3,324
require 'spec_helper_acceptance' # Ensure time synchronization is in use - Section 2.2.1.1 describe package('ntp') do it { should be_installed } end describe package('chrony') do it { should be_installed } end # Ensure ntp is configured - Section 2.2.1.2 describe file('/etc/ntp.conf') do it { should be_f...
25.569231
84
0.692238
e808fbe7168eec68188405770cd7c236bae0d4a0
317
module Autoconsul module Helpers def self.options(spec) # This will convert a hash of format { 'option' => 'option_value' } # into a string with the expected format for command line: # --option --option_value spec.reduce(String.new) { |r, (o, v)| r << "--#{o} #{v} " } end end end
28.818182
73
0.602524
380309c17cee3ca7a26b4f2b2ccf8be2ced458f8
55,160
# frozen_string_literal: true require 'set' # NOTE RUBY_ENGINE == 'opal' conditional blocks like this are filtered by the Opal preprocessor if RUBY_ENGINE == 'opal' # this require is satisfied by the Asciidoctor.js build; it augments the Ruby environment for Asciidoctor.js require 'asciidoctor/js' else autoload ...
34.518148
183
0.593129
62bc348bfb0b769fc9c4869fa47aa23318653311
624
class String define_method(:anagram) do |word| sorted_input = self.downcase().delete("^a-z").split('').sort() sorted_word = word.downcase().delete("^a-z").split('').sort() reversed_word = word.downcase().delete("^a-z").reverse() user_input = self.downcase().delete("^a-z") if user_input.scan(/[aei...
29.714286
66
0.636218
620b1f6dc37111a41d4bc8315d84c9070fc6e689
2,120
#-- # Copyright (c) 2010-2012 Michael Berkovich # # Permission is hereby granted, free of charge, to any person obtaining # a copy of this software and associated documentation files (the # "Software"), to deal in the Software without restriction, including # without limitation the rights to use, copy, modify, merge, p...
38.545455
86
0.748113
612c108c5e6c4251d43a8775f9e298d2eb87cd59
1,258
class Automake < Formula desc "Tool for generating GNU Standards-compliant Makefiles" homepage "https://www.gnu.org/software/automake/" url "http://ftpmirror.gnu.org/automake/automake-1.15.tar.xz" mirror "https://ftp.gnu.org/gnu/automake/automake-1.15.tar.xz" sha256 "9908c75aabd49d13661d6dcb1bc382252d22cc77bf...
32.25641
95
0.740859
617d731b24746f7c6c9db5b20f2dc0c91fb2a95c
1,438
# encoding: utf-8 # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may cause incorrect behavior and will be lost if the code is # regenerated. module Azure::Monitor::Mgmt::V2019_03_01 module Models # # Represents a baseline metadata value. # class BaselineMetadata include M...
24.793103
70
0.515994
792ab44f43ef4d2dcd06f0fe9ad8ded03e0b6f6d
2,867
# encoding: UTF-8 # 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 definition is the authoritative sou...
40.957143
142
0.709452
4a8604aa20aa506ffd9cfcd78a5602b94b2002fb
7,488
# # Cookbook Name:: bcpc # Recipe:: zabbix-head # # Copyright 2013, Bloomberg Finance L.P. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # U...
25.297297
97
0.713809
627f5745eee444ba82481c886b5aa2829a54c893
527
# encoding: UTF-8 # This file contains data derived from the IANA Time Zone Database # (http://www.iana.org/time-zones). module TZInfo module Data module Definitions module Indian module Kerguelen include TimezoneDefinition timezone 'Indian/Kerguelen' do |tz| ...
21.958333
66
0.555977
1a237c7f3d36fa0f8aec52e763b0b0c8cce4f210
2,038
class Expect < Formula desc "Program that can automate interactive applications" homepage "https://expect.sourceforge.io/" url "https://downloads.sourceforge.net/project/expect/Expect/5.45.4/expect5.45.4.tar.gz" sha256 "49a7da83b0bdd9f46d04a04deec19c7767bb9a323e40c4781f89caf760b92c34" bottle do rebuild 1...
34.542373
122
0.712954
6243bb39120418348bbd9c2d199d18c32a86db28
14,066
# frozen_string_literal: true require "cgi" module Stripe module Util # Options that a user is allowed to specify. OPTS_USER_SPECIFIED = Set[ :api_key, :idempotency_key, :stripe_account, :stripe_version ].freeze # Options that should be copyable from one StripeObject to anot...
34.560197
79
0.61247
189ae0511ba9189aa0fbdbcfc817482432c36b84
70
# Add your variables here first_number = "luis" second_number = "soto"
23.333333
25
0.757143
03e7342fcc322bfea19c445c8da17f1cfda684e8
1,469
# coding: utf-8 lib = File.expand_path('../lib', __FILE__) $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib) require 'trelloist/version' Gem::Specification.new do |spec| spec.name = "trelloist" spec.version = Trelloist::VERSION spec.authors = ["Tumas Bajoras"] spec.email = ["...
38.657895
104
0.6855
e819897e2d3eb2d547e2403b38b32f585e953931
883
# TODO: Get these added to the `pretty_ruby` gem, and use that. (Note that it uses refinements, not monkey-patching.) module Enumerable # Allow Scheme-style `rest`. def rest(count = 1) drop(count) end # Allow Scheme-style `tail`. def tail return self if size.zero? last(size - 1) end # Retu...
21.02381
117
0.657984
1a13c565ed636e753e38dffc736e950c49ee7e54
4,278
## # This file is part of the Metasploit Framework and may be subject to # redistribution and commercial restrictions. Please see the Metasploit # Framework web site for more information on licensing and terms of use. # http://metasploit.com/framework/ ## require 'msf/core' class Metasploit3 < Msf::Exploit...
29.102041
87
0.583918
610dd9c3372923da29966a454b10bb6ba302dcb6
9,041
=begin #The Plaid API #The Plaid REST API. Please see https://plaid.com/docs/api for more details. The version of the OpenAPI document: 2020-09-14_1.64.13 Generated by: https://openapi-generator.tech OpenAPI Generator version: 5.1.0 =end require 'date' require 'time' module Plaid # The rationale for Plaid's dec...
32.876364
659
0.641301
1d0637fef0cbc42a0f6274d58a773657d0885d76
2,555
# Generated by the protocol buffer compiler. DO NOT EDIT! # Source: google/ads/googleads/v9/services/feed_item_set_link_service.proto for package 'Google.Ads.GoogleAds.V9.Services' # Original file comments: # Copyright 2021 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not us...
37.573529
184
0.625832
d5e56c4a8bf4738e91e82e7d840b03c141532c4e
1,947
class PostVote < ApplicationRecord class Error < Exception ; end belongs_to :post belongs_to :user attr_accessor :vote after_initialize :initialize_attributes, if: :new_record? validates_presence_of :score validates_inclusion_of :score, :in => [SuperVoter::MAGNITUDE, 1, -1, -SuperVoter::MAGNITUDE] aft...
27.041667
110
0.684643
116899b0adb956cdaa7b80db381ef85efa5776d6
286
require_relative '../../spec_helper' describe "Complex#marshal_dump" do it "is a private method" do Complex.should have_private_instance_method(:marshal_dump, false) end it "dumps real and imaginary parts" do Complex(1, 2).send(:marshal_dump).should == [1, 2] end end
23.833333
69
0.72028
1d2a5e9c746b9f5c977dadaeef5f1e7ba1746d7b
966
require 'pg' require 'date' now = DateTime.now con = PG.connect(:dbname => "#{$evm.object['db_database']}", :user => "#{$evm.object['db_user']}", :password => "#{$evm.object.decrypt('db_password')}", :host => "#{$evm.object['db_hostname']}" ) res = con.exec "selec...
43.909091
203
0.620083
873668165940b6ca1316c3d83292d4f598862110
144
# Be sure to restart your server when you modify this file. DummyApp::Application.config.session_store :cookie_store, key: '_finishes_session'
36
82
0.805556
62ccd2b9ec5de36d63c60255897da1e78903d6d8
589
name 'graphite' maintainer 'Sous Chefs' maintainer_email 'help@sous-chefs.org' license 'Apache-2.0' description 'Installs/Configures graphite' long_description IO.read(File.join(File.dirname(__FILE__), 'README.md')) version '1.0.7' supports 'ubuntu' supports 'debian' supports '...
28.047619
72
0.711375
ed028d6282fd3a71f1e878905eab1967b361293f
6,061
require 'formula' # NOTE: When updating Wine, please check Wine-Gecko and Wine-Mono for updates too: # http://wiki.winehq.org/Gecko # http://wiki.winehq.org/Mono class Wine < Formula homepage 'http://winehq.org/' stable do url 'http://downloads.sourceforge.net/project/wine/Source/wine-1.6.tar.bz2' sha256 ...
32.940217
96
0.6852
33debfb8700744f8221391bbe4581a66aadc2911
907
module NavigationHelpers # Maps a name to a path. Used by the # # When /^I go to (.+)$/ do |page_name| # # step definition in web_steps.rb # def path_to(page_name) case page_name when /the home\s?page/ '/' when /the new post page/ new_post_path when /the sign up page/ ...
23.25641
71
0.593164
6a103c575c8914b3f59d38096f22e1e7f70a661c
4,179
# frozen_string_literal: true require "rails_helper" RSpec.describe ChangeSetPersister::UpdateAspaceDao do let(:shoulder) { "99999/fk4" } let(:blade) { "123456" } with_queue_adapter :inline it "updates ASpace with a new DAO when an item is marked complete" do stub_aspace_login stub_find_archival_objec...
50.963415
184
0.78057
26d82506ade45d6bf08506723bf130f8806e5ec4
1,155
require_relative '../lib/credit_card' require 'minitest/autorun' describe 'Test hashing requirements' do before do @cc1 = CreditCard.new('4916603231464963', 'Mar-30-2020', 'Soumya Ray', 'Visa') @cc2 = CreditCard.new('4916603231464963', 'Mar-30-2020', 'Soumy...
30.394737
70
0.658009
1c552939db1b5d77ef69d26ee788f252c766f926
2,765
# frozen_string_literal: true require 'bundler' module LicenseFinder class Bundler < PackageManager def initialize(options = {}) super @ignored_groups = options[:ignored_groups] @definition = options[:definition] # dependency injection for tests end def current_packages logger.d...
25.366972
106
0.667993
62aa3362c8342d22cda5fd5fc22918e437cd52e3
1,978
# Copyright (c) 2007-2021 Andy Maleh # # Permission is hereby granted, free of charge, to any person obtaining # a copy of this software and associated documentation files (the # "Software"), to deal in the Software without restriction, including # without limitation the rights to use, copy, modify, merge, publish, # d...
38.784314
122
0.737108
f7295b684057034994061b5cecbef1838bfff8ce
772
Gem::Specification.new do |s| s.name = 'ultrasoap' s.version = '0.1.6' s.summary = "Simple Ruby client library for UltraDNS SOAP API" s.description = "Connect to Neustar's UltraDNS SOAP API. FKA ultrasoap-ruby. Any feedback or contribution is appreciated." s.authors = ["Gabriel Sa...
33.565217
126
0.632124
18112c7e2d7b2f7aed41ab480e5a0b79e11368df
515
cask "sabnzbd" do version "3.2.1" sha256 "d007fd890ddfce91e693cd7b759f48ae9fb01750574108f8354eccd15effae99" url "https://github.com/sabnzbd/sabnzbd/releases/download/#{version}/SABnzbd-#{version}-osx.dmg", verified: "github.com/sabnzbd/sabnzbd/" name "SABnzbd" desc "Binary newsreader" homepage "https...
23.409091
99
0.72233
f802cf9767412041f3c5deff365a7e642259b509
309
require './lib/main' use Rack::MiniProfiler if ENV.has_key?("PROFILE") %w{w webdav}.each do |point| map "/#{point}/" do run DAV4Rack::Handler.new(resource_class: WebSync::FileResource, root_uri_path: "/#{point}/", log_to: ['log/webdav.log', Logger::DEBUG]) end end map '/' do run WebSync::App end
23.769231
140
0.676375
7a1ec54bba7b6966b06b0c2a11524b6361ae01b3
437
# frozen_string_literal: true # 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 s...
43.7
76
0.810069
e9fc5463d8de1f9df925987ac3a7bfb63e73c1a7
1,829
require "google_drive" require 'csv' module Gdrive class NotFound < RuntimeError; end class Spread attr_reader :key def initialize(ds, key) @ds = ds @key = key @raw = ds.spreadsheet_by_key(key) end def raw @raw or raise NotFound.new("spreadsheet not found: '#{@key}'") ...
18.29
78
0.556042
e83104729bffca90a1a67080170676c542f33e21
216
# frozen_string_literal: true class Admin::Search::TextFieldComponent < ViewComponent::Form::TextFieldComponent self.tag_klass = ActionView::Helpers::Tags::TextField def html_class 'form-control' end end
21.6
81
0.773148
18417791d089f43e80818467caedf718b2b3cfb2
1,005
class Gammu < Formula desc "Command-line utility to control a phone" homepage "https://wammu.eu/gammu/" url "https://dl.cihar.com/gammu/releases/gammu-1.37.4.tar.xz" mirror "https://mirrors.kernel.org/debian/pool/main/g/gammu/gammu_1.37.4.orig.tar.xz" sha256 "ee345d9e1a06fd055bca8a4b418778a9568178a2c34082e820...
33.5
103
0.747264
7acfb4b98fc61a70a9e0c45417c4d8930f629f72
463
# # encoding: utf-8 # Inspec test for recipe own_cookbook::default # The Inspec reference, with examples and extensive documentation, can be # found at http://inspec.io/docs/reference/resources/ unless os.windows? describe user('root') do it { should exist } skip 'This is an example test, replace with your...
24.368421
73
0.725702
ac921f8687ff6c30ac4b92dba8b053e641e7b113
2,421
# encoding: utf-8 require 'spec_helper' describe Relation, '#eql?' do subject { object.eql?(other) } let(:header) { [[:id, Integer]] } let(:body) { LazyEnumerable.new([[1]]) } let(:object) { described_class.new(header, body) } before do expect(object).to be_instance_of(descr...
28.482353
92
0.533251
b96fbc968afeff793ae51e99df9b4c98bc580ee5
530
class CalendarController < ApplicationController add_breadcrumb "Calendar" def index @issues_json = Issue.where(issue_status: :open).to_json(methods: [:start_date, :end_date, :text, :url, :color]) @todos_json = current_user.todos.to_json(methods: [:text, :url, :color, :start_date, :end_date]) @weeks_json = Wee...
53
123
0.728302
1ae47a5a0eedbd56a8039de6c096f061562e3b36
6,427
=begin #Selling Partner API for A+ Content Management #With the A+ Content API, you can build applications that help selling partners add rich marketing content to their Amazon product detail pages. A+ content helps selling partners share their brand and product story, which helps buyers make informed purchasing decis...
53.558333
365
0.838961
28e29fda0bd1fc18386dc3a0dc3a640e0a18035f
594
#!/usr/bin/env ruby # Makes sure log, log_e, and bench can be overridden. # (C)2013 Mike Bourgeous require_relative '../lib/nlhue' NLHue::Log.on_log do |*args| puts "OK: Log overridden #{args}" end NLHue::Log.on_log_e do |*args| puts "OK: Log_e overridden #{args}" end NLHue::Log.on_bench do |*args, &block| pu...
23.76
77
0.70202
1c0fc282491ef1351e45f4b8053545b85b53b4ce
469
class ManageAssignments::CoursesController < ApplicationController def show @course = CourseCoverage.new(course) authorize(@course) if @course.has_coverages? render :show else render :show_without_coverages end end def course policy_scope(Course). includes(outcomes: :ou...
22.333333
66
0.690832
618937d9f9a5fa8677e7827bed42713fc912875a
2,052
require "language/node" class FirebaseCli < Formula desc "Firebase command-line tools" homepage "https://firebase.google.com/docs/cli/" url "https://registry.npmjs.org/firebase-tools/-/firebase-tools-10.0.1.tgz" sha256 "cfa57ac33a7b81e923ab3712fa5e0c10cc4c514294a4d1aa77442bfca5525df3" license "MIT" head "h...
40.235294
123
0.767057
bb932d67649f62a036cdbe7b0508f6af013f3455
2,406
# frozen_string_literal: true require 'types' require 'dms/main/entities/person' require 'dms/main/entities/cause' require 'dms/main/entities/project' module Dms module Main module Entities class Donation < Dry::Struct constructor_type :schema Donation_Types = Types::Strict::String.enum('o...
30.075
97
0.5399
62503fe20609a4558f4c1d093ff788aa9a2e97bf
3,429
require File.expand_path('../../../spec_helper', __FILE__) require File.expand_path('../fixtures/classes', __FILE__) require File.expand_path('../shared/enumeratorized', __FILE__) describe "Enumerable#each_slice" do before :each do @enum = EnumerableSpecs::Numerous.new(7,6,5,4,3,2,1) @sliced = [[7,6,5],[4,3,...
33.617647
87
0.631671
ed6550d84b85356cf5b8403a158f42e7023eef97
2,216
# Based on https://github.com/ajsharp/warden-rspec-rails module Warden # Set of helpers for testing with Warden module Test # Warden::Test::ControllerHelpers provides a facility to test controllers in isolation # Most of the code was extracted from Devise's Devise::TestHelpers. module ControllerHelpers ...
33.575758
128
0.625
613d9aa0365ae11048dddb78161e61aebf0e9362
443
cask :v1 => 'preference-manager' do version :latest sha256 :no_check url 'http://download.digitalrebellion.com/Pref_Man.dmg' appcast 'http://www.digitalrebellion.com/rss/appcasts/pref_man_appcast.xml' name 'Preference Manager' homepage 'http://www.digitalrebellion.com/prefman' license :unknown # todo:...
34.076923
115
0.758465
386168c6d5291ed4fd370c50ab846b93c0fb7d12
1,197
# coding: utf-8 lib = File.expand_path('../lib', __FILE__) $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib) require 'duck_puncher/version' Gem::Specification.new do |spec| spec.name = "duck_puncher" spec.version = DuckPuncher::VERSION spec.authors = ["Ryan Buckley"] spec.email ...
39.9
106
0.663325
61876a254eda6b059bf87684eefbde80c741850b
766
require "rails" require "action_cable" require "cable_ready" require "futurism/engine" require "futurism/message_verifier" require "futurism/resolver/resources" require "futurism/resolver/controller" require "futurism/resolver/controller/renderer" require "futurism/channel" require "futurism/helpers" module Futurism ...
24.709677
72
0.787206
7994e8a573b243ce1e384c772ac1d01e74aab997
260
require 'virtus' require 'adamantium' require "podcast_reader/version" module PodcastReader # Your code goes here... end require 'podcast_reader/podcast' require 'podcast_reader/item_node' require 'podcast_reader/request' require 'podcast_reader/channel'
18.571429
34
0.807692
e9c8a307fff230ec925d3fb709606d26735a41b3
393
class GroceryPolicy < ApplicationPolicy def index? user.present? end def show? user.present? end def create? user.present? end def edit? user.present? end def update? return true if user.present? && user == item.user end def destroy? return true if user.present? && use...
12.28125
53
0.618321
f782108d13b3a2e75f01652627130a3ff3d12a71
4,908
class Vanagon class Platform class RPM < Vanagon::Platform # The specific bits used to generate an rpm package for a given project # # @param project [Vanagon::Project] project to build an rpm package of # @return [Array] list of commands required to build an rpm package for the given proj...
44.216216
205
0.628158
280518d9110688bebc90eb9a319d0402507952d1
1,958
require 'pry' class CLI attr_accessor :user def greeting puts "Welcome To Your Journy!" puts "***********************" puts " Please enter your fullname" @user = gets.chomp.strip.upcase puts " " puts "Welcome #{@user}: If you are intrested in traveling the world ente...
27.577465
91
0.565373