Sha256: ae5a276353f94458370f625fab7943289431693e374b442563004679e586741b

Contents?: true

Size: 281 Bytes

Versions: 17

Compression:

Stored size: 281 Bytes

Contents

module PushbulletRuby
  class Token

    def self.load(filename = 'token.json')
      begin
        File.open(File.expand_path(filename), 'r') do |f|
          JSON.parse(f.read)['token']
        end
      rescue => error
        puts error
      end
    end
  end
end

Version data entries

17 entries across 16 versions & 2 rubygems

Version Path
tdiary-5.1.6 vendor/bundle/ruby/2.7.0/gems/pushbullet_ruby-1.1.4/lib/pushbullet_ruby/token.rb
tdiary-5.1.6 vendor/bundle/ruby/2.7.0/gems/tdiary-5.1.5/vendor/bundle/ruby/3.0.0/gems/pushbullet_ruby-1.1.4/lib/pushbullet_ruby/token.rb
tdiary-5.1.5 vendor/bundle/ruby/3.0.0/gems/pushbullet_ruby-1.1.4/lib/pushbullet_ruby/token.rb
tdiary-5.1.2 vendor/bundle/ruby/2.6.0/gems/pushbullet_ruby-1.1.4/lib/pushbullet_ruby/token.rb
tdiary-5.1.1 vendor/bundle/ruby/2.6.0/gems/pushbullet_ruby-1.1.4/lib/pushbullet_ruby/token.rb
pushbullet_ruby-1.1.4 lib/pushbullet_ruby/token.rb
tdiary-5.0.8 vendor/bundle/gems/pushbullet_ruby-1.1.3/lib/pushbullet_ruby/token.rb
pushbullet_ruby-1.1.3 lib/pushbullet_ruby/token.rb
pushbullet_ruby-1.1.2 lib/pushbullet_ruby/token.rb
pushbullet_ruby-1.1.1 lib/pushbullet_ruby/token.rb
pushbullet_ruby-1.1.0 lib/pushbullet_ruby/token.rb
pushbullet_ruby-1.0.4.1 lib/pushbullet_ruby/token.rb
pushbullet_ruby-1.0.4 lib/pushbullet_ruby/token.rb
pushbullet_ruby-1.0.3 lib/pushbullet_ruby/token.rb
pushbullet_ruby-1.0.2.1 lib/pushbullet_ruby/token.rb
pushbullet_ruby-1.0.2 lib/pushbullet_ruby/token.rb
pushbullet_ruby-1.0.1 lib/pushbullet_ruby/token.rb