Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,18 @@ hamalert-cli edit
# Saves changes back to HamAlert
```

### set-callsigns

Replace the callsign list of an existing trigger with the contents of a file (one callsign per line, `#` comments allowed). Only `conditions.callsign` changes; every other condition, action, comment and option is kept, and the trigger is updated in place:

```bash
hamalert-cli set-callsigns --trigger-id <id> --file callsigns.txt # Dry run: shows added/removed
hamalert-cli set-callsigns --trigger-id <id> --file callsigns.txt --no-dry-run # Apply
hamalert-cli set-callsigns --comment "SOTA spots" --file callsigns.txt # Select by exact comment
```

Trigger IDs (`_id`) are listed in `backup` output. As a safeguard, the update is refused if the file is empty or if more callsigns would be removed than `--max-removals` (default: 10% of the current list, minimum 5).

### bulk-delete

Interactively delete multiple triggers with a TUI multi-select interface:
Expand Down
9 changes: 9 additions & 0 deletions skills/hamalert-cli/references/commands.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,15 @@ hamalert-cli edit

Fetches triggers, asks the user to choose one, opens editable JSON in `$EDITOR` or `vi`, validates JSON, and updates the live trigger if changed.

## set-callsigns

```bash
hamalert-cli set-callsigns --trigger-id <id> --file callsigns.txt
hamalert-cli set-callsigns --comment "<exact comment>" --file callsigns.txt --no-dry-run
```

Replaces the callsign list of one existing trigger with the file's contents (one callsign per line, `#` comments allowed), updating it in place. Only `conditions.callsign` changes, written back in its original string or array form; other conditions, actions, comment, and options are kept. Dry-run by default, printing added and removed callsigns. Refuses an empty file, or more removals than `--max-removals` (default: 10% of the current list, minimum 5). After saving, it re-fetches the trigger and errors if the saved list does not match. Trigger IDs (`_id`) appear in `backup` output.

## bulk-delete

```bash
Expand Down
2 changes: 2 additions & 0 deletions skills/hamalert-cli/references/safety.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ hamalert-cli restore --input <file>
hamalert-cli import-file --file <file> ... --dry-run
hamalert-cli import-polo-notes --url <url> ... --dry-run
hamalert-cli bulk-delete --dry-run
hamalert-cli set-callsigns --trigger-id <id> --file <file>
hamalert-cli profile list
hamalert-cli profile show <name>
hamalert-cli profile status
Expand All @@ -43,6 +44,7 @@ hamalert-cli import-polo-notes ... # without --dry-run
hamalert-cli restore --input <file> --no-dry-run
hamalert-cli edit
hamalert-cli bulk-delete # without --dry-run
hamalert-cli set-callsigns ... --no-dry-run
hamalert-cli profile switch <name> --no-dry-run
```

Expand Down
15 changes: 15 additions & 0 deletions skills/hamalert-cli/references/workflows.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,21 @@ Execute after approval:
hamalert-cli import-file --file callsigns.txt --comment "Local imports" --actions app
```

## Replace a Trigger's Callsign List

Find the trigger ID in a backup, then preview the diff:

```bash
hamalert-cli backup
hamalert-cli set-callsigns --trigger-id <id> --file callsigns.txt
```

Execute after approval. If the removal limit refuses the update, review the removed callsigns with the user before passing `--max-removals`:

```bash
hamalert-cli set-callsigns --trigger-id <id> --file callsigns.txt --no-dry-run
```

## Import Ham2K PoLo Notes

Preview:
Expand Down
Loading