[SCM] ci-tooling packaging branch, master, updated. 35277096009b100c57e0ab254be94b0a2e2756f2

Harald Sitter apachelogger-guest at moszumanska.debian.org
Mon Dec 7 12:57:51 UTC 2015


Gitweb-URL: http://git.debian.org/?p=pkg-kde/ci-tooling.git;a=commitdiff;h=bd19c47

The following commit has been merged in the master branch:
commit bd19c4791d2a7829feb13c419f285fe32f179652
Author: Harald Sitter <sitter at kde.org>
Date:   Mon Dec 7 13:46:08 2015 +0100

    documentation++
---
 lib/lp.rb | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/lib/lp.rb b/lib/lp.rb
index 38ecb95..324e967 100644
--- a/lib/lp.rb
+++ b/lib/lp.rb
@@ -58,12 +58,14 @@ module Launchpad
     }
   end
 
+  # @!visibility private
   def self.conf
     conf = "#{@conf_path}/tooling/confined/lp-tokens.json"
     conf = "#{@conf_path}/.config/lp-tokens.json" unless File.exist?(conf)
     conf
   end
 
+  # @!visibility private
   def self.token_from_file(file)
     return nil unless File.exist?(file)
     JSON.parse(File.read(file), symbolize_names: true)
@@ -83,6 +85,8 @@ module Launchpad
     @token = OAuth::AccessToken.from_hash(consumer, token_hash)
   end
 
+  # @!visibility private
+  # @note NOT thread safe
   def self.request_token
     site_options = { scheme: :header, site: 'https://api.launchpad.net' }
     consumer_options = consumer_options.merge(site_options)
@@ -102,13 +106,11 @@ module Launchpad
   def self.authenticate
     # Fun story, during auth for some reason launchpad needs the flags in the
     # body while at usage it only works with flags in the header...
-
     token_hash = token_from_file(conf)
     unless token_hash
       token_hash = request_token
       File.write(conf, JSON.fast_generate(token_hash))
     end
-
     token
   end
 

-- 
ci-tooling packaging



More information about the pkg-kde-commits mailing list