boar 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.gitignore +7 -0
- data/.travis-gemfile +13 -0
- data/.travis.yml +10 -0
- data/.yardopts +1 -0
- data/Gemfile +20 -0
- data/README.md +19 -0
- data/Rakefile +11 -0
- data/app/controllers/boar/application_controller.rb +16 -0
- data/app/controllers/boar/downloads_controller.rb +17 -0
- data/app/controllers/boar/pages_controller.rb +13 -0
- data/app/models/boar/handlers/authentication.rb +38 -0
- data/app/models/boar/handlers/downloads/base.rb +56 -0
- data/app/models/boar/handlers/downloads/box_net.rb +67 -0
- data/app/models/boar/handlers/downloads/dropbox.rb +59 -0
- data/app/models/boar/handlers/downloads/google_drive.rb +48 -0
- data/app/models/boar/handlers/downloads/local.rb +34 -0
- data/app/models/boar/handlers/downloads/remote.rb +24 -0
- data/app/models/boar/handlers/downloads/s3.rb +54 -0
- data/app/models/boar/handlers/downloads/sky_drive.rb +45 -0
- data/app/models/boar/handlers/generic.rb +25 -0
- data/app/models/boar/handlers/hosts.rb +28 -0
- data/app/models/boar/handlers/locale.rb +25 -0
- data/app/models/boar/handlers/path_mapper.rb +15 -0
- data/app/models/boar/handlers/root.rb +25 -0
- data/app/models/boar/handlers/views.rb +25 -0
- data/app/models/boar/services/downloads.rb +118 -0
- data/app/models/boar/services/generic.rb +78 -0
- data/app/models/boar/services/pages.rb +62 -0
- data/app/models/boar/utils/basic.rb +27 -0
- data/boar.gemspec +41 -0
- data/lib/boar.rb +31 -0
- data/lib/boar/configuration.rb +77 -0
- data/lib/boar/engine.rb +16 -0
- data/lib/boar/exceptions.rb +46 -0
- data/lib/boar/providers/base.rb +28 -0
- data/lib/boar/providers/box_net.rb +27 -0
- data/lib/boar/providers/dropbox.rb +26 -0
- data/lib/boar/providers/google_drive.rb +87 -0
- data/lib/boar/providers/sky_drive.rb +80 -0
- data/lib/boar/router.rb +68 -0
- data/lib/boar/version.rb +25 -0
- data/lib/tasks/boar.rake +102 -0
- data/spec/boar/controllers/application_controller_spec.rb +11 -0
- data/spec/boar/controllers/pages_controller_spec.rb +11 -0
- data/spec/boar/routes_spec.rb +11 -0
- data/spec/boar_spec.rb +7 -0
- data/spec/coverage_helper.rb +17 -0
- data/spec/spec_helper.rb +15 -0
- metadata +264 -0
@@ -0,0 +1,80 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
#
|
3
|
+
# This file is part of the boar gem. Copyright (C) 2013 and above Shogun <shogun_panda@me.com>.
|
4
|
+
# Licensed under the MIT license, which can be found at http://www.opensource.org/licenses/mit-license.php.
|
5
|
+
#
|
6
|
+
|
7
|
+
module Boar
|
8
|
+
module Providers
|
9
|
+
class SkyDrive < Base
|
10
|
+
SCOPES = "wl.skydrive_update,wl.offline_access"
|
11
|
+
|
12
|
+
def redirect_for_authentication(authorizer, configuration)
|
13
|
+
authorizer.ip = configuration[:domain]
|
14
|
+
|
15
|
+
@client = Boar::Providers::SkyDrive.client(configuration, authorizer.callback_url)
|
16
|
+
@client.authorize_url
|
17
|
+
end
|
18
|
+
|
19
|
+
def get_credentials(authorizer, request, response)
|
20
|
+
begin
|
21
|
+
raise Clavem::Exceptions::AuthorizationDenied if request.query["error"].present? || request.query["code"].blank?
|
22
|
+
token = @client.get_access_token(request.query["code"])
|
23
|
+
{access_token: token.token, refresh_token: token.refresh_token}
|
24
|
+
rescue RuntimeError
|
25
|
+
nil
|
26
|
+
end
|
27
|
+
end
|
28
|
+
|
29
|
+
def search_file(path, params)
|
30
|
+
rv = nil
|
31
|
+
|
32
|
+
# Split path
|
33
|
+
Lazier.load_pathname
|
34
|
+
filename = File.basename(path)
|
35
|
+
tree = Pathname.new(File.dirname(path)).components
|
36
|
+
|
37
|
+
# Initialize client
|
38
|
+
client = Boar::Providers::SkyDrive.authorized_client(params[:single], params)
|
39
|
+
|
40
|
+
# Find the last folder
|
41
|
+
current = client.my_skydrive
|
42
|
+
tree.each do |folder|
|
43
|
+
current = search_entry(current, folder, true)
|
44
|
+
break if !current
|
45
|
+
end
|
46
|
+
|
47
|
+
# We have the container, query for the file
|
48
|
+
rv = search_entry(current, filename) if current
|
49
|
+
rv ? {"id" => rv.id} : nil
|
50
|
+
end
|
51
|
+
|
52
|
+
def self.client(configuration, callback_url = nil)
|
53
|
+
::Skydrive::Oauth::Client.new(configuration[:client_id], configuration[:client_secret], callback_url, Boar::Providers::SkyDrive::SCOPES)
|
54
|
+
end
|
55
|
+
|
56
|
+
def self.authorized_client(configuration, params)
|
57
|
+
# Get a new access token
|
58
|
+
token = Boar::Providers::SkyDrive.client(configuration).get_access_token_from_hash(configuration[:access_token], {:refresh_token => configuration[:refresh_token]})
|
59
|
+
params[:provider].update_credentials({access_token: token.token, refresh_token: token.refresh_token}, params)
|
60
|
+
|
61
|
+
# Create the client
|
62
|
+
Skydrive::Client.new(token)
|
63
|
+
end
|
64
|
+
|
65
|
+
private
|
66
|
+
def search_entry(parent, entry, directory = false)
|
67
|
+
catch(:entry) do
|
68
|
+
parent.files.items.each do |file|
|
69
|
+
if file.name == entry && (file.is_a?(Skydrive::File) || directory)
|
70
|
+
file.instance_variable_set("@client", parent.client) # This is to fix a gem's bug.
|
71
|
+
throw(:entry, file)
|
72
|
+
end
|
73
|
+
end
|
74
|
+
|
75
|
+
nil
|
76
|
+
end
|
77
|
+
end
|
78
|
+
end
|
79
|
+
end
|
80
|
+
end
|
data/lib/boar/router.rb
ADDED
@@ -0,0 +1,68 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
#
|
3
|
+
# This file is part of the boar gem. Copyright (C) 2013 and above Shogun <shogun_panda@me.com>.
|
4
|
+
# Licensed under the MIT license, which can be found at http://www.opensource.org/licenses/mit-license.php.
|
5
|
+
#
|
6
|
+
|
7
|
+
module ActionDispatch::Routing
|
8
|
+
class Mapper
|
9
|
+
def boar_mount_pages(*args)
|
10
|
+
Boar::Router.mount_pages(self, *args)
|
11
|
+
end
|
12
|
+
|
13
|
+
def boar_mount_downloads(*args)
|
14
|
+
Boar::Router.mount_downloads(self, *args)
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
18
|
+
|
19
|
+
module Boar
|
20
|
+
class Router
|
21
|
+
def self.mount_pages(router, *args)
|
22
|
+
options = args.extract_options!
|
23
|
+
config = Rails.application.config.boar
|
24
|
+
|
25
|
+
root = get_option(options, :root, config.pages_root)
|
26
|
+
root += "/" if root.present? && root !~ /\/$/
|
27
|
+
locale_param = get_option(options, :locale_param, config.locale_param).to_sym
|
28
|
+
default_locale = get_option(options, :default_locale, config.default_locale).to_sym
|
29
|
+
locale_regexp = get_option(options, :locale_regexp, config.locale_regexp)
|
30
|
+
route_options = get_option(options, :route_options, {}).deep_symbolize_keys
|
31
|
+
|
32
|
+
router.scope(module: :boar) do
|
33
|
+
router.scope("(#{locale_param.inspect})", defaults: {locale_param => default_locale}, constraints: {locale_param => locale_regexp}) do
|
34
|
+
yield(router, options) if block_given?
|
35
|
+
router.match("#{root}(*path)", route_controller(options, "pages#main").merge({via: :get, boar_options: options}).merge(route_options))
|
36
|
+
end
|
37
|
+
end
|
38
|
+
end
|
39
|
+
|
40
|
+
def self.mount_downloads(router, *args)
|
41
|
+
options = args.extract_options!
|
42
|
+
config = Rails.application.config.boar
|
43
|
+
|
44
|
+
root = get_option(options, :root, config.downloads_root)
|
45
|
+
root += "/" if root.present? && root !~ /\/$/
|
46
|
+
route_options = get_option(options, :route_options, {}).deep_symbolize_keys
|
47
|
+
|
48
|
+
router.scope(module: :boar) do
|
49
|
+
yield(router, options) if block_given?
|
50
|
+
router.match("#{root}", {controller: options.fetch(:controller, "downloads"), action: :update, via: :put, boar_options: options}.merge(route_options))
|
51
|
+
router.match("#{root}(*path)", route_controller(options, "downloads#main").merge({via: :get, constraints: {path: /.+/}, boar_options: options}).merge(route_options))
|
52
|
+
end
|
53
|
+
end
|
54
|
+
|
55
|
+
private
|
56
|
+
def self.route_controller(options, default)
|
57
|
+
options[:controller] ? {controller: options[:controller], action: options[:action].ensure_string || :index} : {to: default}
|
58
|
+
end
|
59
|
+
|
60
|
+
def self.get_option(options, key, default = nil)
|
61
|
+
begin
|
62
|
+
options.symbolize_keys.fetch(key.to_sym)
|
63
|
+
rescue Exception => _
|
64
|
+
block_given? ? yield(key) : default
|
65
|
+
end
|
66
|
+
end
|
67
|
+
end
|
68
|
+
end
|
data/lib/boar/version.rb
ADDED
@@ -0,0 +1,25 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
#
|
3
|
+
# This file is part of the boar gem. Copyright (C) 2013 and above Shogun <shogun_panda@me.com>.
|
4
|
+
# Licensed under the MIT license, which can be found at http://www.opensource.org/licenses/mit-license.php.
|
5
|
+
#
|
6
|
+
|
7
|
+
# A Rails engine to handle local static pages and downloads on the cloud.
|
8
|
+
module Boar
|
9
|
+
# The current version of boar, according to semantic versioning.
|
10
|
+
#
|
11
|
+
# @see http://semver.org
|
12
|
+
module Version
|
13
|
+
# The major version.
|
14
|
+
MAJOR = 1
|
15
|
+
|
16
|
+
# The minor version.
|
17
|
+
MINOR = 0
|
18
|
+
|
19
|
+
# The patch version.
|
20
|
+
PATCH = 1
|
21
|
+
|
22
|
+
# The current version of boar.
|
23
|
+
STRING = [MAJOR, MINOR, PATCH].compact.join(".")
|
24
|
+
end
|
25
|
+
end
|
data/lib/tasks/boar.rake
ADDED
@@ -0,0 +1,102 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
#
|
3
|
+
# This file is part of the boar gem. Copyright (C) 2013 and above Shogun <shogun_panda@me.com>.
|
4
|
+
# Licensed under the MIT license, which can be found at http://www.opensource.org/licenses/mit-license.php.
|
5
|
+
#
|
6
|
+
|
7
|
+
# TODO: Rename param here and everywhere else as credentials where appropriate. Could you move them to a class?
|
8
|
+
|
9
|
+
namespace :boar do
|
10
|
+
def setup(args)
|
11
|
+
# Get parameters
|
12
|
+
provider_name = args[:provider].ensure_string
|
13
|
+
host = args[:host].present? ? args[:host].to_s : "localhost"
|
14
|
+
configuration_path = Mustache.render(args[:file].blank? ? Rails.application.config.boar.credentials_file : args[:file], {root: Rails.root})
|
15
|
+
all_configurations = nil
|
16
|
+
configuration = nil
|
17
|
+
provider = nil
|
18
|
+
|
19
|
+
# Find the service
|
20
|
+
begin
|
21
|
+
provider = Lazier.find_class(provider_name, "Boar::Providers::%CLASS%", true).new
|
22
|
+
rescue
|
23
|
+
valids = Boar::Providers.constants.collect {|c| c != :Base && Boar::Providers.const_get(c).is_a?(Class) ? c.to_s : nil }.compact
|
24
|
+
raise RuntimeError.new((provider_name.present? ? "Invalid provider #{provider_name}." : "No provider specified.") + " Valid providers are: #{valids.join(", ")}.")
|
25
|
+
end
|
26
|
+
|
27
|
+
# Open the configuration for the provider
|
28
|
+
begin
|
29
|
+
all_configurations = YAML.load_file(configuration_path)
|
30
|
+
|
31
|
+
# Get host specific configuration
|
32
|
+
configuration = HashWithIndifferentAccess.new(all_configurations[host][provider_name])
|
33
|
+
raise ArgumentError if !configuration.is_a?(Hash)
|
34
|
+
rescue
|
35
|
+
raise RuntimeError.new("Configuration for service #{provider_name.classify} on host #{host} not valid or not found.")
|
36
|
+
end
|
37
|
+
|
38
|
+
{path: configuration_path, all: all_configurations, single: configuration, host: host, provider: provider, name: provider_name}
|
39
|
+
end
|
40
|
+
|
41
|
+
desc "Updates credentials for a service"
|
42
|
+
task :update_credentials, [:provider, :host, :file] => :environment do |_, args|
|
43
|
+
params = setup(args)
|
44
|
+
|
45
|
+
configuration = params[:single]
|
46
|
+
provider = params[:provider]
|
47
|
+
provider_name = params[:name]
|
48
|
+
credentials = nil
|
49
|
+
|
50
|
+
# Authorize provider
|
51
|
+
begin
|
52
|
+
authorizer = Clavem::Authorizer.new(configuration.fetch(:authorizer_host, "localhost"), configuration.fetch(:authorizer_port, "2501")) do |auth, req, res|
|
53
|
+
credentials = provider.get_credentials(auth, req, res)
|
54
|
+
end
|
55
|
+
|
56
|
+
# Get the redirection URL
|
57
|
+
url = provider.redirect_for_authentication(authorizer, configuration)
|
58
|
+
|
59
|
+
# Redirect and fetch new credentials to merge to the old configuration
|
60
|
+
authorizer.authorize(url)
|
61
|
+
rescue => e
|
62
|
+
raise e
|
63
|
+
raise case e.class.to_s
|
64
|
+
when "ArgumentError" then e
|
65
|
+
when "AuthorizationDenied" then Clavem::Exceptions::AuthorizationDenied.new("Authorization denied for provider #{provider_name.classify}.")
|
66
|
+
else RuntimeError.new("Authorization failed for provider #{provider_name.classify}.")
|
67
|
+
end
|
68
|
+
end
|
69
|
+
|
70
|
+
# Update the file
|
71
|
+
begin
|
72
|
+
params[:provider].update_credentials(credentials, params)
|
73
|
+
rescue
|
74
|
+
raise RuntimeError.new("Cannot update configuration file #{params[:path]}.")
|
75
|
+
end
|
76
|
+
end
|
77
|
+
|
78
|
+
desc "Search required information for sharing a file"
|
79
|
+
task :search_file, [:path, :provider, :file] => :environment do |_, args|
|
80
|
+
params = setup(args)
|
81
|
+
path = args[:path]
|
82
|
+
name = params[:name]
|
83
|
+
info = nil
|
84
|
+
|
85
|
+
raise "Please specify a path." if path.blank?
|
86
|
+
begin
|
87
|
+
info = params[:provider].search_file(path, params)
|
88
|
+
rescue => e
|
89
|
+
raise e
|
90
|
+
raise RuntimeError.new("Cannot find file #{path} on #{params[:name]}.")
|
91
|
+
end
|
92
|
+
|
93
|
+
if info.nil? then
|
94
|
+
puts "File #{path} on #{name.classify} doesn't exists."
|
95
|
+
elsif !info then
|
96
|
+
puts "To share on provider #{name.classify} use the path itself."
|
97
|
+
else
|
98
|
+
puts "The required information to share #{path} via #{name.classify} are:\n"
|
99
|
+
puts " " + info.to_yaml.gsub(/^---/, "").gsub("\n", "\n ")
|
100
|
+
end
|
101
|
+
end
|
102
|
+
end
|
@@ -0,0 +1,11 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
#
|
3
|
+
# This file is part of the boar gem. Copyright (C) 2013 and above Shogun <shogun_panda@me.com>.
|
4
|
+
# Licensed under the MIT license, which can be found at http://www.opensource.org/licenses/mit-license.php.
|
5
|
+
#
|
6
|
+
|
7
|
+
require "spec_helper"
|
8
|
+
|
9
|
+
describe Boar::ApplicationController do
|
10
|
+
|
11
|
+
end
|
@@ -0,0 +1,11 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
#
|
3
|
+
# This file is part of the boar gem. Copyright (C) 2013 and above Shogun <shogun_panda@me.com>.
|
4
|
+
# Licensed under the MIT license, which can be found at http://www.opensource.org/licenses/mit-license.php.
|
5
|
+
#
|
6
|
+
|
7
|
+
require "spec_helper"
|
8
|
+
|
9
|
+
describe Boar::PagesController do
|
10
|
+
|
11
|
+
end
|
@@ -0,0 +1,11 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
#
|
3
|
+
# This file is part of the boar gem. Copyright (C) 2013 and above Shogun <shogun_panda@me.com>.
|
4
|
+
# Licensed under the MIT license, which can be found at http://www.opensource.org/licenses/mit-license.php.
|
5
|
+
#
|
6
|
+
|
7
|
+
require "spec_helper"
|
8
|
+
|
9
|
+
describe Boar::Router do
|
10
|
+
|
11
|
+
end
|
data/spec/boar_spec.rb
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
#
|
3
|
+
# This file is part of the boar gem. Copyright (C) 2013 and above Shogun <shogun_panda@me.com>.
|
4
|
+
# Licensed under the MIT license, which can be found at http://www.opensource.org/licenses/mit-license.php.
|
5
|
+
#
|
6
|
+
|
7
|
+
require "pathname"
|
8
|
+
require "simplecov"
|
9
|
+
|
10
|
+
SimpleCov.start do
|
11
|
+
root = Pathname.new(File.dirname(__FILE__)) + ".."
|
12
|
+
|
13
|
+
add_filter do |src_file|
|
14
|
+
path = Pathname.new(src_file.filename).relative_path_from(root).to_s
|
15
|
+
path !~ /\.rb$/ || path !~ /^(app|bin|lib)/
|
16
|
+
end
|
17
|
+
end
|
data/spec/spec_helper.rb
ADDED
@@ -0,0 +1,15 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
#
|
3
|
+
# This file is part of the boar gem. Copyright (C) 2013 and above Shogun <shogun_panda@me.com>.
|
4
|
+
# Licensed under the MIT license, which can be found at http://www.opensource.org/licenses/mit-license.php.
|
5
|
+
#
|
6
|
+
|
7
|
+
require "rubygems"
|
8
|
+
require "bundler/setup"
|
9
|
+
require "boar"
|
10
|
+
|
11
|
+
RSpec.configure do |config|
|
12
|
+
config.expect_with :rspec do |c|
|
13
|
+
c.syntax = :expect
|
14
|
+
end
|
15
|
+
end
|
metadata
ADDED
@@ -0,0 +1,264 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: boar
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 1.0.1
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Shogun
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2019-12-11 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: rails
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: 3.2.12
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ">="
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: 3.2.12
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: mustache
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: 0.99.4
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: 0.99.4
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: mbrao
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: 1.1.1
|
48
|
+
type: :runtime
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: 1.1.1
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: redis
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - "~>"
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: 3.0.3
|
62
|
+
type: :runtime
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - "~>"
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: 3.0.3
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: oj
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: 2.0.10
|
76
|
+
type: :runtime
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: 2.0.10
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: elephas
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - "~>"
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: 3.0.0
|
90
|
+
type: :runtime
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - "~>"
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: 3.0.0
|
97
|
+
- !ruby/object:Gem::Dependency
|
98
|
+
name: clavem
|
99
|
+
requirement: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - "~>"
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: 1.2.2
|
104
|
+
type: :runtime
|
105
|
+
prerelease: false
|
106
|
+
version_requirements: !ruby/object:Gem::Requirement
|
107
|
+
requirements:
|
108
|
+
- - "~>"
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: 1.2.2
|
111
|
+
- !ruby/object:Gem::Dependency
|
112
|
+
name: dropbox-sdk
|
113
|
+
requirement: !ruby/object:Gem::Requirement
|
114
|
+
requirements:
|
115
|
+
- - "~>"
|
116
|
+
- !ruby/object:Gem::Version
|
117
|
+
version: 1.5.1
|
118
|
+
type: :runtime
|
119
|
+
prerelease: false
|
120
|
+
version_requirements: !ruby/object:Gem::Requirement
|
121
|
+
requirements:
|
122
|
+
- - "~>"
|
123
|
+
- !ruby/object:Gem::Version
|
124
|
+
version: 1.5.1
|
125
|
+
- !ruby/object:Gem::Dependency
|
126
|
+
name: google-api-client
|
127
|
+
requirement: !ruby/object:Gem::Requirement
|
128
|
+
requirements:
|
129
|
+
- - "~>"
|
130
|
+
- !ruby/object:Gem::Version
|
131
|
+
version: 0.6.3
|
132
|
+
type: :runtime
|
133
|
+
prerelease: false
|
134
|
+
version_requirements: !ruby/object:Gem::Requirement
|
135
|
+
requirements:
|
136
|
+
- - "~>"
|
137
|
+
- !ruby/object:Gem::Version
|
138
|
+
version: 0.6.3
|
139
|
+
- !ruby/object:Gem::Dependency
|
140
|
+
name: aws-sdk
|
141
|
+
requirement: !ruby/object:Gem::Requirement
|
142
|
+
requirements:
|
143
|
+
- - "~>"
|
144
|
+
- !ruby/object:Gem::Version
|
145
|
+
version: 1.9.5
|
146
|
+
type: :runtime
|
147
|
+
prerelease: false
|
148
|
+
version_requirements: !ruby/object:Gem::Requirement
|
149
|
+
requirements:
|
150
|
+
- - "~>"
|
151
|
+
- !ruby/object:Gem::Version
|
152
|
+
version: 1.9.5
|
153
|
+
- !ruby/object:Gem::Dependency
|
154
|
+
name: ruby-box
|
155
|
+
requirement: !ruby/object:Gem::Requirement
|
156
|
+
requirements:
|
157
|
+
- - "~>"
|
158
|
+
- !ruby/object:Gem::Version
|
159
|
+
version: 1.2.0
|
160
|
+
type: :runtime
|
161
|
+
prerelease: false
|
162
|
+
version_requirements: !ruby/object:Gem::Requirement
|
163
|
+
requirements:
|
164
|
+
- - "~>"
|
165
|
+
- !ruby/object:Gem::Version
|
166
|
+
version: 1.2.0
|
167
|
+
- !ruby/object:Gem::Dependency
|
168
|
+
name: skydrive
|
169
|
+
requirement: !ruby/object:Gem::Requirement
|
170
|
+
requirements:
|
171
|
+
- - "~>"
|
172
|
+
- !ruby/object:Gem::Version
|
173
|
+
version: 0.1.0
|
174
|
+
type: :runtime
|
175
|
+
prerelease: false
|
176
|
+
version_requirements: !ruby/object:Gem::Requirement
|
177
|
+
requirements:
|
178
|
+
- - "~>"
|
179
|
+
- !ruby/object:Gem::Version
|
180
|
+
version: 0.1.0
|
181
|
+
description: A Rails engine to handle local static pages and downloads on the cloud.
|
182
|
+
email:
|
183
|
+
- shogun_panda@me.com
|
184
|
+
executables: []
|
185
|
+
extensions: []
|
186
|
+
extra_rdoc_files: []
|
187
|
+
files:
|
188
|
+
- ".gitignore"
|
189
|
+
- ".travis-gemfile"
|
190
|
+
- ".travis.yml"
|
191
|
+
- ".yardopts"
|
192
|
+
- Gemfile
|
193
|
+
- README.md
|
194
|
+
- Rakefile
|
195
|
+
- app/controllers/boar/application_controller.rb
|
196
|
+
- app/controllers/boar/downloads_controller.rb
|
197
|
+
- app/controllers/boar/pages_controller.rb
|
198
|
+
- app/models/boar/handlers/authentication.rb
|
199
|
+
- app/models/boar/handlers/downloads/base.rb
|
200
|
+
- app/models/boar/handlers/downloads/box_net.rb
|
201
|
+
- app/models/boar/handlers/downloads/dropbox.rb
|
202
|
+
- app/models/boar/handlers/downloads/google_drive.rb
|
203
|
+
- app/models/boar/handlers/downloads/local.rb
|
204
|
+
- app/models/boar/handlers/downloads/remote.rb
|
205
|
+
- app/models/boar/handlers/downloads/s3.rb
|
206
|
+
- app/models/boar/handlers/downloads/sky_drive.rb
|
207
|
+
- app/models/boar/handlers/generic.rb
|
208
|
+
- app/models/boar/handlers/hosts.rb
|
209
|
+
- app/models/boar/handlers/locale.rb
|
210
|
+
- app/models/boar/handlers/path_mapper.rb
|
211
|
+
- app/models/boar/handlers/root.rb
|
212
|
+
- app/models/boar/handlers/views.rb
|
213
|
+
- app/models/boar/services/downloads.rb
|
214
|
+
- app/models/boar/services/generic.rb
|
215
|
+
- app/models/boar/services/pages.rb
|
216
|
+
- app/models/boar/utils/basic.rb
|
217
|
+
- boar.gemspec
|
218
|
+
- lib/boar.rb
|
219
|
+
- lib/boar/configuration.rb
|
220
|
+
- lib/boar/engine.rb
|
221
|
+
- lib/boar/exceptions.rb
|
222
|
+
- lib/boar/providers/base.rb
|
223
|
+
- lib/boar/providers/box_net.rb
|
224
|
+
- lib/boar/providers/dropbox.rb
|
225
|
+
- lib/boar/providers/google_drive.rb
|
226
|
+
- lib/boar/providers/sky_drive.rb
|
227
|
+
- lib/boar/router.rb
|
228
|
+
- lib/boar/version.rb
|
229
|
+
- lib/tasks/boar.rake
|
230
|
+
- spec/boar/controllers/application_controller_spec.rb
|
231
|
+
- spec/boar/controllers/pages_controller_spec.rb
|
232
|
+
- spec/boar/routes_spec.rb
|
233
|
+
- spec/boar_spec.rb
|
234
|
+
- spec/coverage_helper.rb
|
235
|
+
- spec/spec_helper.rb
|
236
|
+
homepage: http://github.com/ShogunPanda/boar
|
237
|
+
licenses: []
|
238
|
+
metadata: {}
|
239
|
+
post_install_message:
|
240
|
+
rdoc_options: []
|
241
|
+
require_paths:
|
242
|
+
- lib
|
243
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
244
|
+
requirements:
|
245
|
+
- - ">="
|
246
|
+
- !ruby/object:Gem::Version
|
247
|
+
version: 1.9.3
|
248
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
249
|
+
requirements:
|
250
|
+
- - ">="
|
251
|
+
- !ruby/object:Gem::Version
|
252
|
+
version: '0'
|
253
|
+
requirements: []
|
254
|
+
rubygems_version: 3.0.3
|
255
|
+
signing_key:
|
256
|
+
specification_version: 4
|
257
|
+
summary: A Rails engine to handle local static pages and downloads on the cloud.
|
258
|
+
test_files:
|
259
|
+
- spec/boar/controllers/application_controller_spec.rb
|
260
|
+
- spec/boar/controllers/pages_controller_spec.rb
|
261
|
+
- spec/boar/routes_spec.rb
|
262
|
+
- spec/boar_spec.rb
|
263
|
+
- spec/coverage_helper.rb
|
264
|
+
- spec/spec_helper.rb
|