Created
October 13, 2019 09:17
-
-
Save A/a252f320a7e36566ef7455935e4f6c74 to your computer and use it in GitHub Desktop.
Just a js snippet to automagically remove opened repository
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const sleep = (t) => new Promise((resolve, reject) => { | |
setTimeout(resolve, t); | |
}); | |
(async () => { | |
$('a[data-selected-links*=key_links_settings]').click(); | |
await sleep(3000); | |
document.querySelectorAll('summary.btn-danger')[2].click(); | |
await sleep(3000); | |
const name = document.querySelectorAll('.Box-body.overflow-auto p strong')[2].textContent; | |
const input = document.querySelectorAll('input[name=verify]')[1]; | |
input.value = name; | |
const button = input.parentElement.parentElement.querySelector('button'); | |
button.disabled = false; | |
button.click(); | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment