agilib 0.1.0.beta2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.DS_Store +0 -0
- data/.document +5 -0
- data/.gitignore +49 -0
- data/.rspec +1 -0
- data/.ruby-gemset +1 -0
- data/.ruby-version +1 -0
- data/Gemfile.lock +69 -0
- data/LICENSE.txt +20 -0
- data/README.rdoc +19 -0
- data/Rakefile +51 -0
- data/app/.DS_Store +0 -0
- data/app/controllers/.DS_Store +0 -0
- data/app/controllers/agilib/tokens_controller.rb +56 -0
- data/bin/agilib +4 -0
- data/lib/agilib/cli.rb +35 -0
- data/lib/agilib/token_authentication/token_authentication.rb +33 -0
- data/lib/agilib/token_authentication/token_authentication_handler.rb +68 -0
- data/lib/agilib/version.rb +10 -0
- data/lib/agilib.rb +15 -0
- data/lib/generators/agilib/install/install_generator.rb +46 -0
- data/spec/agilib-rails_spec.rb +11 -0
- data/spec/spec_helper.rb +12 -0
- metadata +166 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 1c159316805609c84b91fed6c293abea3ca9d5bf
|
4
|
+
data.tar.gz: 1785cc91e95a8a9dc848beb6109edd78c7e27c74
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 0ba89ad20e1cd124ad7111b67063cc05e07c925b83d3b248dab5e000e7885bfb24b950f2a8eda1e8444f4b337cdd5bac1ccfe95009ea620e523050306ea2e7ae
|
7
|
+
data.tar.gz: 38afae470a11aa25760ac704df24df7723f658e8fe66441fd1f1b66b12ada5215cfcdd7a137a5847f7221a69a4c2373d4ceff16cf238c9ac3eb4fde1f063543f
|
data/.DS_Store
ADDED
Binary file
|
data/.document
ADDED
data/.gitignore
ADDED
@@ -0,0 +1,49 @@
|
|
1
|
+
# rcov generated
|
2
|
+
coverage
|
3
|
+
coverage.data
|
4
|
+
|
5
|
+
# rdoc generated
|
6
|
+
rdoc
|
7
|
+
|
8
|
+
# yard generated
|
9
|
+
doc
|
10
|
+
.yardoc
|
11
|
+
|
12
|
+
# bundler
|
13
|
+
.bundle
|
14
|
+
|
15
|
+
# jeweler generated
|
16
|
+
pkg
|
17
|
+
|
18
|
+
# Have editor/IDE/OS specific files you need to ignore? Consider using a global gitignore:
|
19
|
+
#
|
20
|
+
# * Create a file at ~/.gitignore
|
21
|
+
# * Include files you want ignored
|
22
|
+
# * Run: git config --global core.excludesfile ~/.gitignore
|
23
|
+
#
|
24
|
+
# After doing this, these files will be ignored in all your git projects,
|
25
|
+
# saving you from having to 'pollute' every project you touch with them
|
26
|
+
#
|
27
|
+
# Not sure what to needs to be ignored for particular editors/OSes? Here's some ideas to get you started. (Remember, remove the leading # of the line)
|
28
|
+
#
|
29
|
+
# For MacOS:
|
30
|
+
#
|
31
|
+
#.DS_Store
|
32
|
+
|
33
|
+
# For TextMate
|
34
|
+
#*.tmproj
|
35
|
+
#tmtags
|
36
|
+
|
37
|
+
# For emacs:
|
38
|
+
#*~
|
39
|
+
#\#*
|
40
|
+
#.\#*
|
41
|
+
|
42
|
+
# For vim:
|
43
|
+
#*.swp
|
44
|
+
|
45
|
+
# For redcar:
|
46
|
+
#.redcar
|
47
|
+
|
48
|
+
# For rubinius:
|
49
|
+
#*.rbc
|
data/.rspec
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
--color
|
data/.ruby-gemset
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
agivis
|
data/.ruby-version
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
2.1.0
|
data/Gemfile.lock
ADDED
@@ -0,0 +1,69 @@
|
|
1
|
+
GEM
|
2
|
+
remote: http://rubygems.org/
|
3
|
+
specs:
|
4
|
+
addressable (2.3.5)
|
5
|
+
builder (3.2.2)
|
6
|
+
descendants_tracker (0.0.3)
|
7
|
+
diff-lcs (1.1.3)
|
8
|
+
faraday (0.8.8)
|
9
|
+
multipart-post (~> 1.2.0)
|
10
|
+
git (1.2.6)
|
11
|
+
github_api (0.11.1)
|
12
|
+
addressable (~> 2.3)
|
13
|
+
descendants_tracker (~> 0.0.1)
|
14
|
+
faraday (~> 0.8, < 0.10)
|
15
|
+
hashie (>= 1.2)
|
16
|
+
multi_json (>= 1.7.5, < 2.0)
|
17
|
+
nokogiri (~> 1.6.0)
|
18
|
+
oauth2
|
19
|
+
hashie (2.0.5)
|
20
|
+
highline (1.6.20)
|
21
|
+
httpauth (0.2.0)
|
22
|
+
jeweler (2.0.0)
|
23
|
+
builder
|
24
|
+
bundler (>= 1.0)
|
25
|
+
git (>= 1.2.5)
|
26
|
+
github_api
|
27
|
+
highline (>= 1.6.15)
|
28
|
+
nokogiri (>= 1.5.10)
|
29
|
+
rake
|
30
|
+
rdoc
|
31
|
+
json (1.8.1)
|
32
|
+
jwt (0.1.8)
|
33
|
+
multi_json (>= 1.5)
|
34
|
+
mini_portile (0.5.2)
|
35
|
+
multi_json (1.8.2)
|
36
|
+
multi_xml (0.5.5)
|
37
|
+
multipart-post (1.2.0)
|
38
|
+
nokogiri (1.6.1)
|
39
|
+
mini_portile (~> 0.5.0)
|
40
|
+
oauth2 (0.9.2)
|
41
|
+
faraday (~> 0.8)
|
42
|
+
httpauth (~> 0.2)
|
43
|
+
jwt (~> 0.1.4)
|
44
|
+
multi_json (~> 1.0)
|
45
|
+
multi_xml (~> 0.5)
|
46
|
+
rack (~> 1.2)
|
47
|
+
rack (1.5.2)
|
48
|
+
rake (10.1.1)
|
49
|
+
rdoc (3.12.2)
|
50
|
+
json (~> 1.4)
|
51
|
+
rspec (2.8.0)
|
52
|
+
rspec-core (~> 2.8.0)
|
53
|
+
rspec-expectations (~> 2.8.0)
|
54
|
+
rspec-mocks (~> 2.8.0)
|
55
|
+
rspec-core (2.8.0)
|
56
|
+
rspec-expectations (2.8.0)
|
57
|
+
diff-lcs (~> 1.1.2)
|
58
|
+
rspec-mocks (2.8.0)
|
59
|
+
yard (0.8.7.3)
|
60
|
+
|
61
|
+
PLATFORMS
|
62
|
+
ruby
|
63
|
+
|
64
|
+
DEPENDENCIES
|
65
|
+
bundler (~> 1.0)
|
66
|
+
jeweler (~> 2.0.0)
|
67
|
+
rdoc (~> 3.12)
|
68
|
+
rspec (~> 2.8.0)
|
69
|
+
yard (~> 0.7)
|
data/LICENSE.txt
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
Copyright (c) 2014 Tabata Ruiz Schnoeller
|
2
|
+
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
4
|
+
a copy of this software and associated documentation files (the
|
5
|
+
"Software"), to deal in the Software without restriction, including
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
9
|
+
the following conditions:
|
10
|
+
|
11
|
+
The above copyright notice and this permission notice shall be
|
12
|
+
included in all copies or substantial portions of the Software.
|
13
|
+
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
17
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
18
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
19
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
20
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.rdoc
ADDED
@@ -0,0 +1,19 @@
|
|
1
|
+
= agilib
|
2
|
+
|
3
|
+
Description goes here.
|
4
|
+
|
5
|
+
== Contributing to agilib
|
6
|
+
|
7
|
+
* Check out the latest master to make sure the feature hasn't been implemented or the bug hasn't been fixed yet.
|
8
|
+
* Check out the issue tracker to make sure someone already hasn't requested it and/or contributed it.
|
9
|
+
* Fork the project.
|
10
|
+
* Start a feature/bugfix branch.
|
11
|
+
* Commit and push until you are happy with your contribution.
|
12
|
+
* Make sure to add tests for it. This is important so I don't break it in a future version unintentionally.
|
13
|
+
* Please try not to mess with the Rakefile, version, or history. If you want to have your own version, or is otherwise necessary, that is fine, but please isolate to its own commit so I can cherry-pick around it.
|
14
|
+
|
15
|
+
== Copyright
|
16
|
+
|
17
|
+
Copyright (c) 2014 Tabata Ruiz Schnoeller. See LICENSE.txt for
|
18
|
+
further details.
|
19
|
+
|
data/Rakefile
ADDED
@@ -0,0 +1,51 @@
|
|
1
|
+
require 'rubygems'
|
2
|
+
require 'bundler'
|
3
|
+
begin
|
4
|
+
Bundler.setup(:default, :development)
|
5
|
+
rescue Bundler::BundlerError => e
|
6
|
+
$stderr.puts e.message
|
7
|
+
$stderr.puts "Run `bundle install` to install missing gems"
|
8
|
+
exit e.status_code
|
9
|
+
end
|
10
|
+
require 'rake'
|
11
|
+
|
12
|
+
require 'jeweler'
|
13
|
+
require './lib/agilib/version.rb'
|
14
|
+
|
15
|
+
Jeweler::Tasks.new do |gem|
|
16
|
+
|
17
|
+
# gem is a Gem::Specification... see http://docs.rubygems.org/read/chapter/20 for more options
|
18
|
+
gem.name = "agilib"
|
19
|
+
gem.version = Agilib::Version::STRING
|
20
|
+
gem.homepage = "http://github.com/marcosgugs/agilib"
|
21
|
+
gem.license = "MIT"
|
22
|
+
gem.summary = "agilib summary"
|
23
|
+
gem.description = "agilib description"
|
24
|
+
gem.email = "marcos.junior@agivis.com.br"
|
25
|
+
gem.authors = ["Marcos Junior"]
|
26
|
+
gem.files = `git ls-files`.split("\n") - %w[agilib.gemspec Gemfile]
|
27
|
+
# dependencies defined in Gemfile
|
28
|
+
|
29
|
+
gem.add_runtime_dependency 'rails'
|
30
|
+
gem.add_runtime_dependency 'devise'
|
31
|
+
|
32
|
+
gem.executables = ['agilib']
|
33
|
+
|
34
|
+
end
|
35
|
+
Jeweler::RubygemsDotOrgTasks.new
|
36
|
+
|
37
|
+
require 'rspec/core'
|
38
|
+
require 'rspec/core/rake_task'
|
39
|
+
RSpec::Core::RakeTask.new(:spec) do |spec|
|
40
|
+
spec.pattern = FileList['spec/**/*_spec.rb']
|
41
|
+
end
|
42
|
+
|
43
|
+
RSpec::Core::RakeTask.new(:rcov) do |spec|
|
44
|
+
spec.pattern = 'spec/**/*_spec.rb'
|
45
|
+
# spec.rcov = true
|
46
|
+
end
|
47
|
+
|
48
|
+
task :default => :spec
|
49
|
+
|
50
|
+
require 'yard'
|
51
|
+
YARD::Rake::YardocTask.new
|
data/app/.DS_Store
ADDED
Binary file
|
Binary file
|
@@ -0,0 +1,56 @@
|
|
1
|
+
class Agilib::TokensController < Devise::SessionsController
|
2
|
+
skip_before_filter :verify_authenticity_token
|
3
|
+
respond_to :json
|
4
|
+
|
5
|
+
def create
|
6
|
+
login = params[:email]
|
7
|
+
password = params[:password]
|
8
|
+
|
9
|
+
if request.format != :json
|
10
|
+
render :status=>406, :json => { :message => "The request must be json" }
|
11
|
+
return
|
12
|
+
end
|
13
|
+
|
14
|
+
if login.nil? or password.nil?
|
15
|
+
render :status=>400, :json=>{ :message => "The request must contain the user login and password." }
|
16
|
+
return
|
17
|
+
end
|
18
|
+
|
19
|
+
if User.respond_to? "find_by"
|
20
|
+
@user = User.find_by(email: login.downcase)
|
21
|
+
elsif User.respond_to? "find_by_email"
|
22
|
+
@user = User.find_by_email(login.downcase)
|
23
|
+
end
|
24
|
+
|
25
|
+
if @user.nil?
|
26
|
+
render :status=>401, :json=>{:message=>"Invalid login or passoword."}
|
27
|
+
return
|
28
|
+
end
|
29
|
+
|
30
|
+
@user.ensure_authentication_token
|
31
|
+
@user.save!
|
32
|
+
|
33
|
+
if not @user.valid_password?(password)
|
34
|
+
render :status=> 401, :json=>{:message=>"Invalid login or passoword."}
|
35
|
+
else
|
36
|
+
render :status=>200, :json=>{:user=> @user, :token => @user.authentication_token}
|
37
|
+
end
|
38
|
+
|
39
|
+
end
|
40
|
+
|
41
|
+
def destroy
|
42
|
+
@user=User.find_by_authentication_token(params[:id])
|
43
|
+
if @user.nil?
|
44
|
+
render :status=>404, :json=>{:message=>"Invalid token."}
|
45
|
+
else
|
46
|
+
@user.authentication_token = ""
|
47
|
+
@user.save!
|
48
|
+
|
49
|
+
sign_out @user
|
50
|
+
|
51
|
+
render :status => 200, :json=>{:user=> @user, :token=>params[:id]}
|
52
|
+
|
53
|
+
end
|
54
|
+
end
|
55
|
+
|
56
|
+
end
|
data/bin/agilib
ADDED
data/lib/agilib/cli.rb
ADDED
@@ -0,0 +1,35 @@
|
|
1
|
+
require 'agilib'
|
2
|
+
require 'optparse'
|
3
|
+
|
4
|
+
module Agilib
|
5
|
+
class Cli
|
6
|
+
|
7
|
+
def self.run(args, out = STDOUT)
|
8
|
+
|
9
|
+
OptionParser.new{ |opts|
|
10
|
+
opts.banner = "Usage:\n agilib [options] <location>"
|
11
|
+
opts.separator "\nOptions: "
|
12
|
+
|
13
|
+
opts.on("-l <language>", "--language <language>",
|
14
|
+
"Language of output (see API docs for valid choices)") do |language|
|
15
|
+
# Agilib.configure(:language => language)
|
16
|
+
end
|
17
|
+
|
18
|
+
opts.on_tail("-v", "--version", "Print version number") do
|
19
|
+
require "agilib/version"
|
20
|
+
out << "Agilib #{Agilib::VERSION}\n"
|
21
|
+
exit
|
22
|
+
end
|
23
|
+
|
24
|
+
opts.on_tail("-h", "--help", "Print this help") do
|
25
|
+
out << "Agilib Help.\n\n"
|
26
|
+
out << opts
|
27
|
+
out << "\nCreated and maintained by Agivis Web & Mobile, available under the MIT License.\n"
|
28
|
+
exit
|
29
|
+
end
|
30
|
+
}.parse!(args)
|
31
|
+
|
32
|
+
end
|
33
|
+
|
34
|
+
end
|
35
|
+
end
|
@@ -0,0 +1,33 @@
|
|
1
|
+
module Agilib
|
2
|
+
module TokenAuthenticatable
|
3
|
+
extend ActiveSupport::Concern
|
4
|
+
|
5
|
+
# Please see https://gist.github.com/josevalim/fb706b1e933ef01e4fb6
|
6
|
+
# before editing this file, the discussion is very interesting.
|
7
|
+
|
8
|
+
included do
|
9
|
+
private :generate_authentication_token
|
10
|
+
end
|
11
|
+
|
12
|
+
def ensure_authentication_token
|
13
|
+
if authentication_token.blank?
|
14
|
+
self.authentication_token = generate_authentication_token
|
15
|
+
end
|
16
|
+
end
|
17
|
+
|
18
|
+
def generate_authentication_token
|
19
|
+
loop do
|
20
|
+
token = Devise.friendly_token
|
21
|
+
break token unless User.where(authentication_token: token).first
|
22
|
+
end
|
23
|
+
end
|
24
|
+
|
25
|
+
module ClassMethods
|
26
|
+
def agilib_token_authenticatable(options = {})
|
27
|
+
include Agilib::TokenAuthenticatable
|
28
|
+
before_save :ensure_authentication_token
|
29
|
+
end
|
30
|
+
end
|
31
|
+
end
|
32
|
+
end
|
33
|
+
ActiveRecord::Base.send :include, Agilib::TokenAuthenticatable
|
@@ -0,0 +1,68 @@
|
|
1
|
+
module Agilib
|
2
|
+
module TokenAuthenticationHandlerMethods
|
3
|
+
extend ActiveSupport::Concern
|
4
|
+
|
5
|
+
# Please see https://gist.github.com/josevalim/fb706b1e933ef01e4fb6
|
6
|
+
# before editing this file, the discussion is very interesting.
|
7
|
+
|
8
|
+
included do
|
9
|
+
private :authenticate_user_from_token!
|
10
|
+
# This is our new function that comes before Devise's one
|
11
|
+
before_filter :authenticate_user_from_token!
|
12
|
+
# This is Devise's authentication
|
13
|
+
before_filter :authenticate_user!
|
14
|
+
end
|
15
|
+
|
16
|
+
# For this example, we are simply using token authentication
|
17
|
+
# via parameters. However, anyone could use Rails's token
|
18
|
+
# authentication features to get the token from a header.
|
19
|
+
def authenticate_user_from_token!
|
20
|
+
# Set the authentication token params if not already present,
|
21
|
+
# see http://stackoverflow.com/questions/11017348/rails-api-authentication-by-headers-token
|
22
|
+
if user_token = params[:user_token].blank? && request.headers["X-User-Token"]
|
23
|
+
params[:user_token] = user_token
|
24
|
+
end
|
25
|
+
if user_email = params[:user_email].blank? && request.headers["X-User-Email"]
|
26
|
+
params[:user_email] = user_email
|
27
|
+
end
|
28
|
+
|
29
|
+
user_email = params[:user_email].presence
|
30
|
+
# See https://github.com/ryanb/cancan/blob/1.6.10/lib/cancan/controller_resource.rb#L108-L111
|
31
|
+
if User.respond_to? "find_by"
|
32
|
+
user = user_email && User.find_by(email: user_email)
|
33
|
+
elsif User.respond_to? "find_by_email"
|
34
|
+
user = user_email && User.find_by_email(user_email)
|
35
|
+
end
|
36
|
+
|
37
|
+
# Notice how we use Devise.secure_compare to compare the token
|
38
|
+
# in the database with the token given in the params, mitigating
|
39
|
+
# timing attacks.
|
40
|
+
if user && Devise.secure_compare(user.authentication_token, params[:user_token])
|
41
|
+
# Notice we are passing store false, so the user is not
|
42
|
+
# actually stored in the session and a token is needed
|
43
|
+
# for every request. If you want the token to work as a
|
44
|
+
# sign in token, you can simply remove store: false.
|
45
|
+
sign_in user, store: false
|
46
|
+
end
|
47
|
+
end
|
48
|
+
end
|
49
|
+
|
50
|
+
module TokenAuthenticationHandler
|
51
|
+
extend ActiveSupport::Concern
|
52
|
+
|
53
|
+
# I have insulated the methods into an additional module to avoid before_filters
|
54
|
+
# to be applied by the `included` block before acts_as_token_authentication_handler was called.
|
55
|
+
# See https://github.com/gonzalo-bulnes/simple_token_authentication/issues/8#issuecomment-31707201
|
56
|
+
|
57
|
+
included do
|
58
|
+
# nop
|
59
|
+
end
|
60
|
+
|
61
|
+
module ClassMethods
|
62
|
+
def agilib_token_authentication_handler(options = {})
|
63
|
+
include Agilib::TokenAuthenticationHandlerMethods
|
64
|
+
end
|
65
|
+
end
|
66
|
+
end
|
67
|
+
end
|
68
|
+
ActionController::Base.send :include, Agilib::TokenAuthenticationHandler
|
data/lib/agilib.rb
ADDED
@@ -0,0 +1,46 @@
|
|
1
|
+
require 'rails/generators'
|
2
|
+
|
3
|
+
module Agilib
|
4
|
+
module Generators
|
5
|
+
class InstallGenerator < ::Rails::Generators::Base
|
6
|
+
desc "Instalação da Agilib"
|
7
|
+
source_root File.expand_path('../templates', __FILE__)
|
8
|
+
class_option :template_engine, :desc => 'Template engine to be invoked (erb, haml or slim).'
|
9
|
+
class_option :bootstrap, :type => :boolean, :desc => 'Add the Twitter Bootstrap wrappers to the SimpleForm initializer.'
|
10
|
+
class_option :foundation, :type => :boolean, :desc => 'Add the Zurb Foundation 3 wrappers to the SimpleForm initializer.'
|
11
|
+
|
12
|
+
def info_bootstrap
|
13
|
+
return if options.bootstrap? || options.foundation?
|
14
|
+
puts "SimpleForm 2 supports Twitter Bootstrap and Zurb Foundation 3. If you want "\
|
15
|
+
"a configuration that is compatible with one of these frameworks, then please " \
|
16
|
+
"re-run this generator with --bootstrap or --foundation as an option."
|
17
|
+
end
|
18
|
+
|
19
|
+
def copy_config
|
20
|
+
# template "config/initializers/simple_form.rb"
|
21
|
+
|
22
|
+
# if options[:bootstrap]
|
23
|
+
# template "config/initializers/simple_form_bootstrap.rb"
|
24
|
+
# elsif options[:foundation]
|
25
|
+
# template "config/initializers/simple_form_foundation.rb"
|
26
|
+
# end
|
27
|
+
|
28
|
+
# directory 'config/locales'
|
29
|
+
puts "copy_config"
|
30
|
+
end
|
31
|
+
|
32
|
+
def copy_scaffold_template
|
33
|
+
# engine = options[:template_engine]
|
34
|
+
# copy_file "_form.html.#{engine}", "lib/templates/#{engine}/scaffold/_form.html.#{engine}"
|
35
|
+
puts "copy_scaffold_template"
|
36
|
+
end
|
37
|
+
|
38
|
+
def show_readme
|
39
|
+
# if behavior == :invoke && options.bootstrap?
|
40
|
+
# readme "README"
|
41
|
+
# end
|
42
|
+
puts "show_readme"
|
43
|
+
end
|
44
|
+
end
|
45
|
+
end
|
46
|
+
end
|
@@ -0,0 +1,11 @@
|
|
1
|
+
require File.expand_path(File.dirname(__FILE__) + '/spec_helper')
|
2
|
+
|
3
|
+
describe "AgilibRails" do
|
4
|
+
# it "fails" do
|
5
|
+
# fail "hey buddy, you should probably rename this file and start specing for real"
|
6
|
+
# end
|
7
|
+
|
8
|
+
# it "test agilib" do
|
9
|
+
# puts Agilib::TokenAuthenticatable
|
10
|
+
# end
|
11
|
+
end
|
data/spec/spec_helper.rb
ADDED
@@ -0,0 +1,12 @@
|
|
1
|
+
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
2
|
+
$LOAD_PATH.unshift(File.dirname(__FILE__))
|
3
|
+
require 'rspec'
|
4
|
+
require 'agilib'
|
5
|
+
|
6
|
+
# Requires supporting files with custom matchers and macros, etc,
|
7
|
+
# in ./support/ and its subdirectories.
|
8
|
+
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each {|f| require f}
|
9
|
+
|
10
|
+
RSpec.configure do |config|
|
11
|
+
|
12
|
+
end
|
metadata
ADDED
@@ -0,0 +1,166 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: agilib
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.0.beta2
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Marcos Junior
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2014-01-10 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: rspec
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: 2.8.0
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: 2.8.0
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: yard
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0.7'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0.7'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: rdoc
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '3.12'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '3.12'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: bundler
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - "~>"
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '1.0'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - "~>"
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '1.0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: jeweler
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: 2.0.0
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: 2.0.0
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: rails
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - ">="
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '0'
|
90
|
+
type: :runtime
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - ">="
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '0'
|
97
|
+
- !ruby/object:Gem::Dependency
|
98
|
+
name: devise
|
99
|
+
requirement: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - ">="
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: '0'
|
104
|
+
type: :runtime
|
105
|
+
prerelease: false
|
106
|
+
version_requirements: !ruby/object:Gem::Requirement
|
107
|
+
requirements:
|
108
|
+
- - ">="
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: '0'
|
111
|
+
description: agilib description
|
112
|
+
email: marcos.junior@agivis.com.br
|
113
|
+
executables:
|
114
|
+
- agilib
|
115
|
+
extensions: []
|
116
|
+
extra_rdoc_files:
|
117
|
+
- LICENSE.txt
|
118
|
+
- README.rdoc
|
119
|
+
files:
|
120
|
+
- ".DS_Store"
|
121
|
+
- ".document"
|
122
|
+
- ".gitignore"
|
123
|
+
- ".rspec"
|
124
|
+
- ".ruby-gemset"
|
125
|
+
- ".ruby-version"
|
126
|
+
- Gemfile.lock
|
127
|
+
- LICENSE.txt
|
128
|
+
- README.rdoc
|
129
|
+
- Rakefile
|
130
|
+
- app/.DS_Store
|
131
|
+
- app/controllers/.DS_Store
|
132
|
+
- app/controllers/agilib/tokens_controller.rb
|
133
|
+
- bin/agilib
|
134
|
+
- lib/agilib.rb
|
135
|
+
- lib/agilib/cli.rb
|
136
|
+
- lib/agilib/token_authentication/token_authentication.rb
|
137
|
+
- lib/agilib/token_authentication/token_authentication_handler.rb
|
138
|
+
- lib/agilib/version.rb
|
139
|
+
- lib/generators/agilib/install/install_generator.rb
|
140
|
+
- spec/agilib-rails_spec.rb
|
141
|
+
- spec/spec_helper.rb
|
142
|
+
homepage: http://github.com/marcosgugs/agilib
|
143
|
+
licenses:
|
144
|
+
- MIT
|
145
|
+
metadata: {}
|
146
|
+
post_install_message:
|
147
|
+
rdoc_options: []
|
148
|
+
require_paths:
|
149
|
+
- lib
|
150
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
151
|
+
requirements:
|
152
|
+
- - ">="
|
153
|
+
- !ruby/object:Gem::Version
|
154
|
+
version: '0'
|
155
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
156
|
+
requirements:
|
157
|
+
- - ">"
|
158
|
+
- !ruby/object:Gem::Version
|
159
|
+
version: 1.3.1
|
160
|
+
requirements: []
|
161
|
+
rubyforge_project:
|
162
|
+
rubygems_version: 2.2.1
|
163
|
+
signing_key:
|
164
|
+
specification_version: 4
|
165
|
+
summary: agilib summary
|
166
|
+
test_files: []
|