mirror of
https://github.com/Alvin-Zilverstand/Twitter-X-Media-Batch-Downloader.git
synced 2026-11-24 07:13:11 +01:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3d1fd7d1fb | ||
|
|
c0885b1812 | ||
|
|
1ca5c613ae | ||
|
|
596ba9bb3c | ||
|
|
a1cbb04402 | ||
|
|
ddf6439893 | ||
|
|
fed2bf7b0c | ||
|
|
241884de89 | ||
|
|
77b443ace0 | ||
|
|
cd48b6f9bc | ||
|
|
6f45b48047 | ||
|
|
7083c56c8b | ||
|
|
60cb3cbabd | ||
|
|
b38bff238a | ||
|
|
d4d216ed6b | ||
|
|
129c007f6f |
No files matched your search
@@ -8,9 +8,9 @@
|
||||
|
||||
## 📥 Download
|
||||
|
||||
- **Windows**: [TwitterXMediaBatchDownloader](https://github.com/afkarxyz/Twitter-X-Media-Batch-Downloader/releases/download/v3.0/TwitterXMediaBatchDownloader.exe)
|
||||
- **Linux**: [TwitterXMediaBatchDownloader](https://github.com/afkarxyz/Twitter-X-Media-Batch-Downloader/releases/download/v3.0/TwitterXMediaBatchDownloader)
|
||||
- **Mac**: [TwitterXMediaBatchDownloader](https://github.com/afkarxyz/Twitter-X-Media-Batch-Downloader/releases/download/v3.0/TwitterXMediaBatchDownloader.app.zip)
|
||||
- **Windows (Latest)**: [TwitterXMediaBatchDownloader](https://github.com/afkarxyz/Twitter-X-Media-Batch-Downloader/releases/download/v3.2/TwitterXMediaBatchDownloader.exe)
|
||||
- **Linux**: [TwitterXMediaBatchDownloader](https://github.com/afkarxyz/Twitter-X-Media-Batch-Downloader/releases/download/v3.1/TwitterXMediaBatchDownloader)
|
||||
- **Mac**: [TwitterXMediaBatchDownloader](https://github.com/afkarxyz/Twitter-X-Media-Batch-Downloader/releases/download/v3.1/TwitterXMediaBatchDownloader.app.zip)
|
||||
- If you're familiar with **userscripts**, please install it [here](https://greasyfork.org/en/scripts/523157)
|
||||
|
||||
### The downloaded application won't run❓
|
||||
@@ -19,10 +19,9 @@
|
||||
|
||||
```bash
|
||||
chmod +x TwitterXMediaBatchDownloader
|
||||
./TwitterXMediaBatchDownloader
|
||||
```
|
||||
|
||||
https://github.com/user-attachments/assets/2048555f-393e-469d-a8bd-4275e33a81bd
|
||||
https://github.com/user-attachments/assets/41231de2-e665-4d61-a4f4-62f424973af3
|
||||
|
||||
🍎 **Solution (macOS)**: Open your terminal and run:
|
||||
|
||||
@@ -30,7 +29,7 @@ https://github.com/user-attachments/assets/2048555f-393e-469d-a8bd-4275e33a81bd
|
||||
xattr -rd com.apple.quarantine ~/Downloads/TwitterXMediaBatchDownloader.app
|
||||
```
|
||||
|
||||
https://github.com/user-attachments/assets/f0fcd2ba-e1dd-4205-bda7-2b4154b982ee
|
||||
https://github.com/user-attachments/assets/56a89c03-29ab-45f1-979f-4317f45191f7
|
||||
|
||||
## ✨ Features
|
||||
|
||||
@@ -42,11 +41,9 @@ https://github.com/user-attachments/assets/f0fcd2ba-e1dd-4205-bda7-2b4154b982ee
|
||||
|
||||
## 🖼️ Screenshots
|
||||
|
||||

|
||||

|
||||
|
||||

|
||||
|
||||

|
||||

|
||||
|
||||
## 🐧 Build Yourself (Ubuntu/Linux)
|
||||
|
||||
@@ -83,13 +80,7 @@ pip install pyinstaller
|
||||
pyinstaller --onefile --windowed TwitterXMediaBatchDownloader.py
|
||||
```
|
||||
|
||||
### 6. Run the Application
|
||||
|
||||
The compiled binary will be located in the `dist/` folder:
|
||||
|
||||
```bash
|
||||
./dist/TwitterXMediaBatchDownloader
|
||||
```
|
||||
The compiled binary will be located in the `dist/` folder.
|
||||
|
||||
## 🍎 Build Yourself (macOS)
|
||||
|
||||
|
||||
File diff suppressed because it is too large.
Load diff
@@ -313,26 +313,20 @@ class DownloadWorker(QThread):
|
||||
class UpdateDialog(QDialog):
|
||||
def __init__(self, current_version, new_version, parent=None):
|
||||
super().__init__(parent)
|
||||
self.setWindowTitle("Update Available")
|
||||
self.setWindowTitle("Update Now")
|
||||
self.setFixedWidth(400)
|
||||
self.setModal(True)
|
||||
|
||||
layout = QVBoxLayout()
|
||||
|
||||
message = QLabel(f"A new version of Twitter/X Media Batch Downloader is available!\n\n"
|
||||
f"Current version: v{current_version}\n"
|
||||
f"New version: v{new_version}")
|
||||
message = QLabel(f"Twitter/X Media Batch Downloader v{new_version} Available!")
|
||||
message.setWordWrap(True)
|
||||
layout.addWidget(message)
|
||||
|
||||
self.disable_check = QCheckBox("Turn off update checking")
|
||||
self.disable_check.setCursor(Qt.CursorShape.PointingHandCursor)
|
||||
layout.addWidget(self.disable_check)
|
||||
|
||||
button_box = QDialogButtonBox()
|
||||
self.update_button = QPushButton("Update")
|
||||
self.update_button = QPushButton("Check")
|
||||
self.update_button.setCursor(Qt.CursorShape.PointingHandCursor)
|
||||
self.cancel_button = QPushButton("Cancel")
|
||||
self.cancel_button = QPushButton("Later")
|
||||
self.cancel_button.setCursor(Qt.CursorShape.PointingHandCursor)
|
||||
|
||||
button_box.addButton(self.update_button, QDialogButtonBox.ButtonRole.AcceptRole)
|
||||
@@ -348,7 +342,7 @@ class UpdateDialog(QDialog):
|
||||
class TwitterMediaDownloaderGUI(QWidget):
|
||||
def __init__(self):
|
||||
super().__init__()
|
||||
self.current_version = "3.1"
|
||||
self.current_version = "3.3"
|
||||
self.accounts = []
|
||||
self.temp_dir = os.path.join(tempfile.gettempdir(), "twitterxmediabatchdownloader")
|
||||
os.makedirs(self.temp_dir, exist_ok=True)
|
||||
@@ -401,15 +395,11 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
dialog = UpdateDialog(self.current_version, new_version, self)
|
||||
result = dialog.exec()
|
||||
|
||||
if dialog.disable_check.isChecked():
|
||||
self.settings.setValue('check_for_updates', False)
|
||||
self.check_for_updates = False
|
||||
|
||||
if result == QDialog.DialogCode.Accepted:
|
||||
QDesktopServices.openUrl(QUrl("https://github.com/afkarxyz/Twitter-X-Media-Batch-Downloader/releases"))
|
||||
|
||||
except Exception as e:
|
||||
print(f"Error checking for updates: {e}")
|
||||
pass
|
||||
|
||||
def reset_state(self):
|
||||
self.accounts.clear()
|
||||
@@ -431,9 +421,8 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
|
||||
def initUI(self):
|
||||
self.setWindowTitle('Twitter/X Media Batch Downloader')
|
||||
self.setMinimumWidth(650)
|
||||
self.setMinimumHeight(350)
|
||||
self.resize(650, 350)
|
||||
self.setMinimumWidth(670)
|
||||
self.setMinimumHeight(350)
|
||||
|
||||
icon_path = os.path.join(os.path.dirname(__file__), "icon.svg")
|
||||
if os.path.exists(icon_path):
|
||||
@@ -487,7 +476,6 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
QListWidget {
|
||||
background-color: palette(base);
|
||||
border: 1px solid palette(mid);
|
||||
border-radius: 4px;
|
||||
padding: 0px;
|
||||
outline: none;
|
||||
}
|
||||
@@ -495,7 +483,6 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
padding: 8px 12px;
|
||||
margin: 2px 0px;
|
||||
border: none;
|
||||
border-radius: 4px;
|
||||
outline: none;
|
||||
}
|
||||
QListWidget::item:selected {
|
||||
@@ -508,7 +495,7 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
outline: none;
|
||||
}
|
||||
QListWidget::item:hover {
|
||||
background-color: palette(midlight);
|
||||
background-color: palette(highlight);
|
||||
}
|
||||
""")
|
||||
|
||||
@@ -529,7 +516,7 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
self.clear_btn = QPushButton('Clear')
|
||||
|
||||
for btn in [self.download_selected_btn, self.download_all_btn, self.remove_btn, self.clear_btn]:
|
||||
btn.setFixedWidth(150)
|
||||
btn.setMinimumWidth(120)
|
||||
btn.setCursor(Qt.CursorShape.PointingHandCursor)
|
||||
|
||||
self.download_selected_btn.clicked.connect(self.download_selected)
|
||||
@@ -539,7 +526,7 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
|
||||
self.btn_layout.addStretch()
|
||||
for btn in [self.download_selected_btn, self.download_all_btn, self.remove_btn, self.clear_btn]:
|
||||
self.btn_layout.addWidget(btn)
|
||||
self.btn_layout.addWidget(btn, 1)
|
||||
self.btn_layout.addStretch()
|
||||
|
||||
def setup_process_tab(self):
|
||||
@@ -567,8 +554,8 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
self.stop_btn = QPushButton('Stop')
|
||||
self.pause_resume_btn = QPushButton('Pause')
|
||||
|
||||
self.stop_btn.setFixedWidth(150)
|
||||
self.pause_resume_btn.setFixedWidth(150)
|
||||
self.stop_btn.setFixedWidth(120)
|
||||
self.pause_resume_btn.setFixedWidth(120)
|
||||
self.stop_btn.setCursor(Qt.CursorShape.PointingHandCursor)
|
||||
self.pause_resume_btn.setCursor(Qt.CursorShape.PointingHandCursor)
|
||||
|
||||
@@ -587,7 +574,7 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
self.stop_fetch_btn = QPushButton('Stop Fetch')
|
||||
|
||||
for btn in [self.next_batch_btn, self.auto_batch_btn, self.stop_fetch_btn]:
|
||||
btn.setFixedWidth(150)
|
||||
btn.setFixedWidth(120)
|
||||
btn.setCursor(Qt.CursorShape.PointingHandCursor)
|
||||
|
||||
self.next_batch_btn.setToolTip("Fetch next batch manually")
|
||||
@@ -636,6 +623,7 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
self.output_dir.setText(self.last_output_path)
|
||||
self.output_dir.textChanged.connect(self.save_settings)
|
||||
self.output_browse = QPushButton('Browse')
|
||||
self.output_browse.setFixedWidth(100)
|
||||
self.output_browse.setCursor(Qt.CursorShape.PointingHandCursor)
|
||||
self.output_browse.clicked.connect(self.browse_output)
|
||||
|
||||
@@ -657,7 +645,7 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
auth_token_label = QLabel('Auth Token:')
|
||||
|
||||
self.auth_token_input = QLineEdit()
|
||||
self.auth_token_input.setPlaceholderText("Enter your Twitter/X auth_token")
|
||||
self.auth_token_input.setPlaceholderText("Enter Auth Token")
|
||||
self.auth_token_input.setText(self.last_auth_token)
|
||||
self.auth_token_input.textChanged.connect(self.save_settings)
|
||||
self.auth_token_input.setClearButtonEnabled(True)
|
||||
@@ -679,7 +667,7 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
first_row_layout = QHBoxLayout()
|
||||
first_row_layout.setSpacing(5)
|
||||
|
||||
self.batch_checkbox = QCheckBox("Batch")
|
||||
self.batch_checkbox = QCheckBox("Fetch Batch")
|
||||
self.batch_checkbox.setCursor(Qt.CursorShape.PointingHandCursor)
|
||||
self.batch_checkbox.setToolTip("Enable for accounts with thousands of media")
|
||||
self.batch_checkbox.stateChanged.connect(self.handle_batch_checkbox)
|
||||
@@ -745,7 +733,7 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
download_layout.addWidget(download_label)
|
||||
|
||||
batch_layout = QHBoxLayout()
|
||||
batch_label = QLabel('Batch Size:')
|
||||
batch_label = QLabel('Concurrent Downloads:')
|
||||
|
||||
self.download_batch_combo = QComboBox()
|
||||
self.download_batch_combo.setCursor(Qt.CursorShape.PointingHandCursor)
|
||||
@@ -764,7 +752,7 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
batch_layout.addWidget(self.download_batch_combo)
|
||||
batch_layout.addWidget(self.convert_gif_checkbox)
|
||||
|
||||
self.gif_resolution_label = QLabel("GIF Quality:")
|
||||
self.gif_resolution_label = QLabel("Converted GIF Quality:")
|
||||
self.gif_resolution_combo = QComboBox()
|
||||
self.gif_resolution_combo.setCursor(Qt.CursorShape.PointingHandCursor)
|
||||
self.gif_resolution_combo.setFixedWidth(85)
|
||||
@@ -797,15 +785,15 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
about_tab = QWidget()
|
||||
about_layout = QVBoxLayout()
|
||||
about_layout.setAlignment(Qt.AlignmentFlag.AlignCenter)
|
||||
about_layout.setSpacing(3)
|
||||
about_layout.setSpacing(15)
|
||||
|
||||
sections = [
|
||||
("Check for Updates", "https://github.com/afkarxyz/Twitter-X-Media-Batch-Downloader/releases"),
|
||||
("Report an Issue", "https://github.com/afkarxyz/Twitter-X-Media-Batch-Downloader/issues"),
|
||||
("gallery-dl Repository", "https://github.com/mikf/gallery-dl")
|
||||
("Check for Updates", "Check", "https://github.com/afkarxyz/Twitter-X-Media-Batch-Downloader/releases"),
|
||||
("Report an Issue", "Report", "https://github.com/afkarxyz/Twitter-X-Media-Batch-Downloader/issues"),
|
||||
("gallery-dl Repository", "Visit", "https://github.com/mikf/gallery-dl")
|
||||
]
|
||||
|
||||
for title, url in sections:
|
||||
for title, button_text, url in sections:
|
||||
section_widget = QWidget()
|
||||
section_layout = QVBoxLayout(section_widget)
|
||||
section_layout.setSpacing(10)
|
||||
@@ -816,34 +804,18 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
label.setAlignment(Qt.AlignmentFlag.AlignCenter)
|
||||
section_layout.addWidget(label)
|
||||
|
||||
button = QPushButton("Click Here!")
|
||||
button.setFixedWidth(150)
|
||||
button.setStyleSheet("""
|
||||
QPushButton {
|
||||
background-color: palette(button);
|
||||
color: palette(button-text);
|
||||
border: 1px solid palette(mid);
|
||||
padding: 6px;
|
||||
border-radius: 15px;
|
||||
}
|
||||
QPushButton:hover {
|
||||
background-color: palette(light);
|
||||
}
|
||||
QPushButton:pressed {
|
||||
background-color: palette(midlight);
|
||||
}
|
||||
""")
|
||||
button = QPushButton(button_text)
|
||||
button.setFixedSize(120, 25)
|
||||
button.setCursor(Qt.CursorShape.PointingHandCursor)
|
||||
button.clicked.connect(lambda _, url=url: QDesktopServices.openUrl(QUrl(url if url.startswith(('http://', 'https://')) else f'https://{url}')))
|
||||
section_layout.addWidget(button, alignment=Qt.AlignmentFlag.AlignCenter)
|
||||
about_layout.addWidget(section_widget)
|
||||
if sections.index((title, url)) < len(sections) - 1:
|
||||
spacer = QSpacerItem(20, 6, QSizePolicy.Policy.Minimum, QSizePolicy.Policy.Fixed)
|
||||
about_layout.addItem(spacer)
|
||||
section_layout.addWidget(button, alignment=Qt.AlignmentFlag.AlignCenter)
|
||||
|
||||
footer_label = QLabel("v3.1 | gallery-dl v1.30.0 | July 2025")
|
||||
footer_label.setStyleSheet("font-size: 12px; margin-top: 10px;")
|
||||
about_layout.addWidget(section_widget)
|
||||
|
||||
footer_label = QLabel(f"v{self.current_version} | gallery-dl v1.30.1 | July 2025")
|
||||
footer_label.setStyleSheet("font-size: 12px; margin-top: 20px;")
|
||||
about_layout.addWidget(footer_label, alignment=Qt.AlignmentFlag.AlignCenter)
|
||||
|
||||
about_tab.setLayout(about_layout)
|
||||
self.tab_widget.addTab(about_tab, "About")
|
||||
|
||||
@@ -936,7 +908,7 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
self.twitter_url.setText(last_username_url)
|
||||
|
||||
except Exception as e:
|
||||
print(f"Error loading settings: {e}")
|
||||
pass
|
||||
|
||||
def handle_batch_checkbox(self, state):
|
||||
if not hasattr(self, 'size_label') or not hasattr(self, 'batch_size_combo'):
|
||||
@@ -1372,7 +1344,7 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
self.pending_downloads[url] = reply
|
||||
reply.finished.connect(lambda: self.on_profile_image_downloaded(reply, url))
|
||||
except Exception as e:
|
||||
print(f"Error downloading profile image: {e}")
|
||||
pass
|
||||
|
||||
def on_profile_image_downloaded(self, reply, image_url):
|
||||
try:
|
||||
@@ -1389,7 +1361,7 @@ class TwitterMediaDownloaderGUI(QWidget):
|
||||
del self.pending_downloads[image_url]
|
||||
|
||||
except Exception as e:
|
||||
print(f"Error processing profile image: {e}")
|
||||
pass
|
||||
finally:
|
||||
reply.deleteLater()
|
||||
|
||||
@@ -1707,6 +1679,7 @@ def main():
|
||||
os.chdir(os.path.dirname(sys.executable))
|
||||
|
||||
app = QApplication(sys.argv)
|
||||
app.setStyle('fusion')
|
||||
window = TwitterMediaDownloaderGUI()
|
||||
window.show()
|
||||
sys.exit(app.exec())
|
||||
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"version": "3.2"
|
||||
}
|
||||
+2
-1
@@ -3,4 +3,5 @@ requests
|
||||
aiohttp
|
||||
imageio-ffmpeg
|
||||
packaging
|
||||
gallery-dl
|
||||
gallery-dl
|
||||
pyqtdarktheme
|
||||
+1
-1
@@ -1,3 +1,3 @@
|
||||
{
|
||||
"version": "3.0"
|
||||
"version": "3.1"
|
||||
}
|
||||
Reference in new issue
Block a user