{"id":15138426,"url":"https://github.com/0x20f/bunny","last_synced_at":"2026-03-10T10:32:04.651Z","repository":{"id":62438641,"uuid":"280227438","full_name":"0x20F/bunny","owner":"0x20F","description":"Smart bookmarking tool. Fast and customizable shortcuts for your browser.","archived":false,"fork":false,"pushed_at":"2021-01-16T10:50:50.000Z","size":70,"stargazers_count":19,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-30T19:07:21.802Z","etag":null,"topics":["bookmarks","rocket-rs","rust","rust-lang","server","simple"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/0x20F.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-07-16T18:22:06.000Z","updated_at":"2024-11-04T19:02:48.000Z","dependencies_parsed_at":"2022-11-01T21:16:24.705Z","dependency_job_id":null,"html_url":"https://github.com/0x20F/bunny","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0x20F%2Fbunny","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0x20F%2Fbunny/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0x20F%2Fbunny/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/0x20F%2Fbunny/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/0x20F","download_url":"https://codeload.github.com/0x20F/bunny/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":237843753,"owners_count":19375198,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bookmarks","rocket-rs","rust","rust-lang","server","simple"],"created_at":"2024-09-26T07:23:50.973Z","updated_at":"2025-10-23T15:30:18.060Z","avatar_url":"https://github.com/0x20F.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003ebunny\u003c/h1\u003e\n\n\u003cp align=\"center\"\u003eSmart bookmarking tool, running custom commands to open urls from a browser url bar\u003c/p\u003e\n\n\n## What?\n\"Smart bookmarking\"? What? I had the same reaction. Imagine it as a very fast, and elegant (if you so wish) way of entering urls into your browser. Instead of writing `reddit.com/r/programmerhumor`, you could be writing `rd r programmerhumor` and be redirected to your entertainment of choice a lot easier.\n\nThis was inspired by the following [article by facebook](https://developers.facebook.com/blog/post/2020/06/03/build-smart-bookmarking-tool-rust-rocket/)\n\n\n## How to use\n* `cargo install bun` (this does require rust nightly for now)\n* Run the installed program `bun` \n* Create a custom search engine for your browser and point it towards the address the server is running on\n\nThe server looks for a file that contains all the bookmarks inside the home directory (`~/bookmarks.toml`)\n\n\n### Writing bookmarks (`bookmarks.toml`)\nThe engine is simple, it's all written in a `toml` format for readability\n\n* The bookmarks file is made of `books`, they can have any *name* you choose, an *alias*, and a *default* url:\n```rust\n[twitter]\nalias = \"tw\"\ndefault = \"https://twitter.com\"\n```\n\n* Each `book` in the file has `pages`. Each page has a *name*, a *prefix*, and a *url*:\n```rust\n[twitter]\nalias = \"tw\"\ndefault = \"https://twitter.com\"\n\n[twitter.pages]\nsearch = { prefix = \"NONE\", url = \"https://twitter.com/search?q={encoded}\" }\nprofile = { prefix = \"@\", url = \"https://twitter.com/{raw}\" }\n```\n\n* Each `url` can contain special keys that handle the data you pass to the command.\n\n### Keys\n\nConsider the following command: `tw rust lang`. Here are the keys and what they do with the given data. The `prefix` gets stripped away and we are left to handle `rust lang`\n  - `{default}` - will be replaced with the default url of the `book` =\u003e `https://twitter.com` \n  - `{encoded}` - will url encode the data =\u003e `rust%20lang`\n  - `{raw}`     - will pass in the raw data without encoding it =\u003e `rust lang`\n  - `{0}`       - will pass in the first *segment* of the data =\u003e `rust`\n  - `{1}`       - will pass in the second *segment* of the data =\u003e `lang`\n    * There are up to `4` total segments at the moment, because it felt like more were just too many. These can be used to create more customised commands, such as, a reddit command:\n    ```rust\n    [reddit]\n    alias = \"rd\"\n    default = \"https://reddit.com\"\n    \n    [reddit.pages]\n    whatever = { prefix = \"NONE\", url = \"https://reddit.com/{0}/{1} }\n    ```\n    * The above can be used as `rd r programmerhumor` to go to a subreddit or as `rd u programmerhumor` to go to a user \n    \n### Prefixes\n\nThe url prefix can be whatever you want it to be, it is used to differentiate between each command. You could have `-s` when searching for something, or full on `search` if shortcuts aren't your thing. \n\n**You dont even need spaces between the prefix and command**. \n\n`-sheyooo` will be split into `-s heyooo` if the prefix is defined as `-s`. \n\nThere's also one special prefix, `NONE`, which means the command will not expect a prefix, and encode the url with all the given data. \n\n\n\n### Full examples can be seen in the [example file](./example/bookmarks.example.toml)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F0x20f%2Fbunny","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F0x20f%2Fbunny","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F0x20f%2Fbunny/lists"}