Skip to content
This repository was archived by the owner on Nov 2, 2025. It is now read-only.

Commit a04b26e

Browse files
authored
Merge pull request #45 from edoardottt/devel
Devel
2 parents d27344c + 2385697 commit a04b26e

File tree

6 files changed

+187
-71
lines changed

6 files changed

+187
-71
lines changed

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ Usage 🚀
4444
-------
4545

4646
```
47-
usage: twitterbot2.py [-h] [-v] [-t] [-k KEYWORD] [-nu] [-s STATS] [-oc OUTPUT_CSV] [-oj OUTPUT_JSON] [-oh OUTPUT_HTML]
47+
usage: twitterbot2.py [-h] [-v] [-t] [-k KEYWORD] [-nu] [-nl] [-nr] [-s STATS] [-oc OUTPUT_CSV] [-oj OUTPUT_JSON] [-oh OUTPUT_HTML]
4848
4949
Twitterbot v2
5050
@@ -53,8 +53,10 @@ optional arguments:
5353
-v, --version Show the version of this program.
5454
-t, --timeline Search for tweets in the bot and user's timeline.
5555
-k KEYWORD, --keyword KEYWORD
56-
Search for tweets with a defined keyword.
56+
Search for tweets with defined keyword(s). If more than one, comma separated enclosed in double quotes.
5757
-nu, --no-user Don't like and retweet user tweets.
58+
-nl, --no-like Don't like tweets, just retweet.
59+
-nr, --no-retweet Don't retweet tweets, just like.
5860
-s STATS, --stats STATS
5961
Show the statistics of the inputted bot (username).
6062
-oc OUTPUT_CSV, --output-csv OUTPUT_CSV

input.py

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ def get_args():
4141
"-k",
4242
"--keyword",
4343
type=str,
44-
help="Search for tweets with a defined keyword.",
44+
help="Search for tweets with defined keyword(s). If more than one, comma separated enclosed in double quotes.",
4545
)
4646

4747
parser.add_argument(
@@ -51,6 +51,20 @@ def get_args():
5151
help="Don't like and retweet user tweets.",
5252
)
5353

54+
parser.add_argument(
55+
"-nl",
56+
"--no-like",
57+
action="store_true",
58+
help="Don't like tweets, just retweet.",
59+
)
60+
61+
parser.add_argument(
62+
"-nr",
63+
"--no-retweet",
64+
action="store_true",
65+
help="Don't retweet tweets, just like.",
66+
)
67+
5468
group.add_argument(
5569
"-s",
5670
"--stats",

secrets.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@
1212
#
1313

1414
import yaml
15-
import logging
15+
import logging
16+
1617

1718
def read_secrets():
1819
"""

0 commit comments

Comments
 (0)