diff
stringlengths
65
26.7k
message
stringlengths
7
9.92k
diff --git a/metadata.rb b/metadata.rb index abc1234..def5678 100644 --- a/metadata.rb +++ b/metadata.rb @@ -4,4 +4,4 @@ license "Apache 2.0" description "System Software configuration and maintenance" long_description IO.read(File.join(File.dirname(__FILE__), 'README.md')) -version "0.41.3" +v...
Split account databag handling into a separate recipe
diff --git a/tools/upload-to-github.rb b/tools/upload-to-github.rb index abc1234..def5678 100644 --- a/tools/upload-to-github.rb +++ b/tools/upload-to-github.rb @@ -26,5 +26,17 @@ :size => File.size(file), :description => File.basename...
Use curl instead of github_api Because github_api's upload doesn't work... :<
diff --git a/lib/dm-predefined/predefined.rb b/lib/dm-predefined/predefined.rb index abc1234..def5678 100644 --- a/lib/dm-predefined/predefined.rb +++ b/lib/dm-predefined/predefined.rb @@ -28,13 +28,13 @@ end def define(name,attributes={}) - name = name.to_sym + name = name.to_s - ...
Use better escaping of Strings when defining methods.
diff --git a/lib/method_found/interceptor.rb b/lib/method_found/interceptor.rb index abc1234..def5678 100644 --- a/lib/method_found/interceptor.rb +++ b/lib/method_found/interceptor.rb @@ -1,6 +1,14 @@ module MethodFound class Interceptor < Module - def initialize(regex, &intercept_block) + attr_reader :regex ...
Refactor define methods into their own methods
diff --git a/db/migrate/20160412032842_add_email_uniqueness_index.rb b/db/migrate/20160412032842_add_email_uniqueness_index.rb index abc1234..def5678 100644 --- a/db/migrate/20160412032842_add_email_uniqueness_index.rb +++ b/db/migrate/20160412032842_add_email_uniqueness_index.rb @@ -1,4 +1,5 @@ class AddEmailUniquenes...
Add Unit test validation User
diff --git a/lib/rrj/models/active_record.rb b/lib/rrj/models/active_record.rb index abc1234..def5678 100644 --- a/lib/rrj/models/active_record.rb +++ b/lib/rrj/models/active_record.rb @@ -16,7 +16,7 @@ self.primary_key = :id alias_attribute :instance, :id - alias_attribute :name, ...
Change alias with field name
diff --git a/lib/snapme/imagesnap_command.rb b/lib/snapme/imagesnap_command.rb index abc1234..def5678 100644 --- a/lib/snapme/imagesnap_command.rb +++ b/lib/snapme/imagesnap_command.rb @@ -1,7 +1,7 @@ module Snapme class ImagesnapCommand def call(filename) - `#{command_name} #{filename}` + system(comm...
Use system method rather than ticks for shell out * Seems to be a little more clear and doens't require string interpolation for arguments
diff --git a/runner.rb b/runner.rb index abc1234..def5678 100644 --- a/runner.rb +++ b/runner.rb @@ -13,24 +13,51 @@ Dotenv.load -environment = ENV.fetch('ENVIRONMENT') +def main + environment = ENV.fetch('ENVIRONMENT') -database_connection = Mysql2::Client.new(DatabaseConfig.for(environment)) + database_connec...
Add retries for the initial MySQL connection.
diff --git a/config.ru b/config.ru index abc1234..def5678 100644 --- a/config.ru +++ b/config.ru @@ -7,7 +7,40 @@ require 'prometheus/middleware/exporter' use Rack::Deflater, if: ->(_, _, _, body) { body.respond_to?( :map ) && body.map(&:bytesize).reduce(0, :+) > 512 } -use Prometheus::Middleware::Collector use Pro...
Update Prometheus metrics capture to keep path cardinality down and stop a metrics explosion
diff --git a/app/controllers/refinery/retailers/admin/retailers_controller.rb b/app/controllers/refinery/retailers/admin/retailers_controller.rb index abc1234..def5678 100644 --- a/app/controllers/refinery/retailers/admin/retailers_controller.rb +++ b/app/controllers/refinery/retailers/admin/retailers_controller.rb @@ ...
Set paging to false for Admin::RetailersController
diff --git a/app/controllers/solidus_paypal_braintree/checkouts_controller.rb b/app/controllers/solidus_paypal_braintree/checkouts_controller.rb index abc1234..def5678 100644 --- a/app/controllers/solidus_paypal_braintree/checkouts_controller.rb +++ b/app/controllers/solidus_paypal_braintree/checkouts_controller.rb @@ ...
Stop using deprecated payment create Solidus now expects us to use a PaymentCreate class instead of assigning the source attributes via magic.
diff --git a/db/migrate/20170217081027_add_partial_index_to_scores.rb b/db/migrate/20170217081027_add_partial_index_to_scores.rb index abc1234..def5678 100644 --- a/db/migrate/20170217081027_add_partial_index_to_scores.rb +++ b/db/migrate/20170217081027_add_partial_index_to_scores.rb @@ -1,5 +1,6 @@ class AddPartialInd...
Add an `algorithm: concurrently` to our scores partial index Fixes CNVS-35193 Test plan: * specs pass Change-Id: I1a9ca04c8b1f9c82f3b9a9769611da3df79e4205 Reviewed-on: https://gerrit.instructure.com/103040 Tested-by: Jenkins Reviewed-by: Cody Cutrer <c4fe2b1d90ef8f2548c8aeabfa633434316f0305@instructure.com> Product-...
diff --git a/spec/lib/sessions/backend/activity_stream_spec.rb b/spec/lib/sessions/backend/activity_stream_spec.rb index abc1234..def5678 100644 --- a/spec/lib/sessions/backend/activity_stream_spec.rb +++ b/spec/lib/sessions/backend/activity_stream_spec.rb @@ -17,8 +17,9 @@ end it 'manages race condition' do...
Test stabilization: Unjoined threads lead to stuck test suite.
diff --git a/spec/presenters/redetermination_presenter_spec.rb b/spec/presenters/redetermination_presenter_spec.rb index abc1234..def5678 100644 --- a/spec/presenters/redetermination_presenter_spec.rb +++ b/spec/presenters/redetermination_presenter_spec.rb @@ -1,20 +1,13 @@ require 'rails_helper' describe Redetermin...
Remove "created_at" spec because its no longer in the presenter nor is it actually used
diff --git a/code/english_to_numbers.rb b/code/english_to_numbers.rb index abc1234..def5678 100644 --- a/code/english_to_numbers.rb +++ b/code/english_to_numbers.rb @@ -0,0 +1,16 @@+ + + + + +def engToNum word + + # need to make sure it is a string in the array + if word + +intNum - '' + +onesWords = {'one' => 1 , 'tw...
Set up of engToNum -> english words returning integers
diff --git a/app/controllers/pages_controller.rb b/app/controllers/pages_controller.rb index abc1234..def5678 100644 --- a/app/controllers/pages_controller.rb +++ b/app/controllers/pages_controller.rb @@ -7,6 +7,8 @@ raise ActionController::RoutingError.new('Not Found') else logger.error("[Fores...
Add page--404 class to body_classes when rendering page not found
diff --git a/app/controllers/users_controller.rb b/app/controllers/users_controller.rb index abc1234..def5678 100644 --- a/app/controllers/users_controller.rb +++ b/app/controllers/users_controller.rb @@ -7,6 +7,7 @@ user = User.new(user_params) if user.save + session[:user_id] = user.id flash[:n...
Add new user's id to session
diff --git a/app/models/people_network.rb b/app/models/people_network.rb index abc1234..def5678 100644 --- a/app/models/people_network.rb +++ b/app/models/people_network.rb @@ -17,8 +17,12 @@ # end def self.create_trust!(first_person, second_person) - PeopleNetwork.create!(:person => first_person, :trusted_pe...
Add enitiy id to people network when trust is established
diff --git a/app/helpers/google_vision_helper.rb b/app/helpers/google_vision_helper.rb index abc1234..def5678 100644 --- a/app/helpers/google_vision_helper.rb +++ b/app/helpers/google_vision_helper.rb @@ -1,10 +1,41 @@ module GoogleVisionHelper + require 'googleauth' require 'google/apis/vision_v1' + require '...
Add module that identifies cats using Google vision
diff --git a/site-cookbooks/nan-base/definitions/default.rb b/site-cookbooks/nan-base/definitions/default.rb index abc1234..def5678 100644 --- a/site-cookbooks/nan-base/definitions/default.rb +++ b/site-cookbooks/nan-base/definitions/default.rb @@ -16,6 +16,13 @@ system true end + group 'docker' do + actio...
Add staff users to the docker group
diff --git a/site-cookbooks/zabbix_part/spec/spec_helper.rb b/site-cookbooks/zabbix_part/spec/spec_helper.rb index abc1234..def5678 100644 --- a/site-cookbooks/zabbix_part/spec/spec_helper.rb +++ b/site-cookbooks/zabbix_part/spec/spec_helper.rb @@ -1,4 +1,5 @@ # Added by ChefSpec +require 'chef' require 'chefspec' re...
Add dependency on Chef::Resource.identity_attr when run chefspec
diff --git a/app/models/instance.rb b/app/models/instance.rb index abc1234..def5678 100644 --- a/app/models/instance.rb +++ b/app/models/instance.rb @@ -20,5 +20,5 @@ has_many :instance_users has_many :users, through: :instance_users - has_many :announcements, class_name: Announcement.name + has_many :announce...
Fix bug in Instance model
diff --git a/spec/github/git_data/references/delete_spec.rb b/spec/github/git_data/references/delete_spec.rb index abc1234..def5678 100644 --- a/spec/github/git_data/references/delete_spec.rb +++ b/spec/github/git_data/references/delete_spec.rb @@ -21,8 +21,10 @@ it { should respond_to :remove } + it { expec...
Add test for lack of arguments.
diff --git a/db/migrate/20150202171723_add_destroy_labware.rb b/db/migrate/20150202171723_add_destroy_labware.rb index abc1234..def5678 100644 --- a/db/migrate/20150202171723_add_destroy_labware.rb +++ b/db/migrate/20150202171723_add_destroy_labware.rb @@ -2,7 +2,7 @@ def self.up ActiveRecord::Base.transaction d...
Use nice labware destruction name
diff --git a/config/initializers/aws.rb b/config/initializers/aws.rb index abc1234..def5678 100644 --- a/config/initializers/aws.rb +++ b/config/initializers/aws.rb @@ -1,8 +1,8 @@ AssetManager.aws_s3_bucket_name = if Rails.env.production? - ENV.fetch('AWS_S3_BUCKET_NAME') -else - ENV['AWS_S3_BUCKET_NAME'] -end + ...
Fix some Rubocop offences & warnings in AWS config I was seeing the following locally: * Layout/IndentationWidth * Layout/ElseAlignment * Lint/EndAlignment For some reason these were not picked up by the Jenkins CI build of the master branch. I plan to investigate why this didn't happen separately.
diff --git a/test/sample_test.rb b/test/sample_test.rb index abc1234..def5678 100644 --- a/test/sample_test.rb +++ b/test/sample_test.rb @@ -0,0 +1,21 @@+require 'test_helper' + +class Chelsy::SampleTest < Minitest::Test + SAMPLE_DIR = File.expand_path('../../sample/', __FILE__) + + def test_hello + validate_gener...
Add tests to validate sample files
diff --git a/lib/ajimi/server.rb b/lib/ajimi/server.rb index abc1234..def5678 100644 --- a/lib/ajimi/server.rb +++ b/lib/ajimi/server.rb @@ -22,6 +22,7 @@ def find(dir, find_max_depth = nil) cmd = "sudo find #{dir} -ls" cmd += " -maxdepth #{find_max_depth}" if find_max_depth + cmd += " -path /dev...
Exclude /dev and /proc from find
diff --git a/Casks/dwarf-fortress-macnewbie.rb b/Casks/dwarf-fortress-macnewbie.rb index abc1234..def5678 100644 --- a/Casks/dwarf-fortress-macnewbie.rb +++ b/Casks/dwarf-fortress-macnewbie.rb @@ -1,6 +1,6 @@ cask :v1 => 'dwarf-fortress-macnewbie' do - version '0.9.9' - sha256 'ca04045341330e2258e1eedf296eefa2b5fe339...
Update Dwarf Fortress MacNewbie to 0.9.16a.
diff --git a/test/test_helper.rb b/test/test_helper.rb index abc1234..def5678 100644 --- a/test/test_helper.rb +++ b/test/test_helper.rb @@ -1,10 +1,10 @@ require 'bundler/setup' -require 'minitest/autorun' +require 'test/unit' require 'ventana' # Remove deprecation warning I18n.enforce_available_locales = true ...
Switch to test/unit for compatibility
diff --git a/test/test_helper.rb b/test/test_helper.rb index abc1234..def5678 100644 --- a/test/test_helper.rb +++ b/test/test_helper.rb @@ -13,7 +13,13 @@ :database => "activerecord_metal" ) -metal = ActiveRecord::Metal.new +metal = begin + ActiveRecord::Metal.new +rescue ActiveRecord::NoDatabaseError + STDERR....
Print warning if test database is missing.
diff --git a/test/test_job_vn.rb b/test/test_job_vn.rb index abc1234..def5678 100644 --- a/test/test_job_vn.rb +++ b/test/test_job_vn.rb @@ -1,3 +1,4 @@+# frozen_string_literal: true # encoding: UTF-8 require 'helper'
Add frozen string literal comment for test
diff --git a/server.rb b/server.rb index abc1234..def5678 100644 --- a/server.rb +++ b/server.rb @@ -1,20 +1,23 @@-require 'sinatra' +require 'sinatra/base' require './models/student' -get '/hi' do - "Hello world!" -end +class StudentPinMap < Sinatra::Application + set :bind, '0.0.0.0' -get '/' do - @student...
Switch to modular sinatra style (subclass `Sinatra::Application`)
diff --git a/spec/attr_inject/core_ext_spec.rb b/spec/attr_inject/core_ext_spec.rb index abc1234..def5678 100644 --- a/spec/attr_inject/core_ext_spec.rb +++ b/spec/attr_inject/core_ext_spec.rb @@ -20,6 +20,11 @@ end +class BlankClass + def initialize + end +end + describe "attr_inject" do it "creates a method...
Test case where no injection targets are defined
diff --git a/spec/integration/cookbook_spec.rb b/spec/integration/cookbook_spec.rb index abc1234..def5678 100644 --- a/spec/integration/cookbook_spec.rb +++ b/spec/integration/cookbook_spec.rb @@ -2,15 +2,15 @@ describe 'sprout-ruby' do before :all do - expect(File).not_to be_exists('/etc/gemrc') + expect(Fi...
Fix integration tests for local .gemrc installation
diff --git a/spec/models/spree/bp_hook_spec.rb b/spec/models/spree/bp_hook_spec.rb index abc1234..def5678 100644 --- a/spec/models/spree/bp_hook_spec.rb +++ b/spec/models/spree/bp_hook_spec.rb @@ -21,7 +21,9 @@ expect(@all.second['subscribeTo']).to eq 'product.modified' end - it 'sets product.destroyed ...
Set peding failing test due to brightpearl bug
diff --git a/spec/slow_shared_examples_spec.rb b/spec/slow_shared_examples_spec.rb index abc1234..def5678 100644 --- a/spec/slow_shared_examples_spec.rb +++ b/spec/slow_shared_examples_spec.rb @@ -1,8 +1,23 @@+RSpec.shared_context "shared stuff", :shared_context => :metadata do + before do + sleep 1 + end +end + ...
Add example of include_context impacting the recorded timing
diff --git a/app/mailers/invite_people_mailer.rb b/app/mailers/invite_people_mailer.rb index abc1234..def5678 100644 --- a/app/mailers/invite_people_mailer.rb +++ b/app/mailers/invite_people_mailer.rb @@ -5,7 +5,7 @@ @group = @invitation.group @message_body = message_body send_single_mail to: @invit...
Fix locales for invite people emails
diff --git a/app/models/api/v3/area_presenter.rb b/app/models/api/v3/area_presenter.rb index abc1234..def5678 100644 --- a/app/models/api/v3/area_presenter.rb +++ b/app/models/api/v3/area_presenter.rb @@ -9,6 +9,7 @@ analysis_year area base_dataset + derived geo_id gro...
Include "derived" with sparse area data
diff --git a/messaging.gemspec b/messaging.gemspec index abc1234..def5678 100644 --- a/messaging.gemspec +++ b/messaging.gemspec @@ -1,7 +1,7 @@ # -*- encoding: utf-8 -*- Gem::Specification.new do |s| s.name = 'messaging' - s.version = '0.1.0.0' + s.version = '0.2.0.0' s.summary = 'Messaging primitives for Eve...
Package version increased from 0.1.0.0 to 0.2.0.0
diff --git a/lib/csvconverter.rb b/lib/csvconverter.rb index abc1234..def5678 100644 --- a/lib/csvconverter.rb +++ b/lib/csvconverter.rb @@ -8,9 +8,9 @@ rescue LoadError puts "Failed to load #{CSVGEM} (ruby #{RUBY_VERSION})" puts "gem install #{CSVGEM}" - exit + abort end CSVParserClass = CSVGEM == 'csv' ? CSV ...
Change exit by abort to exit properly in require during tests
diff --git a/spec/scanny/checks/system_tools/gpg_usage_check_spec.rb b/spec/scanny/checks/system_tools/gpg_usage_check_spec.rb index abc1234..def5678 100644 --- a/spec/scanny/checks/system_tools/gpg_usage_check_spec.rb +++ b/spec/scanny/checks/system_tools/gpg_usage_check_spec.rb @@ -12,12 +12,24 @@ @runner.shoul...
Test all popular libs for ruby related to GPG
diff --git a/blz.gemspec b/blz.gemspec index abc1234..def5678 100644 --- a/blz.gemspec +++ b/blz.gemspec @@ -5,7 +5,7 @@ Gem::Specification.new do |s| s.name = 'blz' - s.version = '0.1.2' + s.version = '0.1.3' s.platform = Gem::Platform::RUBY s.summary = "BLZ (Bank...
Prepare for new version on rubygems
diff --git a/lib/namesies/cli.rb b/lib/namesies/cli.rb index abc1234..def5678 100644 --- a/lib/namesies/cli.rb +++ b/lib/namesies/cli.rb @@ -9,15 +9,18 @@ def search(q) puts "Searching for #{q}..." puts "\n" + + services = Namesies.constants - [:VERSION, :CLI, :Reporter] + if options[:only...
Rework the way services are searched so except is no longer required.
diff --git a/Auk.podspec b/Auk.podspec index abc1234..def5678 100644 --- a/Auk.podspec +++ b/Auk.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = "Auk" - s.version = "5.0.0" + s.version = "6.0.0" s.license = { :type => "MIT" } s.homepage = "https://github.com/evgenyneu/Auk" s.su...
Update to xcode 8 beta 6
diff --git a/ja.rb b/ja.rb index abc1234..def5678 100644 --- a/ja.rb +++ b/ja.rb @@ -0,0 +1,48 @@+#!/usr/bin/env ruby +# encoding: UTF-8 +require 'prawn' +require 'base64' +require 'open-uri' +# Third party gem that will need installing +require 'zip' +require 'fileutils' + +ipa_2_fonts = 'IPAexfont00201.zip' +open(ipa...
Add test file: must be removed later
diff --git a/app.rb b/app.rb index abc1234..def5678 100644 --- a/app.rb +++ b/app.rb @@ -10,7 +10,7 @@ options[:min_length] = 4 opts.on('-m', '--min LENGTH', 'Minimum length of palindrome') do |v| - options[:min_length] = v + options[:min_length] = v.to_i end opts.on('-h', '--help', 'Show this mess...
Convert min_length option to integer
diff --git a/test/orm_ext/mongo_mapper_test.rb b/test/orm_ext/mongo_mapper_test.rb index abc1234..def5678 100644 --- a/test/orm_ext/mongo_mapper_test.rb +++ b/test/orm_ext/mongo_mapper_test.rb @@ -11,6 +11,19 @@ should "be able to find the object in the database" do assert_equal @person, MongoMapperPerson._t...
Add another mongo mapper extension test
diff --git a/simple_xlsx_reader.gemspec b/simple_xlsx_reader.gemspec index abc1234..def5678 100644 --- a/simple_xlsx_reader.gemspec +++ b/simple_xlsx_reader.gemspec @@ -16,10 +16,11 @@ gem.add_dependency 'rubyzip' gem.add_development_dependency 'minitest', '>= 5.0' + gem.add_development_dependency 'rake' gem...
Add rake as dev dependency for travis-ci
diff --git a/font-awesome-middleman.gemspec b/font-awesome-middleman.gemspec index abc1234..def5678 100644 --- a/font-awesome-middleman.gemspec +++ b/font-awesome-middleman.gemspec @@ -17,7 +17,7 @@ gem.test_files = gem.files.grep(%r{^(test|spec|features)/}) gem.require_paths = ["lib"] - gem.add_runtime_depe...
Adjust middleman dependency to >= 3.0.0
diff --git a/lib/time_records.rb b/lib/time_records.rb index abc1234..def5678 100644 --- a/lib/time_records.rb +++ b/lib/time_records.rb @@ -7,23 +7,11 @@ end def grouped_by_task - uniques = map(&:task_id).uniq - - uniques.map do |task_id| - same = select { |record| record.task_id == task_id } - - ...
Refactor and shorten grouping time records code
diff --git a/lib/dimples/renderable.rb b/lib/dimples/renderable.rb index abc1234..def5678 100644 --- a/lib/dimples/renderable.rb +++ b/lib/dimples/renderable.rb @@ -2,7 +2,7 @@ module Renderable def render(context = {}, body = nil) context[:site] ||= @site - context.merge!(type => Hashie::Mash.new(@m...
Set the context item direct instead of merging it
diff --git a/app/workers/folder_import.rb b/app/workers/folder_import.rb index abc1234..def5678 100644 --- a/app/workers/folder_import.rb +++ b/app/workers/folder_import.rb @@ -0,0 +1,82 @@+module FolderImport + DATE_FORMAT = '%y%m%d' + ALBUM_FOLDER_PATTERN = /^(?<date>\d{6})(?<title>.+)$/ + ALLOWED_EXTS = ImageUplo...
Add rough folder importer worker.
diff --git a/benchmark-perf.gemspec b/benchmark-perf.gemspec index abc1234..def5678 100644 --- a/benchmark-perf.gemspec +++ b/benchmark-perf.gemspec @@ -6,7 +6,7 @@ spec.name = "benchmark-perf" spec.version = Benchmark::Perf::VERSION spec.authors = ["Piotr Murach"] - spec.email = [...
Change to relax dev dependencies
diff --git a/lib/rsscache/feed/item.rb b/lib/rsscache/feed/item.rb index abc1234..def5678 100644 --- a/lib/rsscache/feed/item.rb +++ b/lib/rsscache/feed/item.rb @@ -67,14 +67,14 @@ item.description ? item.description.strip : '' end + alias_method :summary, :description + ## # Returns...
Move the summary alias back alongside description
diff --git a/lib/snapme/cli/command.rb b/lib/snapme/cli/command.rb index abc1234..def5678 100644 --- a/lib/snapme/cli/command.rb +++ b/lib/snapme/cli/command.rb @@ -2,9 +2,18 @@ module CLI class Command def self.start(args) - options = Options.parse(args) - Process.daemon(true) if options.da...
Print message and quit if auth_token isn't set in environment
diff --git a/lib/usesthis/interview.rb b/lib/usesthis/interview.rb index abc1234..def5678 100644 --- a/lib/usesthis/interview.rb +++ b/lib/usesthis/interview.rb @@ -1,4 +1,9 @@ module UsesThis class Interview < Salt::Post + + def output_path(parent_path) + File.join(parent_path, 'interviews', @slug) + end...
Set our custom output path.
diff --git a/test/bmff/box/test_degradation_priority.rb b/test/bmff/box/test_degradation_priority.rb index abc1234..def5678 100644 --- a/test/bmff/box/test_degradation_priority.rb +++ b/test/bmff/box/test_degradation_priority.rb @@ -0,0 +1,62 @@+# coding: utf-8 +# vim: set expandtab tabstop=2 shiftwidth=2 softtabstop=2...
Add a test file for BMFF::Box::DegradationPriority.
diff --git a/test/controllers/oembed_controller_test.rb b/test/controllers/oembed_controller_test.rb index abc1234..def5678 100644 --- a/test/controllers/oembed_controller_test.rb +++ b/test/controllers/oembed_controller_test.rb @@ -12,7 +12,7 @@ assert_equal DC.server_root, json_body['provider_url'] end - de...
Fix name of oEmbed format test name
diff --git a/app/admin/user.rb b/app/admin/user.rb index abc1234..def5678 100644 --- a/app/admin/user.rb +++ b/app/admin/user.rb @@ -11,7 +11,7 @@ # permitted << :other if params[:action] == 'create' && current_user.admin? # permitted # end - permit_params :email, :name, :avatar + permit_params :email, :name, :...
Add password to admin panel.
diff --git a/Gem.gemspec b/Gem.gemspec index abc1234..def5678 100644 --- a/Gem.gemspec +++ b/Gem.gemspec @@ -2,7 +2,7 @@ Gem::Specification.new do |spec| spec.homepage = "https://github.com/envygeeks/luna-rspec-formatters" - spec.summary = "A couple of RSpec formatters the way I like them." + spec.summary = "Env...
Update description, because it's true!
diff --git a/app/models/url.rb b/app/models/url.rb index abc1234..def5678 100644 --- a/app/models/url.rb +++ b/app/models/url.rb @@ -10,4 +10,16 @@ has_one :baseline default_scope order(:name) + + def to_param + [id, slugify(name)].join('-') + end + + private + + # @param [String] string to slugify + # ...
Use slugs for URL links This feature makes the app feel a bit more polished. Change-Id: I913ee6523e31b22d9ceb1f83c9cea19a22873104
diff --git a/db/seeds.rb b/db/seeds.rb index abc1234..def5678 100644 --- a/db/seeds.rb +++ b/db/seeds.rb @@ -1,8 +1,8 @@ # Messages m1 = Message.create(body: 'help fire', phone_number: '+15558675309') -m2 = Message.create(body: 'omg i need a doc', phone_number: '+18005551234') -m3 = Message.create(body: 'send help', p...
Modify phone numbers in seed data
diff --git a/db/seeds.rb b/db/seeds.rb index abc1234..def5678 100644 --- a/db/seeds.rb +++ b/db/seeds.rb @@ -10,8 +10,20 @@ require 'csv' +puts "Loading crops..." CSV.foreach(Rails.root.join('db', 'seeds', 'crops.csv')) do |row| system_name,scientific_name,en_wikipedia_url = row @crop = Crop.create(:system_n...
Create some test users in dev and test environments. They're called test1, test2, test3 and have passwords password1 etc. Run `rake db:seed` or `rake db:setup` to get them.
diff --git a/db/seeds.rb b/db/seeds.rb index abc1234..def5678 100644 --- a/db/seeds.rb +++ b/db/seeds.rb @@ -3,7 +3,12 @@ User.create(name: TubularFaker.name, password: '123') end -Question.create(title: TubularFaker.company, content: TubularFaker.lingo, user: User.find(User.pluck(:id).sample)) +10.times do + que...
Create 10 questions with 3 answers each
diff --git a/db/seeds.rb b/db/seeds.rb index abc1234..def5678 100644 --- a/db/seeds.rb +++ b/db/seeds.rb @@ -14,6 +14,7 @@ {name: 'htg', level: 200}, {name: 'order', level: 300}, {name: 'family', level: 400}, + {nam...
Add subfamily level for SocialTraits
diff --git a/cheffish.gemspec b/cheffish.gemspec index abc1234..def5678 100644 --- a/cheffish.gemspec +++ b/cheffish.gemspec @@ -6,10 +6,10 @@ s.version = Cheffish::VERSION s.platform = Gem::Platform::RUBY s.license = "Apache-2.0" - s.summary = "A library to manipulate Chef in Chef." + s.summary = "A set of C...
Set the author of the gem to Chef Software This mirrors many of our other projects. Signed-off-by: Tim Smith <764ef62106582a09ed09dfa0b6bff7c05fd7d1e4@chef.io>
diff --git a/app/controllers/accounts_controller.rb b/app/controllers/accounts_controller.rb index abc1234..def5678 100644 --- a/app/controllers/accounts_controller.rb +++ b/app/controllers/accounts_controller.rb @@ -7,9 +7,10 @@ def update if current_user.update_attributes(user_params) - redirect_to acco...
Add flash messaging to accounts controller
diff --git a/app/controllers/pictures_controller.rb b/app/controllers/pictures_controller.rb index abc1234..def5678 100644 --- a/app/controllers/pictures_controller.rb +++ b/app/controllers/pictures_controller.rb @@ -17,7 +17,7 @@ def destroy @picture.destroy - redirect_to pictures_url, notice: 'Picture was...
Change redirect path on Picture Destroy
diff --git a/app/controllers/students_controller.rb b/app/controllers/students_controller.rb index abc1234..def5678 100644 --- a/app/controllers/students_controller.rb +++ b/app/controllers/students_controller.rb @@ -8,9 +8,26 @@ end def show + respond_to do |format| + format.html {} + format.json {...
Support a JSON representation of a student
diff --git a/spec/str_sanitizer_spec.rb b/spec/str_sanitizer_spec.rb index abc1234..def5678 100644 --- a/spec/str_sanitizer_spec.rb +++ b/spec/str_sanitizer_spec.rb @@ -11,6 +11,10 @@ it "has a method named 'single_quote'" do expect(StrSanitizer.respond_to? :single_quote).to eq true + end + + it "has a metho...
Add test for Main class to see if the class is accessable
diff --git a/bali-phy.rb b/bali-phy.rb index abc1234..def5678 100644 --- a/bali-phy.rb +++ b/bali-phy.rb @@ -7,9 +7,13 @@ depends_on 'gsl' -# fails_with_clang -# io.H:25:31: error: use of undeclared identifier 'push_back' -# void operator()(const T& t){push_back(t);} + fails_with :clang do + build 3...
Use new fails_with DSL syntax Signed-off-by: Jack Nagel <43386ce32af96f5c56f2a88e458cb94cebee3751@gmail.com>
diff --git a/script/publishing-api-sync-checks/working_group_check.rb b/script/publishing-api-sync-checks/working_group_check.rb index abc1234..def5678 100644 --- a/script/publishing-api-sync-checks/working_group_check.rb +++ b/script/publishing-api-sync-checks/working_group_check.rb @@ -0,0 +1,16 @@+# Working Groups a...
Add a publishing-api-sync-check for Working Groups
diff --git a/app/models/pageflow/positioned_file.rb b/app/models/pageflow/positioned_file.rb index abc1234..def5678 100644 --- a/app/models/pageflow/positioned_file.rb +++ b/app/models/pageflow/positioned_file.rb @@ -34,7 +34,7 @@ end def thumbnail_url(*args) - ImageFile.new.attachment.url(*args) ...
Align thumbnail_url in PositionedFile with ImageFile
diff --git a/awsecrets.gemspec b/awsecrets.gemspec index abc1234..def5678 100644 --- a/awsecrets.gemspec +++ b/awsecrets.gemspec @@ -20,7 +20,7 @@ spec.add_runtime_dependency 'aws-sdk', '>= 2', '< 4' spec.add_runtime_dependency 'aws_config', '~> 0.1.0' - spec.add_development_dependency 'bundler', '~> 1.9' + sp...
Allow bundler version < 3.0.
diff --git a/ext/attribute_builder/extconf.rb b/ext/attribute_builder/extconf.rb index abc1234..def5678 100644 --- a/ext/attribute_builder/extconf.rb +++ b/ext/attribute_builder/extconf.rb @@ -2,7 +2,7 @@ require 'mkmf' $CFLAGS << ' -Wall -W' -$CXXFLAGS << ' -Wall -W -std=c++03' +$CXXFLAGS << ' -Wall -W -std=c++98' ...
Use -std=c++98 for old compilers
diff --git a/lib/axiom/types/encodable.rb b/lib/axiom/types/encodable.rb index abc1234..def5678 100644 --- a/lib/axiom/types/encodable.rb +++ b/lib/axiom/types/encodable.rb @@ -5,68 +5,71 @@ # Add encoding constraints to a type module Encodable - if RUBY_VERSION >= '1.9' + # stub module for ruby 1....
Update Axiom::Types::Encodable to make it easier for YARD to parse
diff --git a/lib/akashi/vpc/instance.rb b/lib/akashi/vpc/instance.rb index abc1234..def5678 100644 --- a/lib/akashi/vpc/instance.rb +++ b/lib/akashi/vpc/instance.rb @@ -7,6 +7,7 @@ @object.internet_gateway = internet_gateway.id puts "Attached an InternetGateway (#{internet_gateway.id}) to a VPC (#{id})...
Add alias attach_internet_gateway of internet_gateway=
diff --git a/lib/autoinc/incrementor.rb b/lib/autoinc/incrementor.rb index abc1234..def5678 100644 --- a/lib/autoinc/incrementor.rb +++ b/lib/autoinc/incrementor.rb @@ -17,7 +17,7 @@ def key "".tap do |str| - str << "#{model_name.underscore}_#{field_name}" + str << "#{model_name.to_s....
Make sure we have a <String>, not a <ModelName>
diff --git a/lib/bipbip/plugin/nginx.rb b/lib/bipbip/plugin/nginx.rb index abc1234..def5678 100644 --- a/lib/bipbip/plugin/nginx.rb +++ b/lib/bipbip/plugin/nginx.rb @@ -16,11 +16,10 @@ uri = URI.parse(server['url']) response = Net::HTTP.get_response(uri) - connections_requested = 0 - if respons...
Raise error if response is not 200
diff --git a/db/seeds.rb b/db/seeds.rb index abc1234..def5678 100644 --- a/db/seeds.rb +++ b/db/seeds.rb @@ -7,13 +7,13 @@ # Character.create(name: 'Luke', movie: movies.first) User.destroy_all -DefinedWords.destroy_all +DefinedWord.destroy_all -20.times do { - User.create(first_name: Faker::Name.first_name, ...
Remove the 's' from the end of DefinedWords and fix the fakers that were not working.
diff --git a/db/seeds.rb b/db/seeds.rb index abc1234..def5678 100644 --- a/db/seeds.rb +++ b/db/seeds.rb @@ -25,3 +25,7 @@ liked = [true, false].sample Vote.create(story_id: rand(1..20), user_id: rand(1..10), liked: liked) end + +## ADMIN ## + +User.create(username: "mai", password: "password", email: "mai@mai.co...
Create account for me to add admin powers to later
diff --git a/lib/bipbip/plugin/monit.rb b/lib/bipbip/plugin/monit.rb index abc1234..def5678 100644 --- a/lib/bipbip/plugin/monit.rb +++ b/lib/bipbip/plugin/monit.rb @@ -3,6 +3,11 @@ module Bipbip class Plugin::Monit < Plugin + + #See https://bitbucket.org/tildeslash/monit/src/d60968cf7972cc902e5b6e2961d44456e1d...
Introduce constants and reference to src
diff --git a/paper_trail.gemspec b/paper_trail.gemspec index abc1234..def5678 100644 --- a/paper_trail.gemspec +++ b/paper_trail.gemspec @@ -17,6 +17,7 @@ s.add_dependency 'rails', '~> 3' + s.add_development_dependency 'rake' s.add_development_dependency 'shoulda', '2.10.3' s.add_development_dependenc...
Add development dependency on Rake.
diff --git a/lib/link_thumbnailer/page.rb b/lib/link_thumbnailer/page.rb index abc1234..def5678 100644 --- a/lib/link_thumbnailer/page.rb +++ b/lib/link_thumbnailer/page.rb @@ -18,6 +18,7 @@ def generate @source = processor.call(url) + processor.http.shutdown scraper.call end
Fix bug with closed TCP connection
diff --git a/lib/microspec/expectation.rb b/lib/microspec/expectation.rb index abc1234..def5678 100644 --- a/lib/microspec/expectation.rb +++ b/lib/microspec/expectation.rb @@ -12,8 +12,8 @@ end rescue NoMethodError => exception - if Predicates[method] - if boolean ^ Predicates[method].call(act...
Store predicate proc in a variable
diff --git a/lib/premailer-rails3/hook.rb b/lib/premailer-rails3/hook.rb index abc1234..def5678 100644 --- a/lib/premailer-rails3/hook.rb +++ b/lib/premailer-rails3/hook.rb @@ -11,13 +11,16 @@ # reset the body and add two new bodies with appropriate types message.body = nil + t_charset = messa...
Fix encoding-issues in Rails 3.1
diff --git a/lib/rack/handler/rack_jax.rb b/lib/rack/handler/rack_jax.rb index abc1234..def5678 100644 --- a/lib/rack/handler/rack_jax.rb +++ b/lib/rack/handler/rack_jax.rb @@ -0,0 +1,18 @@+module Rack + module Handler + + class RackJax + def self.run(app, option={}) + port = options.delete(:Port) || 70...
Add skeleton of a Rack Handler
diff --git a/lib/fluffy_paws/mailers.rb b/lib/fluffy_paws/mailers.rb index abc1234..def5678 100644 --- a/lib/fluffy_paws/mailers.rb +++ b/lib/fluffy_paws/mailers.rb @@ -7,11 +7,12 @@ from = Email.new(email: 'app65106927@heroku.com') subject = "Hi #{params[:user]}, your token for FluffyPaws" to...
Change server url to environmental variable
diff --git a/lib/tasks/mongodb_clone.rake b/lib/tasks/mongodb_clone.rake index abc1234..def5678 100644 --- a/lib/tasks/mongodb_clone.rake +++ b/lib/tasks/mongodb_clone.rake @@ -0,0 +1,10 @@+namespace :db do + namespace :copy do + namespace :production do + desc 'Copy production database' + task to_local: ...
Create a rake task to copy the production database and restore locally.
diff --git a/lib/tasks/users_reports.rake b/lib/tasks/users_reports.rake index abc1234..def5678 100644 --- a/lib/tasks/users_reports.rake +++ b/lib/tasks/users_reports.rake @@ -7,9 +7,9 @@ CSV.open(Rails.root.join('tmp', "submitted.csv").to_s , "wb") do |submitted_csv| CSV.open(Rails.root.join('tmp', "not_su...
Update year for user report csv
diff --git a/lib/geocoded_by_address.rb b/lib/geocoded_by_address.rb index abc1234..def5678 100644 --- a/lib/geocoded_by_address.rb +++ b/lib/geocoded_by_address.rb @@ -1,7 +1,7 @@ module GeocodedByAddress - unless Rails.env.test? + if Rails.env.test? def geocoder_by_address nil end
Adjust in GeocodedByAddress module to run more fast in test
diff --git a/chip-gpio.gemspec b/chip-gpio.gemspec index abc1234..def5678 100644 --- a/chip-gpio.gemspec +++ b/chip-gpio.gemspec @@ -1,7 +1,7 @@ Gem::Specification.new do |s| s.name = 'chip-gpio' - s.version = '0.0.1' + s.version = '0.0.2' s.date = '2016-09-10' s.homepage = 'http:/...
Update gem version after adding direction feature
diff --git a/lib/plugins/popsinseoul.rb b/lib/plugins/popsinseoul.rb index abc1234..def5678 100644 --- a/lib/plugins/popsinseoul.rb +++ b/lib/plugins/popsinseoul.rb @@ -21,7 +21,7 @@ i += 1 end response_string.slice!(-2..-1) - m.reply "[#{date}]#{response_string}" + m.reply "[#...
Add scheduled time to bot response
diff --git a/lib/spinoza/system/node.rb b/lib/spinoza/system/node.rb index abc1234..def5678 100644 --- a/lib/spinoza/system/node.rb +++ b/lib/spinoza/system/node.rb @@ -28,6 +28,9 @@ end def link dst, **opts + if links[dst] + raise "Link from #{self} to #{dst} already exists." + end links[dst] ...
Check for conflicting link definition.
diff --git a/config/routes.rb b/config/routes.rb index abc1234..def5678 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -17,11 +17,14 @@ end end - resources :partner_types, expect: :show + resources :partner_types, except: :show resources :partners, except: :show + resources :sponso...
Add router for sponsor and sponsor level
diff --git a/config/routes.rb b/config/routes.rb index abc1234..def5678 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -6,6 +6,10 @@ root 'application#index' post "/graphql", to: "graphql#execute" + + devise_for :users, controllers: { + registrations: :registrations + } devise_scope :user do...
Add devise route for registrations
diff --git a/config/routes.rb b/config/routes.rb index abc1234..def5678 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -1,7 +1,7 @@ Rails.application.routes.draw do # Render legal documents by using Keiyaku CSS # https://github.com/cognitom/keiyaku-css - resources :contracts, only: [:index, :show] + re...
Change routing from /contracts to /mou
diff --git a/config/routes.rb b/config/routes.rb index abc1234..def5678 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -11,7 +11,7 @@ post 'pusher/auth', to: 'pusher#auth' - get '/active', :to => 'transactions#active', :as => :active + get '/active', :to => 'requests#active', :as => :active get '/ri...
Change active route to a requests controller action
diff --git a/app/helpers/log_helper.rb b/app/helpers/log_helper.rb index abc1234..def5678 100644 --- a/app/helpers/log_helper.rb +++ b/app/helpers/log_helper.rb @@ -2,9 +2,35 @@ # A universal logger # module LogHelper + class DoubtfireLogger < ActiveSupport::Logger + @@logger = DoubtfireLogger.new + + def init...
ENHANCE: Update logger module to use new DoubtfireLogger
diff --git a/db/seeds/development/articles.rb b/db/seeds/development/articles.rb index abc1234..def5678 100644 --- a/db/seeds/development/articles.rb +++ b/db/seeds/development/articles.rb @@ -8,6 +8,7 @@ body: "Hi, this is a test!", posted_by: "naoki", category: "tips", + tags: "Test;Tag0", langu...
Add missing tags to seed data