Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
T
Twint
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nanahira
Twint
Commits
51069f3e
Commit
51069f3e
authored
Aug 10, 2019
by
Francesco Poldi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added filter_retweets
parent
33d288b4
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
1 deletion
+6
-1
twint/cli.py
twint/cli.py
+2
-0
twint/config.py
twint/config.py
+2
-1
twint/url.py
twint/url.py
+2
-0
No files found.
twint/cli.py
View file @
51069f3e
...
...
@@ -122,6 +122,7 @@ def initialize(args):
c
.
Links
=
args
.
links
c
.
Source
=
args
.
source
c
.
Members_list
=
args
.
members_list
c
.
Filter_retweets
=
args
.
filter_retweets
return
c
def
options
():
...
...
@@ -215,6 +216,7 @@ def options():
" you will get both tweets that might contain links or not."
)
ap
.
add_argument
(
"--source"
,
help
=
"Filter the tweets for specific source client."
)
ap
.
add_argument
(
"--members-list"
,
help
=
"Filter the tweets sent by users in a given list."
)
ap
.
add_argument
(
"-fr"
,
"--filter-retweets"
,
help
=
"Exclude retweets from the results."
,
action
=
"store_true"
)
args
=
ap
.
parse_args
()
return
args
...
...
twint/config.py
View file @
51069f3e
...
...
@@ -71,4 +71,5 @@ class Config:
Min_replies
=
0
Links
=
None
Source
=
None
Members_list
=
None
\ No newline at end of file
Members_list
=
None
Filter_retweets
=
False
\ No newline at end of file
twint/url.py
View file @
51069f3e
...
...
@@ -125,6 +125,8 @@ async def Search(config, init):
q
+=
f
" source:
\"
{config.Source}
\"
"
if
config
.
Members_list
:
q
+=
f
" list:{config.Members_list}"
if
config
.
Filter_retweets
:
q
+=
f
" exclude:nativeretweets exclude:retweets"
if
config
.
Custom_query
:
q
=
config
.
Custom_query
...
...
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