Created
December 22, 2009 06:24
-
-
Save fitorec/261548 to your computer and use it in GitHub Desktop.
Mostrando NUM replicas del twitter util pa intregrar al conky
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
#-*- coding: utf-8 -*- | |
# Copyright GNU/GPL 3.0 Fitorec <chanerec@gmail.com> | |
# twitterGetReplies.py | |
# ____ _ _ .--. | |
# | __ |(_) | | ___ ____ ___ ____ | o_o | | |
# | | _ | ||_ _|/ _ \ / __// _ \ / __/ | :_/ | | |
# | __ || | | || (_) || | | __/| (__ // \ \ | |
# |_| |_| | | \___/ |_| \___/ \___( (| | ) | |
# http://fitorec.wordpress.com /'\_ _/ | |
# \___)=(___/ | |
# Creado : 22.12.2009 | |
# | |
# Descripcion: | |
# Ejemplo practico: Mostrando NUM replicas del twitter útil pa integrar al conky | |
# requiere: El modulo de twitter de python | |
# Instalación: apt-get install python-twitter python-twyt | |
# | |
# ============= Configuracion ================= | |
USER = "miUsuario" # usuario | |
PASS = "miPassword" #password | |
NUM = 5 #numero de replies x mostrar <=20 | |
#=============================================== | |
import twitter | |
api = twitter.Api(username = USER , password = PASS) | |
replies = api.GetReplies() | |
for i in range(NUM): | |
rep = "@"+replies[i].user.screen_name+": "+replies[i].text | |
print rep |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment