Skip to content

Instantly share code, notes, and snippets.

View antoniotrento's full-sized avatar
🎯
Focusing

Antonio Trento antoniotrento

🎯
Focusing
View GitHub Profile
@antoniotrento
antoniotrento / scrape.py
Created March 25, 2017 18:10
Web Scraping for Email Addresses and Phone numbers using Python
# Small Python Script to scrape websites for
# email addresses and phone numbers(not a very great RE)
# Author: Dhruv Baldawa (@dhruvbaldawa on twitter)
# Github: http://www.github.com/dhruvbaldawa
import urllib,re
f = urllib.urlopen("http://www.example.com")
s = f.read()
re.findall(r"\+\d{2}\s?0?\d{10}",s)
re.findall(r"[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,4}",s)
@antoniotrento
antoniotrento / extract_emails_from_text.py
Created March 20, 2017 23:28 — forked from dideler/example.md
A python script for extracting email addresses from text files. You can pass it multiple files. It prints the email addresses to stdout, one address per line. For ease of use, remove the .py extension and place it in your $PATH (e.g. /usr/local/bin/) to run it like a built-in command.
#!/usr/bin/env python
#
# Extracts email addresses from one or more plain text files.
#
# Notes:
# - Does not save to file (pipe the output to a file if you want it saved).
# - Does not check for duplicates (which can easily be done in the terminal).
#
# (c) 2013 Dennis Ideler <ideler.dennis@gmail.com>
@antoniotrento
antoniotrento / mediaqueries.css
Created February 20, 2017 09:39 — forked from needim/mediaqueries.css
Device Specific CSS Media Queries Collection
/*
Based on:
1. http://stephen.io/mediaqueries
2. https://css-tricks.com/snippets/css/media-queries-for-standard-devices/
*/
/* iPhone 6 in portrait & landscape */
@media only screen
and (min-device-width : 375px)
and (max-device-width : 667px) {
@antoniotrento
antoniotrento / keybase.md
Created November 7, 2016 10:37
keybase account verification

Keybase proof

I hereby claim:

  • I am antoniotrento on github.
  • I am antoniotrento (https://keybase.io/antoniotrento) on keybase.
  • I have a public key whose fingerprint is 164F 7247 709A FB1E F667 D32A E6A7 0EDE 3027 8EA5

To claim this, I am signing this object:

@antoniotrento
antoniotrento / CSS3 Media Queries Template
Created November 24, 2015 03:03
CSS3 Media Queries template
/*
* Author: http://stuffandnonsense.co.uk/blog/about/hardboiled_css3_media_queries/
*/
/* Smartphones (portrait and landscape) ----------- */
@media only screen
and (min-device-width : 320px)
and (max-device-width : 480px) {
/* Styles */
}