Skip to content

Commit

Permalink
히히
Browse files Browse the repository at this point in the history
버그 없다
  • Loading branch information
franknoh committed Aug 22, 2021
1 parent 42b3571 commit 6cea19f
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 1,704 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
# AIME-parser

downloads problems&solutions from https://artofproblemsolving.com and converts them to pdf
51 changes: 0 additions & 51 deletions index.html

This file was deleted.

20 changes: 12 additions & 8 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -82,21 +82,25 @@ getHtml('/wiki/index.php/AIME_Problems_and_Solutions')
$("div.printfooter").remove();
$("div.catlinks").remove();
htmldata='<!doctype html><html><head><title>김치볶음밥소고기</title></head><body>'+$bodyList.html().split('//').join('http://')+'</body></html>'
fs.writeFileSync('index.html',htmldata);
//fs.writeFileSync('index.html',htmldata);
log(e.name+'-'+f);
all+=$bodyList.html().split('//').join('http://')+'\n\n';
pdf.create($bodyList.html().split('//').join('http://'), options).toFile('./pdf/'+e.name+'/'+e.name+'-'+f+'.pdf', function(err, res) {
if (err) return console.log(err);
console.log(res);
});
if(res.indexOf(e)==res.length-1){
if(all!==''){
pdf.create(all, options).toFile('./pdf/all.pdf', function(err, res) {
if (err) return console.log(err);
console.log(res);

console.log('done!')
});
}
}
})
}
}
})
})
// .then(async () => {
// if(all!==''){pdf.create(all, options).toFile('./pdf/all.pdf', function(err, res) {
// if (err) return console.log(err);
// console.log(res);
// });}
// })
})
Loading

0 comments on commit 6cea19f

Please sign in to comment.