Skip to content

Commit 501e738

Browse files
committed
fix: token_store expire error
1 parent 633e2b5 commit 501e738

File tree

1 file changed

+17
-4
lines changed

1 file changed

+17
-4
lines changed

Rakefile

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,10 @@ end
144144
def user_credentials_for(scope)
145145
FileUtils.mkdir_p(File.dirname(token_store_path))
146146

147+
puts "## Catch error try to delete token_store_path"
148+
149+
puts token_store_path
150+
147151
if ENV['GOOGLE_CLIENT_ID']
148152
client_id = Google::Auth::ClientId.new(ENV['GOOGLE_CLIENT_ID'], ENV['GOOGLE_CLIENT_SECRET'])
149153
else
@@ -174,15 +178,16 @@ task :googlesitemap do |t, args|
174178
service = WebmastersV3::WebmastersService.new
175179
service.authorization = user_credentials_for(WebmastersV3::AUTH_WEBMASTERS)
176180
service.key = ENV['GOOGLE_API_KEY']
177-
Dir.glob("#{deploy_dir}/**/sitemap.xml") { |file|
181+
Dir.glob("#{deploy_dir}/**/sitemap.xml") do |file|
178182
url = deploy_domain + file.sub( "#{deploy_dir}\/" , "")
179183
puts url
180184
begin
181185
service.submit_sitemap(deploy_domain, url)
182-
rescue
186+
rescue StandardError => e
187+
puts e.backtrace.join("\n")
183188
retry
184189
end
185-
}
190+
end
186191
end
187192

188193

@@ -307,9 +312,17 @@ task :multi_gen_deploy do
307312
queueNames =
308313
[
309314

315+
316+
# 'gcc~11',
317+
# 'gcc~11_cpp',
318+
# 'tensorflow_cpp~2.4',
319+
# 'tensorflow~2.4',
320+
# 'haproxy~2.4'
321+
# 'ansible',
322+
# 'ansible~2.11'
310323
# 'django~3.2',
311324
# 'css',
312-
'prettier',
325+
# 'prettier'
313326
# 'latex',
314327
# 'angularjs~1.8',
315328
# 'typescript',

0 commit comments

Comments
 (0)