Skip to content

Latest commit

Β 

History

History
96 lines (62 loc) Β· 2.31 KB

File metadata and controls

96 lines (62 loc) Β· 2.31 KB

dlm_rust (Download Manager)

A TUI-based asynchronous Download Manager that leverages the power of IPC.
Built with ratatui for the terminal interface and tokio-console for async task monitoring.


πŸ“ NOTE

Currently only supports UNIX systems due to the use of Unix Domain Socket for IPC.
Windows support via named_pipe is planned. (Work In Progress).
Uncomment this console_subscriber::init(); on server/src/main.rs to use tokio-console.

  • backend directory: Contains core downloading logic (pausing/resuming via thread locking).
  • View directory: Handles the TUI interface.

✨ Features

  • πŸ–₯️ Intuitive Terminal User Interface (ratatui)
  • πŸ” Async task debugging with tokio-console
  • ⚑ Concurrent multi-link downloads
  • ⏸️ Pause/Resume functionality
  • πŸ“‹ Download listing
  • ⏲ Retry upto 2 times if downloading fails.

🚧 TODO

  • Windows support via named_pipe
  • Error handling

πŸ› οΈ Run

Clone & Navigate

git clone <repo-link>
cd dlm_rust

🐳 Docker Execution (Recommended)

Run the application using Docker Compose with a single command:

docker compose run --rm --build client

Note:

  • This automatically builds the images, starts dlm_server in the background, waits for the socket to be ready, and launches the interactive dlm_client TUI.
  • All downloaded files are automatically synced to the ./downloads/ folder on your host machine.
  • Press Esc inside the TUI to exit.

To run the server as a persistent background daemon:

# Start server in background
docker compose up -d server

# Attach client TUI anytime
docker compose run --rm client

πŸ’» Manual Execution (Native)

1) Run server first

cargo run --bin dlm_server

2) Run client (TUI)

cargo run --bin dlm_client

Example

"example"

multi_download

"example2

Test Links: Link1 (10MB): https://samplefile.com/samples/download/audio/mp3/mp3_sample_file_10MB.mp3/?utm_source=samplefile&utm_medium=format_page&utm_campaign=file_download

Link2 (1MB): https://samplefile.com/samples/download/audio/mp3/mp3_60s_sample_file_939KB.mp3/?utm_source=samplefile&utm_medium=format_page&utm_campaign=file_download