Skip to content

Instantly share code, notes, and snippets.

@hkraji
Created April 17, 2014 11:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hkraji/10974122 to your computer and use it in GitHub Desktop.
Save hkraji/10974122 to your computer and use it in GitHub Desktop.
Remove ssh keys for dtk client
output = `dtk account list-ssh-keys`
output = output.split(/\n/)
output.each do |line|
match = line.match(/[0-9]+ \| (.*) \|/)
if match
identifier = match[1]
puts "Deleting #{identifier} ..."
puts `dtk account delete-ssh-key #{identifier}`
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment