attache 1.0.4 → 1.0.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 9e8d68e04393f581cea8fe67ef01fe24c40a2949
4
- data.tar.gz: f84912ce680a667f13f3df5299c55004ba107e81
3
+ metadata.gz: 712ee55417c8e98d23531489e2e094c5848fbe85
4
+ data.tar.gz: e7961934d82f5da524db5f0e238c8002bfafbc04
5
5
  SHA512:
6
- metadata.gz: dfcdc3b7cb6b9632b3e7a482466aa5790ecfcb7fca0195e26e13c1b71e56c0ff04d9eeadcfe8e4c8c4576c070e74e20ecb1d3df04bec5845702ef312c139faaa
7
- data.tar.gz: bd2c0eb503cac608ef9008542611c10a20b3dadb588f68ab9bdc09897df49fc392ed5b781cbbfd4de3dd483ca91579bd1fb6f59c6c007b02463bde7209f54f39
6
+ metadata.gz: 45e693e294ae935e974c003f7ffbcdf905cb68a73ce87dedccaf7f637a075f29e949ad42390106101b7924325beb67c42c74b3bdd5b9b3f636ac2d6ecc42047e
7
+ data.tar.gz: 3b20dede4e93a1b95eca4cf8e4b37fd0385630729dfd47176b999e1b8b14063637383b09dde95a59ed3ff0c7cf4c4c33f1d2de53089273ed06e9beda0f183700
data/README.md CHANGED
@@ -93,10 +93,10 @@ If you do not want to write down sensitive information like aws access key and s
93
93
 
94
94
  ```
95
95
  # bash
96
- export VHOST="`ruby -ryaml -rjson -e 'puts YAML.load(IO.read("config/vhost.yml")).to_json'`"
96
+ export VHOST=$(bundle exec rake attache:vhost)
97
97
 
98
98
  # heroku
99
- heroku config:set VHOST="`ruby -ryaml -rjson -e 'puts YAML.load(IO.read("config/vhost.yml")).to_json'`"
99
+ heroku config:set VHOST=$(bundle exec rake attache:vhost)
100
100
  ```
101
101
 
102
102
  #### Virtual Host Authorization
data/Rakefile CHANGED
@@ -1,5 +1,6 @@
1
1
  require "bundler/gem_tasks"
2
2
  require 'rspec/core/rake_task'
3
+ require 'attache/tasks'
3
4
 
4
5
  RSpec::Core::RakeTask.new(:spec)
5
6
  task :default => :spec
data/exe/attache CHANGED
@@ -35,6 +35,18 @@ else
35
35
  puts "Initialized Procfile"
36
36
  end
37
37
 
38
+ # rakefile
39
+ if File.exists?("Rakefile")
40
+ puts "Using Rakefile"
41
+ else
42
+ open("Rakefile", "w") do |f|
43
+ f.write <<-EOM.gsub(/^\s+/, '')
44
+ require 'attache/tasks'
45
+ EOM
46
+ end
47
+ puts "Initialized Rakefile"
48
+ end
49
+
38
50
  # rack config
39
51
  if File.exists?("config.ru")
40
52
  puts "Using config.ru"
@@ -0,0 +1,14 @@
1
+ require "rake"
2
+
3
+ namespace :attache do
4
+
5
+ desc "Convert content of FILE to a JSON string; default FILE=config/vhost.yml"
6
+ task :vhost do
7
+ require 'yaml'
8
+ require 'json'
9
+
10
+ file = ENV.fetch("FILE") { "config/vhost.yml" }
11
+ puts YAML.load(IO.read(file)).to_json
12
+ end
13
+
14
+ end
@@ -1,3 +1,3 @@
1
1
  module Attache
2
- VERSION = "1.0.4"
2
+ VERSION = "1.0.5"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: attache
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.4
4
+ version: 1.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - choonkeat
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2015-11-02 00:00:00.000000000 Z
11
+ date: 2015-11-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rack
@@ -52,6 +52,20 @@ dependencies:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
54
  version: '2.14'
55
+ - !ruby/object:Gem::Dependency
56
+ name: net-ssh
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :runtime
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ">="
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
55
69
  - !ruby/object:Gem::Dependency
56
70
  name: fog
57
71
  requirement: !ruby/object:Gem::Requirement
@@ -242,6 +256,7 @@ files:
242
256
  - lib/attache/file_response_body.rb
243
257
  - lib/attache/job.rb
244
258
  - lib/attache/resize_job.rb
259
+ - lib/attache/tasks.rb
245
260
  - lib/attache/tus.rb
246
261
  - lib/attache/tus/upload.rb
247
262
  - lib/attache/upload.rb