termux / termux/termux-api-package

Setting event handlers to termux-download

Open
#119 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Shell
Stars
1.7k
Forks
523
PR merge metrics
No merged PRs in 30d

Description

Feature description
Pooling the FS is not the best way to wait for a file or discover when the download fails.

Would be nice if termux-download had a --onerror and --onsuccess parameters to set a command to run on background, like --action from termux-notification.

Background information
Have you checked if the feature is accessible through the android API?
I believe this means yes.

Do you know of other open-source apps that has a similar feature as the one you want? (Provide links)
Node.js's standard HTTP client and other unblocking implementations.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the termux-download entry point and review the Android DownloadManager completion and failure API described in the issue. Define how --onerror and --onsuccess should accept commands and run them in the background, then verify both outcomes and the existing download behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, shell
Domain
cli, mobile
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.