Skip to content

Commit

Permalink
Delete unused workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
bjornoleh committed Jan 7, 2025
1 parent 9d3e759 commit ff17798
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 94 deletions.
48 changes: 0 additions & 48 deletions .github/workflows/manage_certificates.yml

This file was deleted.

46 changes: 0 additions & 46 deletions fastlane/Fastfile
Original file line number Diff line number Diff line change
Expand Up @@ -278,52 +278,6 @@ platform :ios do
)
end

desc "Manage Certificates"
lane :manage_certs do
setup_ci if ENV['CI']
ENV["MATCH_READONLY"] = false.to_s

api_key = app_store_connect_api_key(
key_id: "#{FASTLANE_KEY_ID}",
issuer_id: "#{FASTLANE_ISSUER_ID}",
key_content: "#{FASTLANE_KEY}"
)

# Check for expiring certificates
UI.message("Checking for certificates expiring within #{CERT_EXPIRATION_THRESHOLD} days...")

expiring_certs = Spaceship::Portal.certificate.all.select do |cert|
days_to_expire = (cert.expires - Time.now) / (60 * 60 * 24)
days_to_expire < CERT_EXPIRATION_THRESHOLD.to_i
end

if expiring_certs.empty?
UI.success("No certificates are expiring within the next #{CERT_EXPIRATION_THRESHOLD} days.")
else
UI.message("Found #{expiring_certs.count} expiring certificates:")
expiring_certs.each do |cert|
UI.message(" - #{cert.name} (expires on #{cert.expires})")
end

# Renew certificates
UI.message("Renewing certificates...")
match(
type: "appstore",
force: true,
git_basic_authorization: Base64.strict_encode64("#{GITHUB_REPOSITORY_OWNER}:#{GH_PAT}"),
app_identifier: [
"com.#{TEAMID}.loopkit.Loop",
"com.#{TEAMID}.loopkit.Loop.statuswidget",
"com.#{TEAMID}.loopkit.Loop.LoopWatch.watchkitextension",
"com.#{TEAMID}.loopkit.Loop.LoopWatch",
"com.#{TEAMID}.loopkit.Loop.Loop-Intent-Extension",
"com.#{TEAMID}.loopkit.Loop.LoopWidgetExtension",
]
)
UI.success("Certificates renewed successfully.")
end
end

desc "Check Certificates"
lane :check_and_revoke_certificates do
setup_ci if ENV['CI']
Expand Down

0 comments on commit ff17798

Please sign in to comment.