Created
July 23, 2020 16:59
-
-
Save xnuk/a4b61c509319775a33b5065d7075f51f to your computer and use it in GitHub Desktop.
This file contains hidden or 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
// https://p.eagate.573.jp 에 로그인한 후 개발자 콘솔에서 이 스크립트를 실행하세요. | |
// !!! 개발자 콘솔이 뭔 뜻인지 모르시면 사용하지 마세요 !!! | |
(async () => { | |
const folder = '/game/bemani/bjm2020/stamp/' | |
const index = folder + 'index.html?contents_id=' | |
const exe = folder + 'exe.html?music_index=' | |
const getHref = str => str.match(/\s+href="([^"]+)"/)[1] | |
const getURLs = async (url, substr) => { | |
const html = await fetch(url, {credentials: 'same-origin'}).then(v => v.text()) | |
return html | |
.match(/<a\s+[^>]+>/g) | |
.filter(str => str.includes(substr)) | |
.map(getHref) | |
} | |
console.log("Wait...") | |
for (const contentUrl of await getURLs(index, index)) | |
for (const exeUrl of await getURLs(contentUrl, exe)) | |
fetch(exeUrl, {credentials: 'same-origin'}) | |
console.log("Done o_<") | |
})() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment