sortify 0.1.7 → 0.1.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Rakefile +8 -14
- data/lib/sortify.rb +4 -4
- data/lib/sortify/version.rb +1 -1
- metadata +3 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6581d98bd8778f7a0ae615640419cfb1c0f6fbc8
|
4
|
+
data.tar.gz: 4ee7c4e3107ca01a4a579ab7ab975e7336c04d81
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0683f48351a44d5de89ba8c5c9e641962bc22dd6b0cdf2f7bfb7a9fcf8c32dd48e60ea8c33d6b7d114e20647cde01baad41d974c38c2b9ad7ef4015347849865
|
7
|
+
data.tar.gz: a8aaee1f375a66441bdfbb9adb1fc395d44eb5772c66fbf9240755ca0dcdfba1e83d3c8eda4693b44e754c112c7f502722c2f079bded4d4f211c5949d9c509e3
|
data/Rakefile
CHANGED
@@ -1,23 +1,17 @@
|
|
1
1
|
begin
|
2
|
-
require
|
2
|
+
require "bundler/setup"
|
3
3
|
rescue LoadError
|
4
|
-
puts
|
4
|
+
puts "You must `gem install bundler` and `bundle install` to run rake tasks"
|
5
5
|
end
|
6
6
|
|
7
|
-
require
|
7
|
+
require "rdoc/task"
|
8
8
|
|
9
9
|
RDoc::Task.new(:rdoc) do |rdoc|
|
10
|
-
rdoc.rdoc_dir =
|
11
|
-
rdoc.title =
|
12
|
-
rdoc.options <<
|
13
|
-
rdoc.rdoc_files.include(
|
14
|
-
rdoc.rdoc_files.include(
|
10
|
+
rdoc.rdoc_dir = "rdoc"
|
11
|
+
rdoc.title = "Sortify"
|
12
|
+
rdoc.options << "--line-numbers"
|
13
|
+
rdoc.rdoc_files.include("README.md")
|
14
|
+
rdoc.rdoc_files.include("lib/**/*.rb")
|
15
15
|
end
|
16
16
|
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
17
|
Bundler::GemHelper.install_tasks
|
23
|
-
|
data/lib/sortify.rb
CHANGED
@@ -1,15 +1,15 @@
|
|
1
|
-
require
|
1
|
+
require "whitelist_scope"
|
2
2
|
|
3
3
|
module Sortify
|
4
4
|
include WhitelistScope
|
5
|
-
|
6
|
-
|
5
|
+
alias sort_option whitelist_scope
|
6
|
+
alias sort_options whitelist
|
7
7
|
|
8
8
|
def default_sort_option(name)
|
9
9
|
@default_sort_option = name.to_sym
|
10
10
|
end
|
11
11
|
|
12
|
-
def sortify(sort_option =
|
12
|
+
def sortify(sort_option = "")
|
13
13
|
if sort_option.empty?
|
14
14
|
begin
|
15
15
|
call_whitelisted_scope(@default_sort_option)
|
data/lib/sortify/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sortify
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Melody
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2016-09-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord
|
@@ -142,9 +142,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
142
142
|
version: '0'
|
143
143
|
requirements: []
|
144
144
|
rubyforge_project:
|
145
|
-
rubygems_version: 2.
|
145
|
+
rubygems_version: 2.5.1
|
146
146
|
signing_key:
|
147
147
|
specification_version: 4
|
148
148
|
summary: Sortify helps you handle user-provided sort options in Rails apps.
|
149
149
|
test_files: []
|
150
|
-
has_rdoc:
|