{"id":15648108,"url":"https://github.com/noracodes/rfortune","last_synced_at":"2025-04-30T14:41:16.104Z","repository":{"id":84925778,"uuid":"77965576","full_name":"NoraCodes/rfortune","owner":"NoraCodes","description":"A Rust quotation webapp built using Rocket","archived":false,"fork":false,"pushed_at":"2023-06-07T21:17:18.000Z","size":132,"stargazers_count":9,"open_issues_count":1,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-30T17:04:37.067Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/NoraCodes.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-01-04T00:38:49.000Z","updated_at":"2023-06-06T14:24:49.000Z","dependencies_parsed_at":null,"dependency_job_id":"936ee889-d1c9-4d58-8f70-79456aa66000","html_url":"https://github.com/NoraCodes/rfortune","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NoraCodes%2Frfortune","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NoraCodes%2Frfortune/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NoraCodes%2Frfortune/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NoraCodes%2Frfortune/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/NoraCodes","download_url":"https://codeload.github.com/NoraCodes/rfortune/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251722804,"owners_count":21633018,"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":[],"created_at":"2024-10-03T12:23:34.306Z","updated_at":"2025-04-30T14:41:16.079Z","avatar_url":"https://github.com/NoraCodes.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# rfortune\nA simple Rust `fortune`-like webapp with Rocket\n\n![A screenshot of rfortune in action](screenshot.png)\n\n## What\nThis simple webapp reads quotes from a SQLite database and picks a random one to return\nwith each request. It uses templates for HTML responses and `serde` for JSON.\nIt provides a proof of concept for my use of Rocket.\n\nWhat this application demonstrates:\n- [x] Database with `rusqlite`\n- [x] Templates with `tera`\n- [x] JSON API with `serde` and the `rocket_contrib` JSON support\n- [x] Integrated command line management\n- [x] Form data entry\n- [x] Responsive, mobile-first design\n- [x] Custom error pages\n- [x] Rust 2018 compliance\n- [ ] Rocket tests\n\n## Why\nI like Rocket, as a concept. It allows me to use Rust, a language that tends to\nproduce code which is both fast and correct, as a backend for services which\ntypically need to be both fast and correct - web services.\n\nRocket also works with paradigms I'm familiar with: pluggable datastore and\ntemplate modules connected by route functions, like Flask.\n\n## How\nTo run the application, simply clone the repo and, assuming that you have\na nightly Rust toolchain installed, as well as `libsqlite3-dev`, run\n`cargo run` in the root directory - you'll get a webserver running!\n\nYou'll need to add quotes using either `cargo run add dev.db \u003cquote\u003e \u003cauthor\u003e [source]`\nor the JSON API.\n\n## License\nThis software is subject to the terms of the GNU Affero General Public License v3.0.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnoracodes%2Frfortune","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnoracodes%2Frfortune","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnoracodes%2Frfortune/lists"}