Appendix C: Exit Codes
hande always prints a plain-English explanation alongside any error — these codes are for scripting against hande’s exit status, not something you need to memorize day to day. Every code below is what $? holds after hande exits with that particular problem.
| Code | What it means |
|---|---|
| 1 | An internal file target for :edit couldn’t be resolved — shouldn’t occur in normal use. |
| 3 | An internal request for data hande doesn’t recognize — shouldn’t occur in normal use. |
| 10 | The handler program named on a bookmark (or the default one hande inferred) isn’t on your $PATH. |
| 11 | A reference (Appendix B) doesn’t resolve to a real bookmark in the category it points to. |
| 12 | A reference illegally targets a command bookmark, or a command bookmark illegally contains a reference. |
| 13 | A reference’s target couldn’t be validated. |
| 19 | A bookmark or category entry is malformed in some way: an illegal character, unclosed brackets or braces, an empty required field, embedded spaces where they aren’t allowed, or a name that’s too short. The accompanying message always names the specific problem. |
| 20 | Two bookmarks (or two categories) share the same name where they shouldn’t. |
| 21 | The category named for a delete or rename operation doesn’t exist. |
| 22 | Your default category’s own file is missing, and create-missing-category is off (see Chapter 7). |
| 24 | The category named for editing doesn’t exist. |
| 25 | You tried to create a category that already exists. |
| 26 | A named category’s file couldn’t be found. |
| 27 | A category name contains a space or a period, neither of which is allowed in a category’s own name. |
| 28 | You set the same category in two different ways at once (e.g. both --category and a qualified name), or used a period inside an @ shortcut chain (see Chapter 1). |
| 30 | A bookmark’s file type has no handler configured for it, on the bookmark itself or in [[formats]] (see Chapter 7). |
| 31 | A bookmark reference has an unnecessary period in it. |
| 32 | An unrecognized symbol or search-service name was used. |
| 34 | An alias/tag lookup (/, Chapter 1) found nothing, or a named search-service bookmark doesn’t exist. |
| 35 | The shortcut key you typed isn’t assigned to any bookmark in scope. |
| 36 | No categories at all were found in the database — shouldn’t occur, since a fresh install always creates a default one. |
| 37 | A character in an @ shortcut chain (Chapter 1) isn’t assigned to any category or subcategory. |
| 38 | No record exists yet of your last-visited bookmark (used by the --summary/-0 flag). |
| 40 | The bookmark named for deletion couldn’t be found. |
| 49 | You tried to combine a search phrase with an explicit --category — searches are always global. |
| 52 | The = (www) link shortcut was used somewhere other than a bookmark or category address. |
| 55 | A reference chain went three levels deep — only two are allowed, to keep references from looping. |
| 58 | An exclamation mark was used somewhere it doesn’t belong inside a link shortcut. |
| 60 | You tried to use one of hande’s own reserved names ($home$, $search$, $help$, $manual$) as an ordinary bookmark’s name. |
| 65 | You asked hande to use a bookmark as a search engine, but it isn’t flagged for search (Chapter 5). |
| 70 | An import or export operation failed; the accompanying message explains why. |