{"id":13782921,"url":"https://github.com/shiroyasha/lisp","last_synced_at":"2025-03-28T00:47:31.018Z","repository":{"id":147856571,"uuid":"72866189","full_name":"shiroyasha/lisp","owner":"shiroyasha","description":"Toy lisp interpreter written in C","archived":false,"fork":false,"pushed_at":"2016-11-13T03:24:06.000Z","size":308,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-02-02T02:45:10.454Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/shiroyasha.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2016-11-04T16:37:24.000Z","updated_at":"2016-11-07T13:57:46.000Z","dependencies_parsed_at":"2023-04-20T00:07:02.153Z","dependency_job_id":null,"html_url":"https://github.com/shiroyasha/lisp","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/shiroyasha%2Flisp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shiroyasha%2Flisp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shiroyasha%2Flisp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shiroyasha%2Flisp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/shiroyasha","download_url":"https://codeload.github.com/shiroyasha/lisp/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245949601,"owners_count":20698922,"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-08-03T18:01:48.085Z","updated_at":"2025-03-28T00:47:30.997Z","avatar_url":"https://github.com/shiroyasha.png","language":"C","funding_links":[],"categories":["C"],"sub_categories":[],"readme":"# Lisp\n\nFollowing the tutorial from [Build Your Own Lisp](http://www.buildyourownlisp.com/).\n\n## Building from source\n\nInstall dependencies:\n\n``` bash\nsudo apt-get install libedit-dev\n```\n\nClone the source code:\n\n``` bash\ngit clone https://github.com/shiroyasha/lispy ~/lispy\n```\n\nBuild binary:\n\n``` bash\ncd ~/lispy\nmake\n```\n\nRun lispy:\n\n``` bash\ncd ~/lispy\n./lispy\n```\n\n## Examples\n\nArithmetic:\n\n``` lisp\n\u003e + 1 2\n3\n\n\u003e * 1 2\n2\n\n\u003e * (+ 1 2) (- 10 8)\n6\n```\n\nLists:\n\n``` lisp\n\u003e { 1 2 3 }\n{1 2 3}\n\n\u003e head {1 2 3}\n1\n\n\u003e tail {1 2 3}\n{2 3}\n\n\u003e join {1 2 3} {5 6 7}\n{1 2 3 5 6 7}\n\n\u003e eval {+ 1 2}\n3\n```\n\nVariables:\n\n``` lisp\n\u003e def {a b c d} 1 90 20 87\n()\n\n\u003e a\n1\n\n\u003e (+ b c)\n110\n```\n\nFunctions:\n\n``` lisp\n\u003e fun {add-together a b} {+ a b}\n()\n\n\u003e add-together 32 18\n50\n```\n\nMacros (fun fact: 'fun' is actually a macro defined in the language):\n\n``` lisp\n\u003e def {fun} (\\ {args body} {def (list (head args)) (\\ (tail args) body)})\n()\n\n\u003e fun {my-function a b c} {* a b c}\n()\n\n\u003e my-function 1 2 3\n6\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshiroyasha%2Flisp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshiroyasha%2Flisp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshiroyasha%2Flisp/lists"}