octoauth 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/octoauth/configfile.rb +1 -0
- data/octoauth.gemspec +1 -1
- data/spec/octoauth/configfile_spec.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2b25a87f39c451d0ae889199a813dcf4fbc97fae
|
4
|
+
data.tar.gz: d0234a80a55d0faa0680cd035ec46659889c9738
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cd798d6c1d88c6f03efb8935bc18e27c38d6d4f81b29bf2c37ad35f05e8c279aa261b576fd96d57fb8827e6c86a20f2ac01869d4a3f033fdaee734c23ff75765
|
7
|
+
data.tar.gz: 338c3a73b60d1d02b7abab2c88adf5728cd1b2493a98e9e41b5a472c995ff63c5e2aba81325b436d261943c2985487cfc133609f1adb13e73f25b877a5bd8341
|
data/lib/octoauth/configfile.rb
CHANGED
@@ -17,6 +17,7 @@ module Octoauth
|
|
17
17
|
# Create new Config object, either ephemerally or from a file
|
18
18
|
def initialize(params = {})
|
19
19
|
@file = params[:file] == :default ? DEFAULT_FILE : params[:file]
|
20
|
+
@file = File.expand_path(@file) if @file
|
20
21
|
@note = params[:note] || fail(ArgumentError, 'A note must be provided')
|
21
22
|
@token = parse
|
22
23
|
end
|
data/octoauth.gemspec
CHANGED
@@ -23,7 +23,7 @@ describe Octoauth do
|
|
23
23
|
context 'when give :default' do
|
24
24
|
it 'uses the default file' do
|
25
25
|
config = Octoauth::ConfigFile.new(note: 'foo', file: :default)
|
26
|
-
expect(config.file).to eql Octoauth::DEFAULT_FILE
|
26
|
+
expect(config.file).to eql File.expand_path(Octoauth::DEFAULT_FILE)
|
27
27
|
end
|
28
28
|
end
|
29
29
|
context 'when given no file' do
|