conversations
listlengths
2
3
source
stringclasses
1 value
stack
stringclasses
1 value
[ { "from": "human", "value": "Add legacy version QuickTime Player 7\n\nThis commit includes legacy QuickTime Player version 7.6.6. The DMG\ncontains the string \"SnowLeopard\", but this binary is not specific to\nSnow Leopard. It runs on any OS X from Snow Leopard through Mavericks.\n" }, { "from":...
ruby
chosen
[ { "from": "human", "value": "Add basic module for persisting order address on user\n\nTo make Spree remember user address on checkout users could include this\nmodule to their Spree.user_class or build their own implementation of\n`persist_order_address`\n" }, { "from": "gpt", "value": "module S...
ruby
chosen
[ { "from": "system", "value": "Change to absolute path in localization test\n" }, { "from": "human", "value": "require 'test_helper'\n\nclass I18nTest < Test::Unit::TestCase\n include Liquid\n\n def setup\n @i18n = I18n.new(\"./test/fixtures/en_locale.yml\")\n end\n\n def test_simple_trans...
ruby
chosen
[ { "from": "system", "value": "Check that notes show page contains text showing the note\n" }, { "from": "human", "value": "require 'spec_helper'\n\ndescribe \"notes\" do\n let(:user) { create_user! }\n before do\n create_book!\n actually_sign_in_as(user)\n end\n \n it \"can add a ne...
ruby
chosen
[ { "from": "system", "value": "Add Shell to list of supported languages\n" }, { "from": "human", "value": "class Project < ActiveRecord::Base\n attr_accessible :description, :github_url, :name, :main_language\n\n validates_presence_of :description, :github_url, :name, :main_language\n validate...
ruby
chosen
[ { "from": "human", "value": "Add OnyX cask for Snow Leopard\n" }, { "from": "gpt", "value": "class OnyxSnowleopard < Cask\n url 'http://www.titanium.free.fr/download/106/OnyX.dmg'\n homepage 'http://www.titanium.free.fr/downloadonyx.php'\n version '2.4.0'\n sha1 '5aea8cf00bd77eff95ea875daeca...
ruby
chosen
[ { "from": "system", "value": "Set default value to avoid a prompt" }, { "from": "human", "value": "module VagrantPlugins\n module Docker\n module Cap\n module Debian\n module DockerInstall\n def self.docker_install(machine, version)\n package = 'lxc-docker'\n ...
ruby
chosen
[ { "from": "system", "value": "Add encoding header for rspec support file\n" }, { "from": "human", "value": "shared_examples_for 'busca_logotipo' do\n it 'para layout padrao' do\n boleto_novo = described_class.new\n expect(File.exist?(boleto_novo.logotipo)).to be_truthy\n expect(File.st...
ruby
chosen
[ { "from": "system", "value": "Replace maruku with rdiscount for Markdown library\n" }, { "from": "human", "value": "# encoding: utf-8\nrequire File.expand_path('../lib/multi_xml/version', __FILE__)\n\nGem::Specification.new do |gem|\n gem.add_development_dependency 'maruku', '~> 0.6'\n gem.add...
ruby
chosen
[ { "from": "human", "value": "Move disableable form into usi core\n\nChange-Id: I75204b7f6349e0407d04f541b944c2c7a642d917\n" }, { "from": "gpt", "value": "class DisableableFormBuilder < ActionView::Helpers::FormBuilder\n\n def disableable_text_field(method, condition, options = {})\n disable(...
ruby
chosen
[ { "from": "system", "value": "Mark registration controller as unloadable.\n" }, { "from": "human", "value": "class RegistrationController < ApplicationController\n skip_before_filter :user_setup, :check_if_login_required\n include HttpAuthHelper\n helper :http_auth\n before_filter :autoregis...
ruby
chosen
[ { "from": "system", "value": "Add Tool classes to author image_link\n" }, { "from": "human", "value": "class AuthorDecorator < ApplicationDecorator\n decorates :user\n\n delegate_all\n\n def email\n source.try :email || \"No Email\"\n end\n\n def name\n source.try :name || \"Anonymous...
ruby
chosen
[ { "from": "system", "value": "Add explicit dependency of ruby_parser\n" }, { "from": "human", "value": "require './lib/version'\n\nGem::Specification.new do |s|\n s.name = %q{brakeman}\n s.version = Version\n s.authors = [\"Justin Collins\"]\n s.summary = \"Security vulnerability scanner for...
ruby
chosen
[ { "from": "system", "value": "Fix old spec helper path so as to require the new helper only once.\n" }, { "from": "human", "value": "require File.join(File.dirname(__FILE__), '..', 'spec_helper')\n$db = Mongo::Connection.new.db('dm-mongo-test')\ninclude DataMapper::Mongo\n" }, { "from": ...
ruby
chosen
[ { "from": "system", "value": "Revert \"Add bigdecimal to gemspec\"\n\nThis reverts commit df1a34e055ec8e13553616472f868b06372c9191.\n" }, { "from": "human", "value": "# encoding: utf-8\nrequire File.expand_path('../lib/multi_xml/version', __FILE__)\n\nGem::Specification.new do |gem|\n gem.add_d...
ruby
chosen
[ { "from": "human", "value": "Add acceptance test for openldap::server::access\n" }, { "from": "gpt", "value": "require 'spec_helper_acceptance'\n\ndescribe 'openldap::server::access define' do\n describe 'Add an ACL' do\n it 'should work with no errors' do\n pp = <<-EOS\n class {...
ruby
chosen
[ { "from": "human", "value": "Add post-commit hook for svn.\n" }, { "from": "gpt", "value": "#!/usr/bin/ruby\nrequire 'rubygems'\nrequire 'time'\nrequire 'net/http'\nrequire 'json'\n\n\n# You will need to change the following two lines\n########################\njobsworth_url = \"http://demo.getj...
ruby
chosen
[ { "from": "human", "value": "Add Firefox Beta for Chinese (Simplified)\n" }, { "from": "gpt", "value": "class FirefoxBetaCn < Cask\n url 'https://download.mozilla.org/?product=firefox-29.0b2&os=osx&lang=zh-CN'\n homepage 'https://www.mozilla.org/zh-CN/firefox/beta/'\n version '29.0b2'\n sha2...
ruby
chosen
[ { "from": "system", "value": "Make it work with arguments and stuff\n" }, { "from": "human", "value": "require \"node_module/version\"\nrequire 'live_ast/to_ruby'\nrequire 'opal'\nrequire 'v8'\n\nmodule NodeModule\n\n def self.included(base)\n base.extend ClassMethods\n end\n\n module Clas...
ruby
chosen
[ { "from": "system", "value": "Update systemu version to 2.4.2\n" }, { "from": "human", "value": "\n$:.unshift File.expand_path('../lib', __FILE__)\nrequire 'ohai/version'\n\nspec = Gem::Specification.new do |s|\n s.name = \"ohai\"\n s.version = Ohai::VERSION\n s.platform = Gem::Platform::RUBY...
ruby
chosen
[ { "from": "system", "value": "Fix typo in invoice factory.\n" }, { "from": "human", "value": "# Invoice factories\nrequire File.expand_path('../customers', __FILE__)\nrequire File.expand_path('../companies', __FILE__)\n\nFactory.define :invoice do |f|\n f.customer Factory.build(:customer)\n f....
ruby
chosen
[ { "from": "system", "value": "Implement the Code method that creates a new subclass of CodeError for a particular code\n" }, { "from": "human", "value": "# frozen_string_literal: true\n\nmodule Discordrb\n # Custom errors raised in various places\n module Errors\n # Raised when authenticati...
ruby
chosen
[ { "from": "system", "value": "Use longer title in combobox to assign referenced invoice for bookings.\n" }, { "from": "human", "value": "module InvoiceHelper\n def invoice_states_as_collection\n states = Invoice::STATES\n states.inject({}) do |result, state|\n result[t(state, :scope ...
ruby
chosen
[ { "from": "system", "value": "Fix: Insert after product properties rather than replacing them\n\nFixes #1\n" }, { "from": "human", "value": "Deface::Override.new(:virtual_path => 'spree/products/show',\n :name => 'add_social_buttons_to_products_show',\n :r...
ruby
chosen
[ { "from": "system", "value": "Update mirror, previous domain host has expired\n\nPrevious domain registration for host \"ipherswipsite.com\" has expired.\n" }, { "from": "human", "value": "cask :v1 => 'snes9x' do\n version '1.53'\n sha256 '48b0cbec848e7c2a24de1b30819dc150b62e354600cbcc0a6a5e2c...
ruby
chosen
[ { "from": "system", "value": "Update Yourkit Java Profiler to 2015-build-15054\n" }, { "from": "human", "value": "cask :v1 => 'yourkit-java-profiler' do\n version '2015-build-15050'\n sha256 'e090896ca3dc57f05221b662b7fce74fc75edfcc24aaf3a06c098f2c1dc2db8a'\n\n url \"http://www.yourkit.com/do...
ruby
chosen
[ { "from": "system", "value": "Remove unused include from RepositoryImportWorker\n" }, { "from": "human", "value": "class RepositoryImportWorker\n include Sidekiq::Worker\n include Gitlab::ShellAdapter\n include DedicatedSidekiqQueue\n\n attr_accessor :project, :current_user\n\n def perform(...
ruby
chosen
[ { "from": "system", "value": "Upgrade Qt Creator to v3.5.1\n" }, { "from": "human", "value": "cask :v1 => 'qt-creator' do\n version '3.5.0'\n sha256 '14c9e90a71679eea7d70ee1f60ba1dd5ad595415326d12a9578d0fbcdc9ecec7'\n\n url \"http://download.qt.io/official_releases/qtcreator/#{version.to_f}/#...
ruby
chosen
[ { "from": "system", "value": "Fix the asset pipleline to not precompile bower files\n" }, { "from": "human", "value": "# Be sure to restart your server when you modify this file.\n\n# Version of your assets, change this if you want to expire all your assets.\nRails.application.config.assets.vers...
ruby
chosen
[ { "from": "human", "value": "Add a new spec file for general library testing.\n" }, { "from": "gpt", "value": "require 'spec_helper'\n\ndescribe ApiVersions do\n let(:testclass) { Class.new.extend ApiVersions }\n\n it \"should raise if no vendor string is provided\" do\n expect { testclass....
ruby
chosen
[ { "from": "system", "value": "Fix 2 failling sitemap controller specs.\n" }, { "from": "human", "value": "require 'spec_helper'\n\nmodule Refinery\n describe SitemapController do\n login_refinery_user\n\n before (:each) do\n @request.env['HTTP_ACCEPT'] = 'application/xml'\n end\n\...
ruby
chosen
[ { "from": "system", "value": "Use the old type in issue_tracker instead a fix one\n\nThanks @stevecrozz to report this error\n" }, { "from": "human", "value": "class ExtractIssueTracker < Mongoid::Migration\n\n def self.up\n App.collection.find.each do |app|\n if app['issue_tracker'] &&...
ruby
chosen
[ { "from": "system", "value": "Upgrade Trailer.app to version 1.0.26\n" }, { "from": "human", "value": "class Trailer < Cask\n url 'http://dev.housetrip.com/trailer/trailer1019.zip'\n homepage 'http://dev.housetrip.com/trailer/'\n version '1.0.19'\n sha256 '651b211c0c678de0719a6535a3c2be390cf...
ruby
chosen
[ { "from": "system", "value": "Remove CSVOrganization definition from CreateOrganizationFromArray\n" }, { "from": "human", "value": "class CreateOrganizationFromArray\n\n def self.create(organization_repository, row, validate)\n new(organization_repository, row).create(validate)\n end\n\n d...
ruby
chosen
[ { "from": "system", "value": "Build instead create in label_link model spec\n" }, { "from": "human", "value": "require 'spec_helper'\n\ndescribe LabelLink, models: true do\n let(:label) { create(:label_link) }\n it { expect(label).to be_valid }\n\n it { is_expected.to belong_to(:label) }\n i...
ruby
chosen
[ { "from": "system", "value": "Fix typo: `reqire` -> `require`." }, { "from": "human", "value": "module Bundler\n class CLI::Clean\n attr_reader :options\n\n def initialize(options)\n @options = options\n end\n\n def run\n reqire_path_or_force\n Bundler.load.clean(opti...
ruby
chosen
[ { "from": "system", "value": "Use statement modifier for more concise code\n" }, { "from": "human", "value": "class Round < ActiveRecord::Base\n attr_accessible :closed, :expire_time, :max_amount, :secret_token, :url, :winning_address1, :winning_address2, :charity\n\n has_many :donations\n be...
ruby
chosen
[ { "from": "system", "value": "Add labels to seed data\n" }, { "from": "human", "value": "# Create a user\n\nuser = User.create! :name => 'Test User', :initials => 'TU',\n :email => 'test@example.com', :password => 'testpass'\nuser.confirm!\n\nproject = Project.create! :name =>...
ruby
chosen
[ { "from": "system", "value": "Increase rails_admin version in dependencies\n" }, { "from": "human", "value": "# coding: utf-8\nlib = File.expand_path('../lib', __FILE__)\n$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)\nrequire 'rails_admin_globalize_field/version'\n\nGem::Specification....
ruby
chosen
[ { "from": "system", "value": "Remove custom generator for ActiveModel\n" }, { "from": "human", "value": "# encoding: utf-8\nrequire \"rails/generators/named_base\"\nrequire \"rails/generators/active_model\"\n\nmodule Mongoid\n module Generators\n class Base < ::Rails::Generators::NamedBase\n...
ruby
chosen
[ { "from": "system", "value": "Fix stupid typo which made the plugin unusable.\n" }, { "from": "human", "value": "module HttpAuthHelper\n unloadable\n \n def user_attributes\n ['login', 'mail', 'firstname', 'lastname']\n end\n\n def use_email?\n Setting.plugin_http_auth['lookup_mode'] ...
ruby
chosen
[ { "from": "human", "value": "Add beginnings of OutdatednessChecker spec\n" }, { "from": "gpt", "value": "describe Nanoc::Int::OutdatednessChecker do\n let(:outdatedness_checker) do\n described_class.new(\n site: site,\n checksum_store: checksum_store,\n dependency_store: depen...
ruby
chosen
[ { "from": "system", "value": "Change the port to a valid one\n" }, { "from": "human", "value": "$:<< File.join(File.dirname(__FILE__), \"../lib\")\n$:<< File.join(File.dirname(__FILE__), \"../ext\")\n\nrequire 'rbkit'\n\nRbkit.start_profiling(90)\n\nclass Foo\n def initialize(name)\n @name =...
ruby
chosen
[ { "from": "system", "value": "Make log directory if not exists\n" }, { "from": "human", "value": "module Integrity\n class Configuration\n attr_reader :directory,\n :base_url,\n :builder\n\n attr_accessor :build_all,\n :auto_branch,\n :github_token,\n :log,\n ...
ruby
chosen
[ { "from": "system", "value": "Fix field order in gasmask Cask" }, { "from": "human", "value": "class GasMask < Cask\n url 'http://gmask.clockwise.ee/files/gas_mask_0.7.zip'\n version '0.7'\n homepage 'http://www.clockwise.ee/gasmask/'\n sha1 '5d0286e594a3fcc21db800105eecd78d5a92f11c'\n link...
ruby
chosen
[ { "from": "system", "value": "Fix nil exception with regex pattern group\n" }, { "from": "human", "value": "Puppet::Type.type(:rbenvgem).provide :default do\n desc \"Maintains gems inside an RBenv setup\"\n\n commands :su => 'su'\n\n def install\n args = ['install', '--no-rdoc', '--no-ri']...
ruby
chosen
[ { "from": "system", "value": "Bump equalizer and parser dependencies\n" }, { "from": "human", "value": "# -*- encoding: utf-8 -*-\n\nGem::Specification.new do |gem|\n gem.name = 'unparser'\n gem.version = '0.1.10'\n\n gem.authors = ['Markus Schirp']\n gem.email = 'mbj@schir-dso.com'...
ruby
chosen
[ { "from": "system", "value": "Use instance_exec in step definition too\n" }, { "from": "human", "value": "require 'cucumber/core_ext/string'\n\nmodule Cucumber\n # A Step Definition holds a Regexp and a Proc, and is created\n # by calling <tt>Given</tt>, <tt>When</tt> or <tt>Then</tt>\n # in ...
ruby
chosen
[ { "from": "system", "value": "Add require for sass/rails to fix font-awesome missing error\n" }, { "from": "human", "value": "require 'spree_backend'\nrequire 'spree_core'\nrequire 'coffee_script'\n\nmodule SpreeRelatedProducts\n class Engine < Rails::Engine\n engine_name 'spree_related_prod...
ruby
chosen
[ { "from": "system", "value": "Remove svn add. It is wrong when you are using git instead of svn.\n" }, { "from": "human", "value": "require 'fileutils'\nsample = File.expand_path(File.dirname(__FILE__) + \"/samples/skip_selenium_and_coverage.rake\")\nintegration = File.expand_path(RAILS_ROOT + \...
ruby
chosen
[ { "from": "human", "value": "Add an example node http server\n" }, { "from": "gpt", "value": "# run with:\n#\n# bundle exec ./bin/opal ./doc/examples/node_http_server.rb\n#\n\n%x{\n var http;\n http = require('http');\n}\n\n\nmodule HTTP\n class Server\n %x{\n var dom_class = http.S...
ruby
chosen
[ { "from": "system", "value": "Update Lo-Dash documentation to 2.4.0\n" }, { "from": "human", "value": "module Docs\n class Lodash < UrlScraper\n self.name = 'Lo-Dash'\n self.slug = 'lodash'\n self.type = 'lodash'\n self.version = '2.3.0'\n self.base_url = 'http://lodash.com/docs'...
ruby
chosen
[ { "from": "human", "value": "Add tests to check bosh resurrector config\n\nVerify that the configuration of the bosh resurrector is valid\nin the generated bosh manifest.\n\nThis commit add the first tests on the properties of this template.\n" }, { "from": "gpt", "value": "RSpec.describe \"mani...
ruby
chosen
[ { "from": "system", "value": "Enable new worker-based player for webkit browsers\n" }, { "from": "human", "value": "module AsciicastsHelper\n\n def player_script(asciicast, options = {})\n speed = (options[:speed] || 1).to_f\n benchmark = !!params[:bm]\n auto_play = options.key?(:auto_...
ruby
chosen
[ { "from": "system", "value": "Refactor attributes helpers to reduce duplication\n" }, { "from": "human", "value": "# Sequel::Model#values does not invoke deserializers\nmodule Sequel\n module Plugins\n module AttributesHelpers\n module InstanceMethods\n def allowed_attributes\n ...
ruby
chosen
[ { "from": "system", "value": "Mark failing spec for raiffeisen importer as pending.\n" }, { "from": "human", "value": "require 'spec_helper'\nrequire 'raiffeisen_importer'\n\ndescribe RaiffeisenImporter do\n before(:each) do\n @csv_simple = File.dirname(__FILE__) + '/csvs/simple.csv'\n @c...
ruby
chosen
[ { "from": "system", "value": "Disable generation of helpers and assets.\n" }, { "from": "human", "value": "require File.expand_path('../boot', __FILE__)\n\nrequire 'rails/all'\n\n# Require the gems listed in Gemfile, including any gems\n# you've limited to :test, :development, or :production.\nB...
ruby
chosen
[ { "from": "system", "value": "Fix passed-in formula name to match the class name\n" }, { "from": "human", "value": "class Testball < Formula\n def initialize(name=\"test_ball\", path=Pathname.new(__FILE__).expand_path, spec=:stable)\n self.class.instance_eval do\n stable.url \"file://#{...
ruby
chosen
[ { "from": "system", "value": "[CS] Switch to named regex captures\n\nMore readable regex matches" }, { "from": "human", "value": "require 'cgi'\n\nmodule RubyAMI\n class AGIResultParser\n attr_reader :code, :result, :data\n\n FORMAT = /^(\\d{3}) result=(-?\\d*) ?(\\(?.*\\)?)?$/.f...
ruby
chosen
[ { "from": "system", "value": "Upgrade armrest gem to 0.7.3.\n" }, { "from": "human", "value": "$:.push File.expand_path(\"../lib\", __FILE__)\n\nrequire \"manageiq/providers/azure/version\"\n\nGem::Specification.new do |s|\n s.name = \"manageiq-providers-azure\"\n s.version = Manage...
ruby
chosen
[ { "from": "system", "value": "Update podspec to a new minor version 0.1.3" }, { "from": "human", "value": "Pod::Spec.new do |s|\n s.name = \"GTScrollNavigationBar\"\n s.version = \"0.1.2\"\n s.summary = \"A scrollable UINavigationBar that follows a UIScrollView\"\n s.homepa...
ruby
chosen
[ { "from": "system", "value": "Mark broken spec as pending\n" }, { "from": "human", "value": "require 'spec_helper'\nrequire 'rom/lint/spec'\nrequire 'rom/memory'\n\ndescribe ROM::Memory::Repository do\n before(:context) do\n # FIXME: Remove when we get a way to control registration in specs\...
ruby
chosen
[ { "from": "system", "value": "Make sure locale path is absolute - the app code is called from within crons etc.\n" }, { "from": "human", "value": "FastGettext.add_text_domain 'app', :path => 'locale', :type => :po\nFastGettext.default_available_locales = ['en'] #all you want to allow\nFastGettex...
ruby
chosen
[ { "from": "system", "value": "Fix warnings spy so it doesn't capture more things than necessary\n" }, { "from": "human", "value": "class WarningsSpy\n class Reader\n attr_reader :warning_groups\n\n def initialize(filesystem)\n @warnings_file = filesystem.warnings_file\n\n @recor...
ruby
chosen
[ { "from": "human", "value": "Update domain_id primary and foreign keys to bigint\n" }, { "from": "gpt", "value": "class ChangeDomainIdToBigint < ActiveRecord::Migration[6.0]\n def up\n change_column :domains, :id, :bigint\n\n change_column :domain_options, :domain_id, :bigint\n change_...
ruby
chosen
[ { "from": "system", "value": "Fix deprecated include_class rspec-puppet syntax\n" }, { "from": "human", "value": "require \"spec_helper\"\n\ndescribe \"homebrew::repo\" do\n let(:facts) { default_test_facts }\n\n it do\n should include_class(\"homebrew\")\n end\nend\n" }, { "from":...
ruby
chosen
[ { "from": "system", "value": "Remove the URL from issues' summary_message.\n\nPlugins using summary_message should display summary_url too.\n" }, { "from": "human", "value": "module Service::IssueHelpers\n include Service::HelpersWithMeta,\n Service::HelpersWithActions\n\n def issue\n @i...
ruby
chosen
[ { "from": "system", "value": "Use RackRequest for all Rack::Request derived classes.\n" }, { "from": "human", "value": "require_relative 'base'\n\nrequire_relative 'hash_request'\nrequire_relative 'legacy_request'\nrequire_relative 'rack_request'\n\nmodule Escher\n module Request\n class Fac...
ruby
chosen
[ { "from": "human", "value": "Write specs for software controller.\n" }, { "from": "gpt", "value": "require 'spec_helper'\n\ndescribe SoftwaresController do\n before(:each) do\n @current_user = FactoryGirl.create :user\n controller.session[:user_id] = @current_user.id\n create(:machine,...
ruby
chosen
[ { "from": "system", "value": "Fix path to logs, gs\n\nSee https://github.com/jadb/capcake/commit/adddace56d61dfecb66c72a7b1a51c15fd490515\n" }, { "from": "human", "value": "set_if_empty :cakephp_roles, :all\nset_if_empty :cakephp_flags, ''\nset_if_empty :cakephp_user, :local_user\n\nset_if_empty...
ruby
chosen
[ { "from": "system", "value": "Upgrade Hedgewars.app to v0.9.21 and license to GPL\n\nLicense source: https://github.com/hedgewars/hw/blob/master/README\n" }, { "from": "human", "value": "cask :v1 => 'hedgewars' do\n version '0.9.20'\n sha256 '167667f32f4798733b7bfd50423493067e6a9fd19f02f45e737...
ruby
chosen
[ { "from": "human", "value": "Add TwentyTwo.app latest with `sha256 :no_check`\n" }, { "from": "gpt", "value": "class Twentytwo < Cask\n url 'https://github.com/marcw/twentytwo/raw/master/dist/TwentyTwo.dmg'\n homepage 'https://github.com/marcw/twentytwo'\n version 'latest'\n sha256 :no_check...
ruby
chosen
[ { "from": "system", "value": "Change tooo heavy query method\n" }, { "from": "human", "value": "module Adhoq\n class Report < ActiveRecord::Base\n BUFSIZE = 10.kilobytes.to_i\n\n belongs_to :execution\n\n delegate :name, to: 'execution'\n delegate :mime_type, to: :reporter\n\n ...
ruby
chosen
[ { "from": "system", "value": "Use a slightly larger sample for homepage data\n" }, { "from": "human", "value": "class StaticController < ApplicationController\n def homepage\n redirect_to dashboard_path() if logged_in?\n\n @projects = Project.limit(100).sample(12).sort_by(&:name)\n @us...
ruby
chosen
[ { "from": "system", "value": "Upgrade Android Studio.app to v0.8.2 build-135.1267975\n" }, { "from": "human", "value": "class AndroidStudio < Cask\n version '0.8.1 build-135.1248636'\n sha256 '1ed112d2d6230b88c57a29ceda59ff473e6c0005e5e371f4480c93e7187c3567'\n\n url 'https://dl.google.com/dl/...
ruby
chosen
[ { "from": "human", "value": "Write spec for the user show route.\n\nThis will alert maintainers if there is a chance the All Contributors view\nbreaks due to a routing change.\n" }, { "from": "gpt", "value": "require 'spec_helper'\n\ndescribe 'user routes' do\n context 'to show a user' do\n ...
ruby
chosen
[ { "from": "system", "value": "Format Command Line Tools Mountain Lion\n" }, { "from": "human", "value": "class CommandLineToolsMountainLion < Cask\n url 'http://devimages.apple.com/downloads/xcode/command_line_tools_for_osx_mountain_lion_april_2014.dmg'\n homepage 'https://developer.apple.com/...
ruby
chosen
[ { "from": "system", "value": "Add link to the now dead Camino browser\n" }, { "from": "human", "value": "class Camino < Cask\n url 'http://download.cdn.mozilla.net/pub/mozilla.org/camino/releases/en-US/Camino-2.1.2.dmg'\n homepage 'http://caminobrowser.org/'\n version '2.1.2'\n sha1 '092dae4...
ruby
chosen
[ { "from": "human", "value": "Add a cask-file for the InSync.app\n" }, { "from": "gpt", "value": "class Insync < Cask\n url 'http://s.insynchq.com/builds/Insync-1.0.11.31522.dmg'\n homepage 'http://insynchq.com/'\n version '1.0.11.31522'\n sha1 'fe311fc627bcba5ee6516a25298ce3514eaae745'\n li...
ruby
chosen
[ { "from": "system", "value": "Fix homepage to use SSL in Clementine Cask\n\nThe HTTP URL is already getting redirected to HTTPS. Using the HTTPS URL directly\nmakes it more secure and saves a HTTP round-trip.\n" }, { "from": "human", "value": "cask :v1 => 'clementine' do\n version '1.2.2'\n sh...
ruby
chosen
[ { "from": "human", "value": "Add acceptance test outline for signing CCLAs\n" }, { "from": "gpt", "value": "require 'spec_feature_helper'\n\ndescribe 'signing a CCLA' do\n\n it 'establishes the signer as an admin of the organization' do\n sign_in\n sign_ccla_as(\"Opscode\")\n visit_pro...
ruby
chosen
[ { "from": "system", "value": "Set config.eager_load to false for dummy app\n" }, { "from": "human", "value": "Dummy::Application.configure do\n # Settings specified here will take precedence over those in config/application.rb\n\n # The test environment is used exclusively to run your applicat...
ruby
chosen
[ { "from": "system", "value": "Add a test for error_class_for\n" }, { "from": "human", "value": "require 'discordrb'\n\ndescribe Discordrb::Errors do\n describe 'the Code method' do\n it 'should create a class without errors' do\n Discordrb::Errors.Code(10_000)\n end\n\n describe '...
ruby
chosen
[ { "from": "system", "value": "Change the default route to the housing forms index\n\nNevermind login for now. We can worry about that when the site starts making\nPDFs for people.\n" }, { "from": "human", "value": "DchousingApps::Application.routes.draw do\n devise_for :users\n\n resources :b...
ruby
chosen
[ { "from": "system", "value": "Validate dates in Person model.\n" }, { "from": "human", "value": "class Person < ActiveRecord::Base\n # Associations\n has_many :vcards, :as => :object\n has_one :vcard, :as => :object\n\n accepts_nested_attributes_for :vcard\n\n # Constructor\n def initializ...
ruby
chosen
[ { "from": "system", "value": "Update CLion EAP to 138.2344.17\n" }, { "from": "human", "value": "class ClionEap < Cask\n version '138.1965.18'\n sha256 'c5c57019141de3369aa62a44d94ee5a410956a9fa88e88d91dd898863da3042f'\n\n url \"http://download.jetbrains.com/cpp/CLion-#{version}.dmg\"\n home...
ruby
chosen
[ { "from": "system", "value": "Set default order to :random\n" }, { "from": "human", "value": "require 'rails/all'\n\nmodule RSpecRails\n class Application < ::Rails::Application\n end\nend\n\nrequire 'rspec/rails'\nrequire 'ammeter/init'\n\nDir[\"#{File.dirname(__FILE__)}/support/**/*.rb\"].ea...
ruby
chosen
[ { "from": "system", "value": "Add original hashes for recently added Deface overrides.\n" }, { "from": "human", "value": "Deface::Override.new(:virtual_path => \"spree/orders/_form\",\n :replace => \"tr.cart-total\",\n :name => \"cart_total\",...
ruby
chosen
[ { "from": "system", "value": "Revert a Rails 3 Router API change because of failing tests\n\nSigned-off-by: Alex Coles <60c6d277a8bd81de7fdde19201bf9c58a3df08f4@alexcolesportfolio.com>\n" }, { "from": "human", "value": "Rails::Application.routes.draw do\n namespace(:admin) do\n resources :da...
ruby
chosen
[ { "from": "system", "value": "Fix fallback if atomic can't be required.\n" }, { "from": "human", "value": "module ThreadSafe\n module Util\n AtomicReference =\n if defined?(Rubinius::AtomicReference)\n # An overhead-less atomic reference.\n Rubinius::AtomicReference\n ...
ruby
chosen
[ { "from": "system", "value": "Fix spec matcher to support Rails 3.0 and 3.1\n" }, { "from": "human", "value": "RSpec::Matchers.define :perform_queries do |expected|\n supports_block_expectations\n\n match do |block|\n query_count(&block) == expected\n end\n\n failure_message do |actual|\n...
ruby
chosen
[ { "from": "system", "value": "Tag some failures towards greening some ci runs\n" }, { "from": "human", "value": "# NOTE: these are copied to AR-JDBC's suite with proper (JVM) TZ adjustment\nexclude :test_preserving_time_objects_with_utc_time_conversion_to_default_timezone_local, 'assuming ENV[TZ...
ruby
chosen
[ { "from": "system", "value": "Clean up ValidatesNumericalityOfMatcher a bit.\n" }, { "from": "human", "value": "module Shoulda # :nodoc:\n module Matchers\n module ActiveModel # :nodoc:\n\n # Ensure that the attribute is numeric\n #\n # Options:\n # * <tt>with_message</tt...
ruby
chosen
[ { "from": "system", "value": "[backend] Correct translations in locale spec\n" }, { "from": "human", "value": "require 'spec_helper'\n\ndescribe \"setting locale\" do\n stub_authorization!\n\n before do\n I18n.locale = I18n.default_locale\n I18n.backend.store_translations(:fr, {\n :o...
ruby
chosen
[ { "from": "human", "value": "Add specs for CI/CD job policy factory method\n" }, { "from": "gpt", "value": "require 'spec_helper'\n\ndescribe Gitlab::Ci::Build::Policy do\n let(:policy) { spy('policy specification') }\n\n before do\n stub_const(\"#{described_class}::Something\", policy)\n ...
ruby
chosen
[ { "from": "system", "value": "Fix Ruby 1.8.7 break caused by class reloading and preventing stub\n" }, { "from": "human", "value": "#\n# Author:: Joseph Anthony Pasquale Holsten (<joseph@josephholsten.com>)\n# Copyright:: Copyright (c) 2013 Joseph Anthony Pasquale Holsten\n# License:: Apache Lic...
ruby
chosen
[ { "from": "system", "value": "Clone wrapper_html options before modifying it.\n\nA passing test.\n" }, { "from": "human", "value": "module Formtastic\n module Inputs\n module Base\n # @todo relies on `dom_id`, `required?`, `optional`, `errors?`, `association_primary_key` & `sanitized_me...
ruby
chosen
[ { "from": "system", "value": "Make watcher test case kill watcher thread to avoid garbage output\n" }, { "from": "human", "value": "# encoding: utf-8\n\nclass Nanoc::CLI::Commands::WatchTest < MiniTest::Unit::TestCase\n\n include Nanoc::TestHelpers\n\n def setup\n super\n @@warned ||= be...
ruby
chosen
[ { "from": "system", "value": "Fix IntellijIdea to use double quotes\n" }, { "from": "human", "value": "class IntellijIdea < Cask\n version '13.1.4'\n sha256 'be5ca65ab5b169ac66f47f02f49d5d9359935c9f56140327a32f9da555d845bb'\n\n url 'http://download-cf.jetbrains.com/idea/ideaIU-#{version}.dmg'...
ruby
chosen
[ { "from": "system", "value": "Use secrets.db_key_base instead of config.secret_key_base\n" }, { "from": "human", "value": "# == Schema Information\n#\n# Table name: variables\n#\n# id :integer not null, primary key\n# project_id :integer not null\n...
ruby
chosen