Files
twitter-cli-cookiefile/pyproject.toml
jackwener 7fb02ba18c feat: cookie file cache with TTL + user --json
- Cookie cache: save to ~/.cache/twitter-cli/cookies.json (24h TTL)
- On 401/403 auth failure: auto-invalidate cache, re-extract from browser
- Cache uses 0600 permissions for security
- Add --json option to twitter user command for scripting
- Priority: env vars → cache file → browser extraction
2026-03-09 21:47:23 +08:00

61 lines
1.6 KiB
TOML

[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[project]
name = "twitter-cli"
version = "0.4.6"
description = "A CLI for Twitter/X — feed, bookmarks, and user timeline in terminal"
readme = "README.md"
license = "Apache-2.0"
requires-python = ">=3.8"
authors = [{ name = "jackwener", email = "jakevingoo@gmail.com" }]
keywords = ["twitter", "x", "cli", "feed", "timeline"]
classifiers = [
"Development Status :: 3 - Alpha",
"Environment :: Console",
"Intended Audience :: Developers",
"License :: OSI Approved :: Apache Software License",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Topic :: Utilities",
]
dependencies = [
"browser-cookie3>=0.19",
"click>=8.0",
"rich>=13.0",
"PyYAML>=6.0",
"curl_cffi>=0.7",
"xclienttransaction>=1.0.1",
"beautifulsoup4>=4.12",
]
[project.optional-dependencies]
dev = [
"pytest>=8.0",
"ruff>=0.8",
]
[project.urls]
Homepage = "https://github.com/jackwener/twitter-cli"
Repository = "https://github.com/jackwener/twitter-cli"
Issues = "https://github.com/jackwener/twitter-cli/issues"
[project.scripts]
twitter = "twitter_cli.cli:cli"
[tool.pytest.ini_options]
testpaths = ["tests"]
python_files = ["test_*.py"]
[tool.ruff]
line-length = 100
[tool.hatch.build.targets.wheel]
packages = ["twitter_cli"]