Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mukhbit0/auto_posting_on_x_twitter
Automate Twitter/X Image Posts with Python. This script streamlines social media management by auto-uploading images to Twitter/X with titles and hashtags. Built with Python and Selenium, it uses a persistent Chrome session to avoid repeated logins and skips duplicates for efficiency.
https://github.com/mukhbit0/auto_posting_on_x_twitter
automation mit-license productivity python-automation python-script selenium-webdriver social-media-tools twitter twitter-automation undetected-chromedriver web-automation
Last synced: 6 days ago
JSON representation
Automate Twitter/X Image Posts with Python. This script streamlines social media management by auto-uploading images to Twitter/X with titles and hashtags. Built with Python and Selenium, it uses a persistent Chrome session to avoid repeated logins and skips duplicates for efficiency.
- Host: GitHub
- URL: https://github.com/mukhbit0/auto_posting_on_x_twitter
- Owner: mukhbit0
- License: mit
- Created: 2025-02-04T23:15:07.000Z (7 days ago)
- Default Branch: main
- Last Pushed: 2025-02-05T00:05:04.000Z (7 days ago)
- Last Synced: 2025-02-05T00:22:43.066Z (7 days ago)
- Topics: automation, mit-license, productivity, python-automation, python-script, selenium-webdriver, social-media-tools, twitter, twitter-automation, undetected-chromedriver, web-automation
- Language: Python
- Homepage:
- Size: 112 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# Auto Posting on Twitter/X
![]()
This script automates the process of posting images to Twitter/X. I created this for my Twitter account.
## Features
- Automatically uploads images to Twitter/X
- Adds titles and hashtags to tweets
- Uses a persistent Chrome session to avoid repeated logins
- Skips already processed images to avoid duplicates## Requirements
- Python 3.6+
- `undetected-chromedriver`
- `selenium`## Installation
1. Clone the repository or download the script files.
2. Navigate to the project directory.
3. Install the required packages using the following command:```sh
pip install -r requirements.txt
```## Configuration
### Required
- **YEAR_FOLDER**: Path to the folder containing your images.
- **USER_DATA_DIR**: Path to your Chrome user data directory.### Optional
- **HASHTAGS**: Hashtags to be added to the tweets.
- **MAX_TWEETS_PER_RUN**: Maximum number of tweets to process in one run (default is 10).
- **TEXT_FILE_NAME**: Name of the text file containing additional details for the tweets (default is `details.txt`).## Usage
1. Ensure that the required configurations are set in the script.
2. Run the script using the following command:```sh
python x.py
```3. The script will open a Chrome browser and navigate to Twitter/X.
4. If this is the first time running the script, you will be prompted to log in to Twitter/X. After logging in, press Enter to continue.
5. The script will process up to the specified number of images from the configured folder, uploading them to Twitter/X and adding the necessary details.
6. After processing the images, you will be prompted to publish the tweets manually. Press Enter to continue.
7. The script will save the processed images to the log file and exit.## Contributing
If you would like to contribute to this project, please email [[email protected]](mailto:[email protected]).
## License
This project is licensed under the MIT License. See the [LICENSE](./LICENSE) file for details.
---
## ☕ Support My Work