How to configure your Mac to use DNS over TLS in five easy steps:
-
Install Stubby with Homebrew (https://dnsprivacy.org/wiki/display/DP/DNS+Privacy+Daemon+-+Stubby):
brew install stubby -
Edit the configuration file:
How to configure your Mac to use DNS over TLS in five easy steps:
Install Stubby with Homebrew (https://dnsprivacy.org/wiki/display/DP/DNS+Privacy+Daemon+-+Stubby):
brew install stubby
Edit the configuration file:
| class MyStreamListener(tweepy.StreamListener): | |
| def __init__(self, api=None): | |
| super(MyStreamListener, self).__init__() | |
| self.num_tweets = 0 | |
| self.file = open("tweets.txt", "w") | |
| def on_status(self, status): | |
| tweet = status._json | |
| self.file.write( json.dumps(tweet) + '\n' ) | |
| self.num_tweets += 1 |
| import wx | |
| # define the load function | |
| def load(event): | |
| file = open(filename.GetValue()) | |
| contents.SetValue(file.read()) | |
| file.close() | |
| # define the save function | |
| def save(event): | |
| file = open(filename.GetValue(), 'w') |
| import wx | |
| # define the load function | |
| def load(event): | |
| file = open(filename.GetValue()) | |
| contents.SetValue(file.read()) | |
| file.close() | |
| # define the save function | |
| def save(event): | |
| file = open(filename.GetValue(), 'w') |
| import random | |
| import urllib.request | |
| def download_web_image(url): | |
| num = random.randrange(1, 100) | |
| full_name = str(num) + '.jpg' | |
| urllib.request.urlretrieve(url, full_name) | |
| download_web_image("http://pic.58pic.com/58pic/11/84/23/13A58PIC6ZC.jpg") |