conversations listlengths 2 3 | source stringclasses 1
value | stack stringclasses 1
value |
|---|---|---|
[
{
"from": "system",
"value": "Fix pypi access issue with http.\nChanging the URL to https\n"
},
{
"from": "human",
"value": "#\n# Cookbook Name:: bach_repository\n# Recipe:: python_sources\n#\n# This recipe downloads pypi packages that are distributed to workers\n# in source form. \n#\ninclude_r... | ruby | chosen |
[
{
"from": "system",
"value": "Use google DNS for jakelong\n"
},
{
"from": "human",
"value": "name \"prgmr\"\ndescription \"Role applied to all servers at prgmr.com\"\n\ndefault_attributes(\n :hosted_by => \"prgmr.com\",\n :location => \"San Francisco, California\",\n :timezone => \"PST8PDT\",... | ruby | chosen |
[
{
"from": "system",
"value": "Fix merge conflict for seed file\n"
},
{
"from": "human",
"value": "<<<<<<< HEAD\n# This file should contain all the record creation needed to seed the database with its default values.\n# The data can then be loaded with the rake db:seed (or created alongside the d... | ruby | chosen |
[
{
"from": "system",
"value": "Fix spec -- view now requires @product_group_placement\n"
},
{
"from": "human",
"value": "require 'rails_helper'\n\ndescribe '/admin/products/edit.html.slim' do\n include ProductsHelper\n\n before(:each) do\n assigns[:product] = @product = FactoryGirl.create(:p... | ruby | chosen |
[
{
"from": "system",
"value": "Update Redesign Summary to use parameterized query\n\nRedesignSummary#add_existing_attachments was not using parameterized\nqueries and was vulnerable to sql injections, it's not now.\n"
},
{
"from": "human",
"value": "class RedesignSummary < ActiveRecord::Base\n a... | ruby | chosen |
[
{
"from": "system",
"value": "Allow usage with Mongoid 4 through 6\n"
},
{
"from": "human",
"value": "Gem::Specification.new do |s|\n s.name = \"mongoid-rails\"\n s.version = \"4.0.0\"\n s.author = \"Conrad Irwin\"\n s.email = \"conrad.irwin@gmail.com\"\n s.homepage ... | ruby | chosen |
[
{
"from": "system",
"value": "Add license flag to the gemspec\n"
},
{
"from": "human",
"value": "# -*- encoding: utf-8 -*-\n$:.push File.expand_path(\"../lib\", __FILE__)\n\nrequire 'mongoid/rspec/version'\n\nGem::Specification.new do |s|\n s.name = \"mongoid-rspec\"\n s.version = M... | ruby | chosen |
[
{
"from": "system",
"value": "Add dm-core runtime dependency to gemspec\n"
},
{
"from": "human",
"value": "# -*- encoding: utf-8 -*-\nrequire File.expand_path('../lib/data_mapper/validation/version', __FILE__)\n\nGem::Specification.new do |gem|\n gem.authors = [ 'Guy van den Berg', 'Emmanue... | ruby | chosen |
[
{
"from": "human",
"value": "Add tests asserting that part assignment against a type works\n"
},
{
"from": "gpt",
"value": "require \"spec_helper\"\n\nmodule Refinery\n module Pages\n describe Type do\n subject { Type.new }\n\n describe \".parts=\" do\n it \"returns an array... | ruby | chosen |
[
{
"from": "system",
"value": "Use Operator.preferred_name for code lists\n"
},
{
"from": "human",
"value": "require_relative 'operator'\n\nmodule ConceptQL\n module Operators\n class VocabularyOperator < Operator\n category \"Select by Clinical Codes\"\n basic_type :selection\n ... | ruby | chosen |
[
{
"from": "system",
"value": "Fix lost block in allowed_to_condition\n"
},
{
"from": "human",
"value": "require 'project'\n\nmodule RedmineCustomize::Patches::ProjectPatch\n extend ActiveSupport::Concern\n\n included do\n has_many :public_drafts\n\n class << self\n alias_method_chai... | ruby | chosen |
[
{
"from": "system",
"value": "Add timer and refactor for style\n"
},
{
"from": "human",
"value": "def amicable?(number)\n sum_of_divisors(sum_of_divisors(number)) == number && sum_of_divisors(number) != number\nend\n\ndef sum_of_divisors(number)\n divisors = []\n (1..number / 2).each do |poss... | ruby | chosen |
[
{
"from": "system",
"value": "Add contextual comment in API\n"
},
{
"from": "human",
"value": "module Xapi\n module Routes\n class Exercises < Core\n get '/exercises/:language/:slug' do |language, slug|\n exercise = Problem.new(language, slug, 'fresh', '.')\n if exercise.n... | ruby | chosen |
[
{
"from": "human",
"value": "Add background job to delete tweets from timelines.\n"
},
{
"from": "gpt",
"value": "# A resque job that removes a tweet from all timelines when it's deleted by\n# the author.\n#\n# Examples\n#\n# # process delete jobs\n# $ QUEUE=retract_tweets bin/rake resque:wo... | ruby | chosen |
[
{
"from": "system",
"value": "Refactor to more intention-revealing composed method\n"
},
{
"from": "human",
"value": "require 'git_tracker/branch'\nrequire 'git_tracker/commit_message'\n\nmodule GitTracker\n class PrepareCommitMessage\n attr_reader :file, :source, :commit_sha\n\n def self... | ruby | chosen |
[
{
"from": "system",
"value": "Fix for new python stull in homebrew\n"
},
{
"from": "human",
"value": "require 'formula'\n\nclass YumMetadataParser < Formula\n homepage 'http://yum.baseurl.org/'\n url 'http://yum.baseurl.org/download/yum-metadata-parser/yum-metadata-parser-1.1.4.tar.gz'\n sha1... | ruby | chosen |
[
{
"from": "system",
"value": "Change an way to terminate rbtclk in Countup.\n"
},
{
"from": "human",
"value": "require \"artii\"\nrequire \"curses\"\nrequire \"time\"\nrequire \"rbtclk/color_code\"\n\nmodule Rbtclk\n class CountupTimer\n include ColorCode\n\n def initialize(font: \"clb8x8... | ruby | chosen |
[
{
"from": "system",
"value": "Remove 'unscoped' modifier from rake task, there's no longer a default scope\n"
},
{
"from": "human",
"value": "require 'asset_processor'\n\nnamespace :govuk_assets do\n desc 'Delete file from NFS for assets uploaded to S3'\n task delete_file_from_nfs_for_assets_u... | ruby | chosen |
[
{
"from": "system",
"value": "Add dependecy to build_config.rb for travis ci\n"
},
{
"from": "human",
"value": "MRuby::Build.new do |conf|\n toolchain :gcc\n conf.gembox 'default'\n conf.gem '../mruby-eventfd'\nend\n"
},
{
"from": "gpt",
"value": "MRuby::Build.new do |conf|\n too... | ruby | chosen |
[
{
"from": "system",
"value": "Revert \"Hardcode version to make an experiment\"\n\nThis reverts commit 16d8824d9a58678d284b2c039328509af8d83aa0.\n"
},
{
"from": "human",
"value": "# -*- encoding: utf-8 -*-\n\n# $LOAD_PATH << File.join(File.dirname(__FILE__), 'lib')\n# require 'typus/version'\n\n... | ruby | chosen |
[
{
"from": "human",
"value": "Add unit tests for exchange name helper module.\n"
},
{
"from": "gpt",
"value": "require 'test_helper'\n\nclass ExchangeNameHelperTest < Minitest::Test\n def test_set_exchange_name_case_insensitive\n ExchangeNameHelper::EXCHANGES.each do |_, v|\n random_casi... | ruby | chosen |
[
{
"from": "system",
"value": "Make Rubocop happMake Rubocop happy\n"
},
{
"from": "human",
"value": "# frozen_string_literal: true\n\nlib = File.expand_path('../lib', __FILE__)\n$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)\nrequire 'rack/rejector/version'\n\nGem::Specification.new do ... | ruby | chosen |
[
{
"from": "system",
"value": "Allow to install in a rails5 app.\n"
},
{
"from": "human",
"value": "# coding: utf-8\nlib = File.expand_path('../lib', __FILE__)\n$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)\nrequire 'switchery/rails/version'\n\nGem::Specification.new do |spec|\n spec.n... | ruby | chosen |
[
{
"from": "system",
"value": "Remove partially remaining decode test\n"
},
{
"from": "human",
"value": "require 'test_helper'\n\nclass Superstore::Types::ArrayTypeTest < Superstore::Types::TestCase\n test 'decode' do\n assert_equal ['1', '2'], type.decode(['1', '2'].to_json)\n asser... | ruby | chosen |
[
{
"from": "system",
"value": "Fix minor issues in the worker recipe.\n"
},
{
"from": "human",
"value": "directory \"#{node[:travis][:worker][:home]}\" do\n action :create\n recursive true\n owner \"travis\" \n group \"travis\"\n mode \"0755\"\nend\n\ngit \"#{node[:travis][:worker][:home]}\... | ruby | chosen |
[
{
"from": "system",
"value": "Stop installing lxc and backported kernel\n\nsince we don't use lxc anymore and the kernel is redundant\n"
},
{
"from": "human",
"value": "# Cookbook Name:: travis_docker\n# Recipe:: package\n# Copyright 2011-2015, Travis CI GmbH <contact+travis-cookbooks@travis-ci.... | ruby | chosen |
[
{
"from": "system",
"value": "Set up fuzzy matches between Aircraft and Airline"
},
{
"from": "human",
"value": "require 'bundler'\nBundler.setup\n\nrequire 'cucumber'\nrequire 'cucumber/formatter/unicode' # Remove this line if you don't want Cucumber Unicode support\n\nrequire 'sniff'\nSniff.in... | ruby | chosen |
[
{
"from": "system",
"value": "Update pod spec to version 0.1.2\n"
},
{
"from": "human",
"value": "Pod::Spec.new do |s|\n git_tag = \"0.1.1\"\n s.name = \"MBContactPicker\"\n s.version = git_tag\n s.summary = \"A contact picker that looks like the one in Apple mail fo... | ruby | chosen |
[
{
"from": "system",
"value": "Fix the path of the shipment comment ovveride.\n"
},
{
"from": "human",
"value": "Deface::Override.new(:virtual_path => \"admin/shipments/edit\",\n :name => \"converted_admin_shipment_edit_buttons_233418828\",\n :insert_after ... | ruby | chosen |
[
{
"from": "system",
"value": "Adjust lib/supermarket/auth spec to please rubocop\n"
},
{
"from": "human",
"value": "require 'spec_helper'\n\nclass ReadOnly\n class Policy\n def initialize(*_) ; end\n\n def show?\n true\n end\n\n def edit?\n false\n end\n end\n\n def p... | ruby | chosen |
[
{
"from": "system",
"value": "Fix up new output for RDiscount 2.\n"
},
{
"from": "human",
"value": "require 'helper'\n\nclass TestRdiscount < Test::Unit::TestCase\n\n context \"rdiscount\" do\n setup do\n config = {\n 'markdown' => 'rdiscount',\n 'rdiscount' => { 'extensio... | ruby | chosen |
[
{
"from": "system",
"value": "Remove install controller tests. They are fail, have low priority for us, and we can not found good solution for install controller.\n"
},
{
"from": "human",
"value": "require 'test_helper'\n\nclass InstallControllerTest < ActionController::TestCase\n\n context \"a... | ruby | chosen |
[
{
"from": "system",
"value": "Fix the test requirement of resque_scheduler\n"
},
{
"from": "human",
"value": "require 'resque'\nrequire 'active_support/core_ext/enumerable'\nrequire 'active_support/core_ext/array/access'\n\nbegin\n require 'resque-scheduler'\nrescue LoadError => e\n $stderr.pu... | ruby | chosen |
[
{
"from": "system",
"value": "Switch to the website under the context of the default frontend locale if supported.\n"
},
{
"from": "human",
"value": "module Refinery\n module Helpers\n module SiteBarHelper\n\n # Generates the link to determine where the site bar switch button returns to... | ruby | chosen |
[
{
"from": "human",
"value": "Add migration to add disclosure_log field\n"
},
{
"from": "gpt",
"value": "class AddDisclosureLog < ActiveRecord::Migration\n def self.up\n add_column :public_bodies, :disclosure_log, :text, :null => false, :default => \"\"\n add_column :public_body_... | ruby | chosen |
[
{
"from": "system",
"value": "Update VLC cask to 2.0.6\n"
},
{
"from": "human",
"value": "class Vlc < Cask\n homepage 'http://www.videolan.org/vlc/'\n url 'http://downloads.sourceforge.net/project/vlc/2.0.5/macosx/vlc-2.0.5.dmg'\n version '2.0.5'\n sha1 'f2d3b240d012f9de6b5f1042a43dccca2c90a... | ruby | chosen |
[
{
"from": "system",
"value": "Update github url as we're now part of the guard org\n"
},
{
"from": "human",
"value": "# -*- encoding: utf-8 -*-\nrequire File.expand_path('../lib/guard/zeus/version', __FILE__)\n\nGem::Specification.new do |gem|\n gem.name = \"guard-zeus\"\n gem.version... | ruby | chosen |
[
{
"from": "human",
"value": "Add tests to deal with the Sequel adapters nicely.\n"
},
{
"from": "gpt",
"value": "require 'spec_helper'\nrequire 'sequel'\n\ndescribe Upsert do\n describe \"Plays nice with Sequel\" do\n config = ActiveRecord::Base.connection.instance_variable_get(:@config)\n ... | ruby | chosen |
[
{
"from": "system",
"value": "Add some missing singleton class specs\n"
},
{
"from": "human",
"value": "\nmodule ClassSpecs\n class A; end\nend\n\ndescribe \"A singleton class\" do\n it \"is NilClass for nil\" do\n nil.singleton_class.should == NilClass\n end\n\n it \"is a singleton Class... | ruby | chosen |
[
{
"from": "human",
"value": "Add integration spec for outdatedness\n"
},
{
"from": "gpt",
"value": "describe 'Outdatedness integration', site: true, stdio: true do\n before do\n File.write('content/foo.md', \"---\\ntitle: hello\\n---\\n\\nfoo\")\n File.write('content/bar.md', '<%= @items[... | ruby | chosen |
[
{
"from": "system",
"value": "Fix spelling mistake in comment.\n"
},
{
"from": "human",
"value": "# encoding: UTF-8\n\nmodule TwitterCldr\n module Normalizers\n class Base\n class << self\n def code_point_to_char(code_point)\n [code_point.upcase.hex].pack('U*')\n ... | ruby | chosen |
[
{
"from": "system",
"value": "Add VERSION_INFO for easier machine parsing.\n"
},
{
"from": "human",
"value": "module RestClient\n VERSION = '2.0.0.alpha' unless defined?(self::VERSION)\n\n def self.version\n VERSION\n end\nend\n"
},
{
"from": "gpt",
"value": "module RestClient\... | ruby | chosen |
[
{
"from": "system",
"value": "Update omniauth dependency to ~> 1.2\n"
},
{
"from": "human",
"value": "lib = File.expand_path('../lib', __FILE__)\n$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)\nrequire 'omniauth-oauth2/version'\n\nGem::Specification.new do |gem|\n gem.add_dependency 'f... | ruby | chosen |
[
{
"from": "system",
"value": "Correct authorization method used in Spree::ProductsController decorator's test in auth\n"
},
{
"from": "human",
"value": "require 'spec_helper'\n\ndescribe Spree::ProductsController do\n let!(:product) { Factory(:product, :available_on => 1.year.from_now) }\n\n i... | ruby | chosen |
[
{
"from": "system",
"value": "Use rails acts_as_list and acts_as_tree.\n"
},
{
"from": "human",
"value": "namespace :typus do\n\n desc 'Install Paperclip, acts_as_list, acts_as_tree.'\n task :misc do\n plugins = [ 'git://github.com/thoughtbot/paperclip.git', \n 'git://github.... | ruby | chosen |
[
{
"from": "human",
"value": "Add new class with no growth\n"
},
{
"from": "gpt",
"value": "$:<< File.join(File.dirname(__FILE__), \"../lib\")\n$:<< File.join(File.dirname(__FILE__), \"../ext\")\n\nrequire 'rbkit'\n\nRbkit.start_profiling(5555)\n\nclass Foo\n def initialize(name)\n @name = na... | ruby | chosen |
[
{
"from": "human",
"value": "Add Firefox for Chinese (Simplified)\n"
},
{
"from": "gpt",
"value": "class FirefoxCn < Cask\n url 'https://download.mozilla.org/?product=firefox-latest&os=osx&lang=zh-CN'\n homepage 'https://www.mozilla.org/zh-CN/firefox/'\n version 'latest'\n no_checksum\n lin... | ruby | chosen |
[
{
"from": "system",
"value": "Fix URL for Parallels Desktop.app v8.0\n\nAdd version and homepage\n"
},
{
"from": "human",
"value": "cask :v1 => 'parallels8' do\n version :latest\n sha256 :no_check\n\n url 'http://www.parallels.com/directdownload/pd8'\n homepage 'http://www.parallels.com/prod... | ruby | chosen |
[
{
"from": "system",
"value": "Simplify Loader.build via new domain param emitter\n"
},
{
"from": "human",
"value": "# encoding: utf-8\n\nmodule ROM\n class Mapper\n\n # Abstract loader class\n #\n # @private\n class Loader\n include Concord::Public.new(:header, :model, :transfo... | ruby | chosen |
[
{
"from": "system",
"value": "Remove Type suffix from xml type names\n"
},
{
"from": "human",
"value": "module Domgen\n module JAXB\n module Helper\n def namespace_annotation_parameter(element)\n return '' unless element.namespace\n \", namespace=\\\"#{element.namespace}\\... | ruby | chosen |
[
{
"from": "system",
"value": "Update xACT 2.33 to 2.34\n\nUpdate xACT 2.33 to 2.34"
},
{
"from": "human",
"value": "class Xact < Cask\n version '2.33'\n sha256 'bd828a3ed879442bf76564fc97c117bee8d49bddabaf3c066413f3dd9e27d714'\n\n url \"http://xact.scottcbrown.org/xACT#{version}.zip\"\n appc... | ruby | chosen |
[
{
"from": "system",
"value": "JariBakken: Fix default URL in the Ruby Android driver.\n\nr13650\n"
},
{
"from": "human",
"value": "module Selenium\n module WebDriver\n module Android\n class Bridge < Remote::Bridge\n\n DEFAULT_URL = \"http://#{Platform.localhost}:8080/hub/\"\n\n ... | ruby | chosen |
[
{
"from": "human",
"value": "Add Sqlite3 adapter, analogues to the postgres one.\n"
},
{
"from": "gpt",
"value": "require 'do_sqlite3'\n\nrequire 'data_mapper/support/veritas/adapter'\nrequire 'data_mapper/support/veritas/adapter/data_objects'\n\nmodule Veritas\n module Adapter\n\n # A verit... | ruby | chosen |
[
{
"from": "system",
"value": "Make test description be accurate\n"
},
{
"from": "human",
"value": "require File.expand_path(File.dirname(__FILE__) + '/../spec_helper')\n\ndescribe RequestGameController, \"when playing the game\" do\n\n fixtures :info_requests, :info_request_events, :public_bo... | ruby | chosen |
[
{
"from": "system",
"value": "Upgrade Atom to version 1.0.7.\n"
},
{
"from": "human",
"value": "cask :v1 => 'atom' do\n version '1.0.6'\n sha256 '212643e118a6d1844a6dfb03481b314a99db7f0f5c7c37e5f528399cf626dbdf'\n\n # github.com is the official download host per the vendor homepage\n url \"h... | ruby | chosen |
[
{
"from": "system",
"value": "Format IntelliJ Idea Community EAP\n"
},
{
"from": "human",
"value": "class IntellijIdeaCommunityEap < Cask\n url 'http://download.jetbrains.com/idea/ideaIC-138.1696.2.dmg'\n homepage 'https://www.jetbrains.com/idea/index.html'\n version '138.1696'\n sha256 '34b... | ruby | chosen |
[
{
"from": "system",
"value": "Add js/ directory to gemspec.\n"
},
{
"from": "human",
"value": "require File.join(File.dirname(__FILE__), 'lib', 'twitter_cldr', 'version')\n\nGem::Specification.new do |s|\n s.name = \"twitter_cldr\"\n s.version = ::TwitterCldr::VERSION\n s.authors = [\"C... | ruby | chosen |
[
{
"from": "system",
"value": "Add domain attribute to Standard model.\n"
},
{
"from": "human",
"value": "module CoreSpring\n class Standard < APIModel\n attr_accessor :id, :dot_notation, :subject, :category, :sub_category, :standard, :grades\n end\nend\n\n"
},
{
"from": "gpt",
"... | ruby | chosen |
[
{
"from": "system",
"value": "Remove TODO from Admin::OverviewController that has existed since the beginning of this repo\n"
},
{
"from": "human",
"value": "# this clas was inspired (heavily) from the mephisto admin architecture\nmodule Spree\n module Admin\n class OverviewController < Spre... | ruby | chosen |
[
{
"from": "system",
"value": "Remove compile_time attr for system-info gem install\n"
},
{
"from": "human",
"value": "#\n# Cookbook Name:: travis_system_info\n# Recipe:: default\n#\n# Copyright 2015, Travis CI GmbH\n#\n# MIT License\n#\n\nlocal_gem = \"#{Chef::Config[:file_cache_path]}/system-in... | ruby | chosen |
[
{
"from": "system",
"value": "Use of custom objects is not necessary here\n"
},
{
"from": "human",
"value": "# coding: utf-8\nlib = File.expand_path('../lib/', __FILE__)\n$:.unshift lib unless $:.include?(lib)\nrequire 'thor/version'\n\nGem::Specification.new do |spec|\n spec.add_development_de... | ruby | chosen |
[
{
"from": "system",
"value": "Change redis package name to match what is in distribution packages\n"
},
{
"from": "human",
"value": "#\n# Author:: Benjamin Black (<b@b3k.us>)\n# Cookbook Name:: redis\n# Recipe:: default\n#\n# Copyright 2009, Benjamin Black\n#\n# Licensed under the Apache License... | ruby | chosen |
[
{
"from": "system",
"value": "Update mocks to simulate real results.\n"
},
{
"from": "human",
"value": "module Fog\n module Compute\n class HP\n class Real\n\n def change_password_server(server_id, admin_password)\n body = { 'changePassword' => { 'adminPass' => admin_pas... | ruby | chosen |
[
{
"from": "system",
"value": "Fix content controller icon (use new font-awesome icon name)\n"
},
{
"from": "human",
"value": "Releaf.setup do |conf|\n # Default settings are commented out\n\n ### setup menu items and therefore available controllers\n conf.menu = [\n {\n :controller =... | ruby | chosen |
[
{
"from": "human",
"value": "Add simple specs for DependencyResolver\n"
},
{
"from": "gpt",
"value": "require File.expand_path('../spec_helper.rb', __FILE__)\n\ndescribe Opal::Nodes::CallNode::DependencyResolver do\n let(:compiler) { double(:compiler, :dynamic_require_severity => :none) }\n\n ... | ruby | chosen |
[
{
"from": "system",
"value": "Fix logic issue if not using GITHUB_TEAM_IDs\n"
},
{
"from": "human",
"value": "class AuthController < ApplicationController\n skip_before_filter :auth, :only => :create\n\n def create\n if team_access? || ENV['GITHUB_TEAM_ID'].nil?\n user = User.where(\n ... | ruby | chosen |
[
{
"from": "system",
"value": "Allow for Aptible remote to be specified via ENV\n"
},
{
"from": "human",
"value": "require 'aptible/api'\nrequire 'git'\n\nmodule Aptible\n module CLI\n module Helpers\n module App\n include Helpers::Token\n\n def ensure_app(options = {})\n ... | ruby | chosen |
[
{
"from": "human",
"value": "Add application GitUp to Cask\n\nThis commit adds the application GitUp for the first time. I have been\nunable to find a versioned download link. It's pre-release software so\nI've added to cask instead of versions. There is no full release yet,\nso I figured it was okay here f... | ruby | chosen |
[
{
"from": "system",
"value": "Reset the alias_target hash for good measure\n"
},
{
"from": "human",
"value": "module Fog\n module Parsers\n module DNS\n module AWS\n\n class ListResourceRecordSets < Fog::Parsers::Base\n\n def reset\n @resource_record = []\n ... | ruby | chosen |
[
{
"from": "system",
"value": "Update method name based on PR review\n"
},
{
"from": "human",
"value": "module ImageHelper\n\n def safe_image_tag(image_url, image_opts={}, load_opts={})\n return if image_url.blank?\n if load_opts[:lazyload]\n commented_image_tag(image_tag(image_url, i... | ruby | chosen |
[
{
"from": "system",
"value": "Fix max number of permitted priorities per project label\n"
},
{
"from": "human",
"value": "class ProjectLabel < Label\n NUMBER_OF_PRIORITIES = 1\n\n belongs_to :project\n\n validates :project, presence: true\n\n validate :permitted_numbers_of_priorities\n vali... | ruby | chosen |
[
{
"from": "system",
"value": "Update test stubs for @GeckoBoard push integration\n"
},
{
"from": "human",
"value": "require File.expand_path('../helper', __FILE__)\n\nclass GeckoBoardTest < PapertrailServices::TestCase\n def setup\n @stubs = Faraday::Adapter::Test::Stubs.new\n end\n\n def ... | ruby | chosen |
[
{
"from": "system",
"value": "Fix stock location transfer quantity check\n"
},
{
"from": "human",
"value": "module Spree\n module Admin\n class StockLocationsController < ResourceController\n before_filter :load_data\n\n def transfer_stock\n @variant = Variant.find(params[:v... | ruby | chosen |
[
{
"from": "human",
"value": "Add an example that shows off PMs\n"
},
{
"from": "gpt",
"value": "# This bot shows off PM functionality by sending a PM every time the bot is mentioned.\n\nrequire 'discordrb'\n\nbot = Discordrb::Bot.new \"email@example.com\", \"hunter2\"\n\nbot.mention do |event|\n... | ruby | chosen |
[
{
"from": "system",
"value": "Create an event handler for RawEventHandler\n"
},
{
"from": "human",
"value": "# frozen_string_literal: true\n\nrequire 'discordrb/events/generic'\n\n# Event classes and handlers\nmodule Discordrb::Events\n # Event raised when any dispatch is received\n class RawE... | ruby | chosen |
[
{
"from": "system",
"value": "Upgrade 1Password 4.app to v4.5.BETA-26"
},
{
"from": "human",
"value": "class OnepasswordBeta < Cask\n version '4.5.BETA-25'\n sha256 'fca119b0614da273a3b2e7d101bae9a9dec3df106ad4bc99d0f14e2ade99e0e2'\n\n url \"https://cache.agilebits.com/dist/1P/mac4/1Password-... | ruby | chosen |
[
{
"from": "system",
"value": "Update Sublime Text dev to Build 3062\n"
},
{
"from": "human",
"value": "class SublimeTextDev < Cask\n url 'http://c758482.r82.cf2.rackcdn.com/Sublime%20Text%20Build%203061.dmg'\n homepage 'http://www.sublimetext.com/3dev'\n version 'Build 3061'\n sha256 '2c4941... | ruby | chosen |
[
{
"from": "system",
"value": "Send Event data through SQS as JSON.\n"
},
{
"from": "human",
"value": "require \"logstash/outputs/base\"\nrequire \"logstash/namespace\"\n\nclass LogStash::Outputs::SQS < LogStash::Outputs::Base\n config_name \"sqs\"\n plugin_status \"experimental\"\n\n # SQS Qu... | ruby | chosen |
[
{
"from": "system",
"value": "Fix Atom version of api_body_request_events\n\nRemove duplicate <created> element, and add an <updated> element\nto each entry.\n"
},
{
"from": "human",
"value": "atom_feed(\"xmlns:alaveteli\" => \"http://www.alaveteli.org/API/v2/RequestEvents/Atom\") do |feed|\n ... | ruby | chosen |
[
{
"from": "system",
"value": "Call `default_font_name` with `.` rather than `::`\n"
},
{
"from": "human",
"value": "require 'gosu'\n\nclass GameWindow < Gosu::Window\n def initialize\n super(320, 240, false)\n self.caption = 'Hello'\n @message = Gosu::Image.from_text(\n self, 'Hel... | ruby | chosen |
[
{
"from": "system",
"value": "Format currency and salary appropriately\n"
},
{
"from": "human",
"value": "require 'slack-notifier'\n\nclass Notifier\n def self.get_notifier\n notifier = Slack::Notifier.new(AppSettings.slack_web_hook_url,\n channel: AppSetti... | ruby | chosen |
[
{
"from": "system",
"value": "Add a minimal spec for the 'undef' keyword\n"
},
{
"from": "human",
"value": "require File.dirname(__FILE__) + '/../spec_helper'\n"
},
{
"from": "gpt",
"value": "require File.dirname(__FILE__) + '/../spec_helper'\n\nclass UndefSpecClass\n def meth=(othe... | ruby | chosen |
[
{
"from": "system",
"value": "Allow finding by permalink or id in products update/destroy on API\n"
},
{
"from": "human",
"value": "module Spree\n module Api\n module V1\n class ProductsController < Spree::Api::V1::BaseController\n def index\n @products = scope.page(para... | ruby | chosen |
[
{
"from": "system",
"value": "Fix bad test to not use mocks, but instead, a real connection\n"
},
{
"from": "human",
"value": "require 'jdbc_common'\nrequire 'db/jndi_config'\n\nbegin\n require 'mocha'\n\nclass JndiConnectionPoolCallbacksTest < Test::Unit::TestCase\n def setup\n @connection... | ruby | chosen |
[
{
"from": "system",
"value": "Remove \"full_controller_name\" method as it only used once\n"
},
{
"from": "human",
"value": "module Releaf\n class BaseApplicationController < ActionController::Base\n before_filter \"authenticate_#{ReleafDeviseHelper.devise_admin_model_name}!\"\n before_fi... | ruby | chosen |
[
{
"from": "system",
"value": "Upgrade FontExplorer X Pro to v4.2.1\n"
},
{
"from": "human",
"value": "class FontexplorerXPro < Cask\n version '4.0.2'\n sha256 '6e7d2bfb89e65e78a8551db705ffca86ec6a25371388ad2124b1cbf956f48472'\n\n url \"http://fex.linotype.com/download/mac/FontExplorerXPro#{ve... | ruby | chosen |
[
{
"from": "system",
"value": "Fix migration without DOWNTIME clause specified\n"
},
{
"from": "human",
"value": "class MigrateUsersNotificationLevel < ActiveRecord::Migration\n # Migrates only users who changed their default notification level :participating\n # creating a new record on notifi... | ruby | chosen |
[
{
"from": "system",
"value": "Upgrade PyCharm Community Edition to 4.0\n"
},
{
"from": "human",
"value": "cask :v1 => 'pycharm-ce' do\n version '3.4.1'\n sha256 '18b4d2d61badb81feaf22a51a7c76b85618e5a7a01f4f4c5e46079d134c64002'\n\n url \"http://download.jetbrains.com/python/pycharm-community-... | ruby | chosen |
[
{
"from": "system",
"value": "[OPTIM] Speed up selective key fetches from hashes\n\nPull Request #293\n\nProblem:\n\nThe `ATTRIBUTES_TYPES` hash is being iterated over twice\nto determine which values are searchable.\n\nThis is an inefficient method\nfor selecting searchable keys from the hash.\n\nSolution:... | ruby | chosen |
[
{
"from": "system",
"value": "Update MoveOrderTokenFromTokenizedPermission migration to work w/ jruby\n\njruby mysql adapter uses adapter_name 'MySQL'. Not recognizing this causes migrations to bomb out on jruby due to invalid SQL syntax.\n\nhttps://github.com/jruby/activerecord-jdbc-adapter/blob/master/lib... | ruby | chosen |
[
{
"from": "system",
"value": "Include Video Height and Width in Editor Seed Data\n"
},
{
"from": "human",
"value": "json.encoding_progress(video_file.encoding_progress.to_i)\n\njson.format(file_format(video_file))\njson.dimensions(file_dimensions(video_file))\njson.duration(file_duration(video_f... | ruby | chosen |
[
{
"from": "system",
"value": "Add spec for survey question lookup\n"
},
{
"from": "human",
"value": "require 'spec_helper'\n\ndescribe Survey do\n it \"gives access to neighborhood data\" do\n Survey.questions_for(\"neighborhood\")[0].should eq(\"public_safety\")\n end\n=begin\n before(:ea... | ruby | chosen |
[
{
"from": "system",
"value": "Add some brackets to increase clarity\n"
},
{
"from": "human",
"value": "module Domgen\n module Java\n module Helper\n def nullability_annotation(is_nullable)\n is_nullable ? \"@javax.annotation.Nullable\" : \"@javax.annotation.Nonnull\"\n end\n... | ruby | chosen |
[
{
"from": "human",
"value": "Add missing spec for ProtectedBranches::CreateService\n"
},
{
"from": "gpt",
"value": "require 'spec_helper'\n\ndescribe ProtectedBranches::CreateService, services: true do\n let(:project) { create(:empty_project) }\n let(:user) { project.owner }\n let(:params) do... | ruby | chosen |
[
{
"from": "system",
"value": "Return the right default object\n"
},
{
"from": "human",
"value": "def llvm_configure\n case Rubinius::BUILD_CONFIG[:llvm]\n when :svn, :prebuilt\n \"vm/external_libs/llvm/Release/bin/llvm-config\"\n when :config\n \"llvm-config\"\n else\n raise \"Tried... | ruby | chosen |
[
{
"from": "system",
"value": "Add a test case for invalid ENV options.\n"
},
{
"from": "human",
"value": "require 'honeybadger/config'\n\ndescribe Honeybadger::Config::Env do\n before do\n ENV['HONEYBADGER_API_KEY'] = 'asdf'\n ENV['HONEYBADGER_EXCEPTIONS_ENABLED'] = 'false'\n ENV['HONE... | ruby | chosen |
[
{
"from": "system",
"value": "Fix logging failure on jruby\n"
},
{
"from": "human",
"value": "require 'upsert/merge_function/postgresql'\n\nclass Upsert\n class MergeFunction\n # @private\n class Java_OrgPostgresqlJdbc4_Jdbc4Connection < MergeFunction\n include Postgresql\n\n de... | ruby | chosen |
[
{
"from": "system",
"value": "Fix a typo in partners section metadata\n"
},
{
"from": "human",
"value": "# Renders the home page.\nclass HomeController < ApplicationController\n def about\n @page_title = 'About us'\n @page_description = 'About MENA devs'\n @page_keywords = App... | ruby | chosen |
[
{
"from": "system",
"value": "Fix up rbenv_gem provider path\n"
},
{
"from": "human",
"value": "require 'puppet/util/execution'\n\nPuppet::Type.type(:rbenv_gem).provide(:rubygems) do\n include Puppet::Util::Execution\n desc \"\"\n\n def rbenv_gem(command)\n full_command = [\n \"sudo -... | ruby | chosen |
[
{
"from": "system",
"value": "Update API path for deleting SSH keys\n\nThe current path is incorrect (missing a '/'), resulting in a 404 whenever you try to destroy an SSH key on DigitalOcean V2."
},
{
"from": "human",
"value": "module Fog\n module Compute\n class DigitalOceanV2\n # noi... | ruby | chosen |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.