{"id":50399372,"url":"https://github.com/72sevenzy2/in-memory-database","last_synced_at":"2026-05-30T22:30:53.977Z","repository":{"id":355584138,"uuid":"1228702929","full_name":"72sevenzy2/in-memory-database","owner":"72sevenzy2","description":"k-v database built with go, stores key-values with serialization involved to ensure optimal performance.","archived":false,"fork":false,"pushed_at":"2026-05-30T10:09:07.000Z","size":61,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-05-30T11:23:28.106Z","etag":null,"topics":["cli-tool","go","golang","golang-cli","golang-database","golang-package","in-memory-database"],"latest_commit_sha":null,"homepage":"","language":"Go","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/72sevenzy2.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-05-04T09:34:47.000Z","updated_at":"2026-05-30T10:10:22.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/72sevenzy2/in-memory-database","commit_stats":null,"previous_names":["72sevenzy2/in-memory-database"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/72sevenzy2/in-memory-database","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/72sevenzy2%2Fin-memory-database","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/72sevenzy2%2Fin-memory-database/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/72sevenzy2%2Fin-memory-database/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/72sevenzy2%2Fin-memory-database/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/72sevenzy2","download_url":"https://codeload.github.com/72sevenzy2/in-memory-database/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/72sevenzy2%2Fin-memory-database/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33712579,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-05-30T02:00:06.278Z","response_time":92,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["cli-tool","go","golang","golang-cli","golang-database","golang-package","in-memory-database"],"created_at":"2026-05-30T22:30:52.764Z","updated_at":"2026-05-30T22:30:53.969Z","avatar_url":"https://github.com/72sevenzy2.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003e key-value style in-memory database. \u003c/h1\u003e\n\u003cbr\u003e\n\u003cul\u003e\n  \u003cli\u003epersistant error handling for edge cases.\u003c/li\u003e\n  \u003cli\u003einteractive cli mode, which stores variable-like data (for now only supports values of type string and int) to then be retrieved         later with methods like \"GET\", \"SET\", \"DEL\", and \"EXIT\" to exit the program.\u003c/li\u003e\n  \u003cli\u003eserializes values to bytes before appending to the database struct for optimised performance.\u003c/li\u003e\n\u003c/ul\u003e\n\n\u003ch1 align=\"center\"\u003eusage:\u003c/h1\u003e\n\u003ch3 align=\"center\"\u003eto start off, you can either set data using SetInt() for key-values with values having type int, or SetString() for key-values with values having type string:\u003c/h3\u003e\n\n```\npackage main\n\nimport (\n\t\"fmt\"\n\t\"github.com/72sevenzy2/in-memory-database/db\"\n)\n\nfunc main() {\n\tv := db.NewDB()\n\n\terr := v.SetInt(\"test1\", 200) // setting ints\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\n\terr2 := v.SetString(\"test2\", \"hello\") // setting strings\n\tif err2 != nil {\n\t\tpanic(err2)\n\t}\n}\n```\n\u003ch3 align=\"center\"\u003eafterwards, you may retrieve them like so:\u003c/h3\u003e\n\n```\npackage main\n\n\nimport (\n\t\"fmt\"\n\t\"github.com/72sevenzy2/in-memory-database/db\"\n)\n\nfunc main() {\n\tv := db.NewDB()\n\n\tval, ok := v.GetInt(\"test1\")\n\tif ok {\n\t\tfmt.Println(val)\n\t}\n\n\tval2, ok2 := v.GetString(\"test2\")\n\tif ok2 {\n\t\tfmt.Println(val2)\n\t}\n\t\n}\n```\n\n\u003ch3 align=\"center\"\u003eif you want to retrieve all key-values with values of type strings/ints:\u003c/h3\u003e\n\n```\npackage main\n\nimport (\n\t\"fmt\"\n\t\"github.com/72sevenzy2/in-memory-database/db\"\n)\n\nfunc main() {\n\tv := db.NewDB()\n\n\tvals, ok := v.GetAllString() // vals is of type map[string]string\n\tif ok {\n\t\tfor k, v := range vals {\n\t\t\tfmt.Println(k, v)\n\t\t}\n\t}\n\n\tvals2, ok2 := v.GetAllInt() // vals2 is of type map[string]uint32\n\tif ok2 {\n\t\tfor k, v := range vals2 {\n\t\t\tfmt.Println(k, v)\n\t\t}\n\t}\n\n}\n```\n\n\u003ch3 align=\"center\"\u003eand finally, to delete keys:\u003c/h3\u003e\n\n```\npackage main\n\nimport (\n\t\"fmt\"\n\t\"github.com/72sevenzy2/in-memory-database/db\"\n)\n\nfunc main() {\n\tv := db.NewDB()\n\n\tv.Del(\"keyName\")\n\n}\n\n```\n\n\u003cbr\u003e\n\u003ch1 align=\"center\"\u003einteractive cli tutorial:\u003c/h1\u003e\n\u003ch2 align=\"center\"\u003erun the following to begin:\u003c/h2\u003e\n\u003ch3 align=\"center\"\u003e\n  \u003ccode\u003e go run . \u003c/code\u003e\n\u003c/h3\u003e\n\u003ch2 align=\"center\"\u003eand follow up by declarin`g a variable:\u003c/h2\u003e\n\u003ch3 align=\"center\"\u003e\n  \u003ccode\u003e SET [KeyName] [Value] \u003c/code\u003e\n\u003c/h3\u003e\n\u003ch3 align=\"center\"\u003e(key names only support either integers or strings as of now).\u003c/h3\u003e\n\n\u003ch2 align=\"center\"\u003eafter setting a variable, you can then retrieve it like so:\u003c/h2\u003e\n\u003ch3 align=\"center\"\u003e\n  \u003ccode\u003e GET [KeyName] \u003c/code\u003e\n\u003c/h3\u003e\n\u003ch3 align=\"center\"\u003eand it returns the value of the key given.\u003c/h3\u003e\n\n\u003ch2 align=\"center\"\u003eto delete a variable/key:\u003c/h2\u003e\n\u003ch3 align=\"center\"\u003e\n  \u003ccode\u003e DEL [KeyName] \u003c/code\u003e\n\u003c/h3\u003e\n\n\u003ch2 align=\"center\"\u003efinally, to exit the program, run:\u003c/h2\u003e\n\u003ch3 align=\"center\"\u003e\n  \u003ccode\u003e EXIT \u003c/code\u003e\n\u003c/h3\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F72sevenzy2%2Fin-memory-database","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F72sevenzy2%2Fin-memory-database","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F72sevenzy2%2Fin-memory-database/lists"}