git checkout -b <branchname>
git add
git commit -m "description of changes"
| """ | |
| Usage: | |
| Make sure that redis is running on localhost (or adjust the url) | |
| Install uvicorn or some other asgi server https://asgi.readthedocs.io/en/latest/implementations.html | |
| pip install -u uvicorn | |
| Install dependencies |
| <rss xmlns:atom="http://www.w3.org/2005/Atom" xmlns:media="http://search.yahoo.com/mrss/" version="2.0"> | |
| <channel> | |
| <title>G1 > Loterias</title> | |
| <link>http://g1.globo.com/loterias/index.html</link> | |
| <description> | |
| Veja no G1 Loterias os resultados dos últimos concursos da Mega-Sena, Dupla Sena, Loteria Federal, Loteca, Lotofacil, Lotogol, Lotomania, Quina e Timemania. | |
| </description> | |
| <language>pt-BR</language> | |
| <copyright>© Copyright Globo Comunicação e Participações S.A.</copyright> | |
| <atom:link href="http://pox.globo.com/rss/g1/loterias/" rel="self" type="application/rss+xml"/> |
| import Adafruit_DHT | |
| import time | |
| isRunning = True | |
| while isRunning: | |
| try: | |
| humidity, temperature = Adafruit_DHT.read_retry(Adafruit_DHT.DHT11, 4) | |
| if humidity is not None and temperature is not None: | |
| print('Temp={0:0.1f}* Humidity={1:0.1f}%'.format(temperature, humidity)) | |
| else: |
| """ | |
| Example of setting up CORS with Bottle.py. | |
| """ | |
| from bottle import Bottle, request, response, run | |
| app = Bottle() | |
| @app.hook('after_request') | |
| def enable_cors(): | |
| """ |
my_project/__init__.pysetup.pypython setup.py develop
python setup.py test