Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/uasi/phog
phog downloads images from Twitter.
https://github.com/uasi/phog
cli downloader image photos twitter
Last synced: about 7 hours ago
JSON representation
phog downloads images from Twitter.
- Host: GitHub
- URL: https://github.com/uasi/phog
- Owner: uasi
- License: apache-2.0
- Created: 2020-08-11T16:57:31.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2022-09-24T17:17:32.000Z (about 2 years ago)
- Last Synced: 2023-04-14T01:31:01.250Z (over 1 year ago)
- Topics: cli, downloader, image, photos, twitter
- Language: Rust
- Homepage:
- Size: 389 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# phog
phog downloads images from Twitter. phog remembers which images you have downloaded and never downloads them again.
## Installation
Precompiled binaries are available for Windows, macOS and Linux. https://github.com/uasi/phog/releases
## Usage
### Logging in to Twitter
Run `phog login`.
```
$ phog loginPreparing login URL...
Open the URL below and log in to Twitter to get a PIN code.https://api.twitter.com/oauth/authorize?oauth_token=XXXXXX
Enter the PIN code (Ctrl-C to quit): 1234567
Logged in successfully.
```### Downloading images
- Use `phog get --user ...` to download from user timelines.
- Use `phog get --likes ...` to download from likes.
- `...` is a list of screen names separated by a comma.
- Use `phog get < tweet_urls.txt` to read URLs from a file.
- Use `phog get --paste` to read URLs from the clipboard.```
$ phog get --user user1,@user2,https://twitter.com/user3 --likes user4Fetched 200 tweets from user1.
Recorded 200 tweets.
Fetched 200 tweets from user2.
Recorded 200 tweets.
Fetched 200 tweets from user3.
Recorded 200 tweets.
Fetched 100 likes from user4.
Recorded 100 tweets.
Downloading photos to "/Users/me/Downloads".
Downloading 2 photosets.
Downloaded @user1-0123456789012345678-img1-XXXXXXXXXXXXXXX.jpg
Downloaded @user1-0123456789012345678-img2-XXXXXXXXXXXXXXY.jpg
Downloaded @user1-0123456789012345679-img1-XXXXXXXXXXXXXXZ.jpg
Done.
```### Configuration
See `~/.config/phog/config.toml` (Linux/macOS) or `%APPDATA%\phog\config.toml` (Windows).
## Building
```
# Optional; if the key and secret are omitted, `phog login` will be disabled.
$ export PHOG_COMPILE_ENV__CONSUMER_KEY=
$ export PHOG_COMPILE_ENV__CONSUMER_SECRET=$ cargo build --release
```