Command-line tool to get photos from Twitter accounts.
Project description
Twitter Photos is a command-line tool to get photos from Twitter accounts.
Requirements
python-twitter
requests
urllib3
Installation
You can install the package with pip:
$ pip install twitter-photos
Or, you can download a source distribution and install with these commands:
$ python setup.py install
Setup
Create a config file at ~/.twphotos specifying your Twitter credentials:
[credentials] consumer_key = your_consumer_key consumer_secret = your_consumer_secret access_token_key = your_access_token_key access_token_secret = your_access_token_secret
Usage
The simplest usage is to run “twphotos” from command-line without any options. This will download all photos from the current authenticated user (you):
$ twphotos
Download all photos from an existing user other yourself with -u option followed by username:
$ twphotos -u wired
Download n most recent photos from a user using -n followed by number:
$ twphotos -u wired -n 20
Download photos to a directory other than the current one:
$ twphotos -u wired -o /path/to/dir
Enable “incremental download” to download new photos since the last downloads with -i:
$ twphotos -u wired -i
Enable “parallel download” to speedup the downloads using the -r switch:
$ twphotos -u wired -r
Print username, tweet ids, and URLs instead of downloading them with -p switch:
$ twphotos -u wired -p
You can retrieve URLs only with cut command:
$ twphotos -u wired -p | cut -d ' ' -f3
Command-line Options
The “soundmeter” command accepts the following options:
- -u USER, --user USER
user account
- -l LIST_SLUG, --list LIST_SLUG
list slug with –user as list owner
- -o OUTDIR, --outdir OUTDIR
output directory
- -p, --print
print media urls and tweet ids instead of download
- -r, --parallel
enable parallel download
- -n NUM, --num NUM
number of most recent photos to download
- -i, --increment
download only new photos since last download
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file twitter-photos-0.1.0.tar.gz
.
File metadata
- Download URL: twitter-photos-0.1.0.tar.gz
- Upload date:
- Size: 7.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
770f4ab88848c1708769a1c2c90ca8b87974742321fd9b1ab345addfd7d54112
|
|
MD5 |
65fcb773f43b404fb2ca58500a654940
|
|
BLAKE2b-256 |
37527a502084a982e25358037b95888d0fa5d7edb49afdc29d80cfb1668d7b97
|