Skip to content

Instantly share code, notes, and snippets.

@0xMilly
Created January 31, 2021 21:05
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 0xMilly/91dddade5ec6bda4f96395b9472cccfc to your computer and use it in GitHub Desktop.
Save 0xMilly/91dddade5ec6bda4f96395b9472cccfc to your computer and use it in GitHub Desktop.
Quick method to scrape Virgil Abloh's published files on public---domain.com - You can then import those URLs into some other software and download the whole collection. It should be around 15GB.
function sleep(ms) {
return new Promise(resolve => setTimeout(resolve, ms));
}
function downloadLinks() {
var a = document.createElement('a');
var file = new Blob([ links.toString() ], { type: 'text/plain' });
a.href = URL.createObjectURL(file);
a.download = 'virgil_abloh_links';
a.click();
}
var links = [];
async function getItems() {
for(let i = 0; i < 17; i++){
document.getElementById("sidebar-item-"+i).click(); //change item
files = document.getElementsByClassName("file-list-item");
for(let i = 0; i < files.length; i++){
files[i].click();
await sleep(250);
a = document.getElementsByClassName("file-name")[0].getElementsByTagName("a")[0].href;
console.log("Got a link: " + a);
links.push(a);
}
}
}
getItems();
downloadLinks();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment