Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
BabelZoo
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
PLN
BabelZoo
Commits
425b8bf6
Unverified
Commit
425b8bf6
authored
Nov 18, 2019
by
PLN (Algolia)
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat(Tweeper): Executable, pause before tweet
parent
982d93d8
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
2 deletions
+5
-2
tweeper.py
KoozDawa/tweeper.py
+5
-2
No files found.
KoozDawa/tweeper.py
100644 → 100755
View file @
425b8bf6
#! /usr/bin/env python
import
os
import
time
import
tweepy
from
didyoumean3.didyoumean
import
did_you_mean
...
...
@@ -18,11 +19,13 @@ class Tweeper(object):
def
tweet
(
self
,
message
):
"""Tweets a message after spellchecking it."""
message
=
did_you_mean
(
message
)
print
(
"About to tweet:"
,
message
)
time
.
sleep
(
5
)
self
.
api
.
update_status
(
message
)
def
main
():
Tweeper
()
.
tweet
(
"
tête daffiche comme la cannelle
"
)
Tweeper
()
.
tweet
(
"
un pont de paris sen souvient sur de toi
"
)
# Authenticate to Twitter
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment