convert stringex plugin to proper gem

Change-Id: I947b3dee5adc0ac84ef56173c46a1927ca3f2936
Reviewed-on: https://gerrit.instructure.com/29469
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Stephan Hagemann <stephan@pivotallabs.com>
Product-Review: Stephan Hagemann <stephan@pivotallabs.com>
QA-Review: Stephan Hagemann <stephan@pivotallabs.com>
This commit is contained in:
Raphael Weiner 2014-01-30 11:06:31 -07:00 committed by Stephan Hagemann
parent 85b9a2567b
commit 455b2fd840
201 changed files with 116 additions and 257 deletions

View File

@ -148,6 +148,7 @@ gem 'canvas_breach_mitigation', path: 'gems/canvas_breach_mitigation'
gem 'canvas_crummy', path: 'gems/canvas_crummy'
gem 'canvas_mimetype_fu', path: 'gems/canvas_mimetype_fu'
gem 'canvas_sanitize', path: 'gems/canvas_sanitize'
gem 'canvas_stringex', path: 'gems/canvas_stringex'
group :assets do
gem 'compass-rails', '1.0.3'

View File

@ -0,0 +1,6 @@
source 'https://rubygems.org'
# Specify your gem's dependencies in canvas_stringex.gemspec
gemspec
gem 'rails', :github => 'makandra/rails', :branch => '2-3-lts', :ref => 'e86daf8ff727d5efc0040c876ba00c9444a5d915'

View File

@ -0,0 +1,46 @@
GIT
remote: git://github.com/makandra/rails.git
revision: e86daf8ff727d5efc0040c876ba00c9444a5d915
ref: e86daf8ff727d5efc0040c876ba00c9444a5d915
branch: 2-3-lts
specs:
actionmailer (2.3.18)
actionpack (= 2.3.18)
actionpack (2.3.18)
activesupport (= 2.3.18)
rack (~> 1.1.0)
activerecord (2.3.18)
activesupport (= 2.3.18)
activeresource (2.3.18)
activesupport (= 2.3.18)
activesupport (2.3.18)
rails (2.3.18)
actionmailer (= 2.3.18)
actionpack (= 2.3.18)
activerecord (= 2.3.18)
activeresource (= 2.3.18)
activesupport (= 2.3.18)
rake (>= 0.8.3)
PATH
remote: .
specs:
canvas_stringex (0.0.1)
GEM
remote: https://rubygems.org/
specs:
rack (1.1.6)
rake (10.1.1)
sqlite3 (1.3.8)
PLATFORMS
ruby
DEPENDENCIES
activerecord
bundler (~> 1.5)
canvas_stringex!
rails!
rake
sqlite3

View File

@ -1,4 +1,6 @@
Copyright (c) 2008 Lucky Sneaks
Copyright (c) 2014
MIT License
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the

View File

@ -1,4 +1,8 @@
= Stringex
= Canvas Stringex
This is a fork of the Stringex gem: http://rubygems.org/gems/stringex
TODO: Use a current version of this stringex gem at some point
Some [hopefully] useful extensions to Ruby's String class. It is made up of three libraries: ActsAsUrl, Unidecoder, and StringExtensions.

View File

@ -1,3 +1,5 @@
require "bundler/gem_tasks"
require 'rake'
require 'rake/testtask'
require 'rdoc/task'

Binary file not shown.

View File

@ -0,0 +1,21 @@
# coding: utf-8
lib = File.expand_path('../lib', __FILE__)
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
Gem::Specification.new do |spec|
spec.name = "canvas_stringex"
spec.version = '0.0.1'
spec.authors = ["Raphael Weiner", "Stephan Hagemann"]
spec.email = ["rweiner@pivotallabs.com", "stephan@pivotallabs.com"]
spec.summary = %q{Instructure fork of the stringex gem}
spec.files = `git ls-files -z`.split("\x0")
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
spec.require_paths = ["lib"]
spec.add_development_dependency "activerecord"
spec.add_development_dependency "bundler", "~> 1.5"
spec.add_development_dependency "rake"
spec.add_development_dependency "sqlite3"
end

View File

@ -0,0 +1,11 @@
module CanvasStringex
require "lucky_sneaks/string_extensions"
require "lucky_sneaks/unidecoder"
require "lucky_sneaks/acts_as_url"
String.send :include, LuckySneaks::StringExtensions
if defined?(ActiveRecord)
ActiveRecord::Base.send :include, LuckySneaks::ActsAsUrl
end
end

Some files were not shown because too many files have changed in this diff Show More