Tweet from the terminal
A simple CLI tool to post tweets to X (Twitter) without leaving your terminal.
go install github.com/Shobhit-Nagpal/twt@latestMake sure ~/go/bin is in your PATH.
- Go to developer.x.com
- Create a new app with read and write permissions
- Generate your API keys and access tokens
Create ~/.config/twt/config.json with your credentials:
{
"USERNAME": "your_twitter_handle",
"API_KEY": "your_api_key",
"API_KEY_SECRET": "your_api_key_secret",
"ACCESS_TOKEN": "your_access_token",
"ACCESS_TOKEN_SECRET": "your_access_token_secret"
}# Post a tweet
twt post "Hello from the terminal!"
# View help
twt --helpMIT