diff options
author | Julian Teu <julianteule@gmail.com> | 2018-04-10 18:07:28 +0200 |
---|---|---|
committer | Julian Teu <julianteule@gmail.com> | 2018-04-10 18:07:28 +0200 |
commit | 3e00fc23117a6fbb91d5ca09602f8006c3f2365a (patch) | |
tree | 4e3f2288424a5c09e9815eff04719f620cd7b321 /Scripts/#wiki2P.py# | |
parent | a3443fca6351cbe9ecbbe29a32e358f7534a92a6 (diff) |
Cleanup
Diffstat (limited to 'Scripts/#wiki2P.py#')
-rwxr-xr-x | Scripts/#wiki2P.py# | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/Scripts/#wiki2P.py# b/Scripts/#wiki2P.py# deleted file mode 100755 index 2fb1a10..0000000 --- a/Scripts/#wiki2P.py# +++ /dev/null @@ -1,26 +0,0 @@ -import requests, bs4, re - -# res = requests.get("https://en.wikipedia.org/wiki/Special:Random") -res = requests.get("https://en.wikipedia.org/wiki/Linux") - - -soup = bs4.BeautifulSoup(res.text, "html.parser") - - -element = soup.select("#mw-content-text a[title]") - - -pattern = re.compile("^\/.*") - - -for i in element: - if "Edit section" not in i["title"] and pattern.match(i["href"]): - if "div" not in str(i.parent) and "th" not in str(i.parent) and "td" not in str(i.parent): - try: - i["class"] - except KeyError: - print(i) - break - -print("LOL") - |