{"id":30389261,"url":"https://github.com/marcos-venicius/evalset","last_synced_at":"2026-05-16T00:34:51.803Z","repository":{"id":299252460,"uuid":"910213803","full_name":"marcos-venicius/evalset","owner":"marcos-venicius","description":"The JSON successor?","archived":false,"fork":false,"pushed_at":"2025-07-19T11:23:11.000Z","size":165,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-07-19T16:10:06.097Z","etag":null,"topics":["ast","clang","dsl","evalset","json","language","toml"],"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/marcos-venicius.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,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-12-30T17:52:19.000Z","updated_at":"2025-06-15T15:46:54.000Z","dependencies_parsed_at":"2025-06-15T16:19:24.687Z","dependency_job_id":"7601ce83-2587-4d2e-9400-faaadf920c00","html_url":"https://github.com/marcos-venicius/evalset","commit_stats":null,"previous_names":["marcos-venicius/evalset"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/marcos-venicius/evalset","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marcos-venicius%2Fevalset","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marcos-venicius%2Fevalset/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marcos-venicius%2Fevalset/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marcos-venicius%2Fevalset/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/marcos-venicius","download_url":"https://codeload.github.com/marcos-venicius/evalset/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marcos-venicius%2Fevalset/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271448405,"owners_count":24761441,"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","status":"online","status_checked_at":"2025-08-21T02:00:08.990Z","response_time":74,"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":["ast","clang","dsl","evalset","json","language","toml"],"created_at":"2025-08-21T08:18:48.077Z","updated_at":"2026-05-16T00:34:51.731Z","avatar_url":"https://github.com/marcos-venicius.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# EVALSET\n\nThe JSON sucessor?\n\n\u003cimg width=\"1920\" height=\"1080\" alt=\"image\" src=\"https://github.com/user-attachments/assets/c05c3c0f-43e5-432f-b193-bd6c16ce049a\" /\u003e\n\n## The idea\n\nThis is a simple example of the `evalset` syntax: \n\n```console\nroot = {\n    # this is the base url for the app\n    base_url = \"http://localhost:3030\"\n    app_name = \"testing some stuff\" # this is the name of my app\n    id = 129\n    other = 129.19\n\n    route_names = {\n        home = \"Home\"\n        dashboard = \"Dashboard\"\n    }\n}\n\nroutes = [\n    {\n        id = mul($/root/id, 2)\n        path = concat($/root/base_url, \"/\")\n        name = $/root/route_names/home\n    }\n    {\n        id = mul($/root/id, 3)\n        path = concat($/root/base_url, \"/dashboard\")\n        name = $/root/route_names/dashboard\n    }\n]\n\n# Commas are entirely optional\ndependencies = {\n  test = \"hello\"\n  outro = \"now\"\n  number = 10\n  floats = 3.1415,\n  this_is_true = true,\n  this_is_false = false\n  this_is_nil = nil\n  array = [\n    \"hello world\"\n    [\n      10, 20\n    ]\n    {\n      \"this is a valid key\" = \"my very secret jwt token\",\n      my_lucy_number = 10\n      child = {\n        intern_node = \"Hello Guys\"\n      }\n    }\n  ]\n}\n\nlist = [\"hello\", 4239]\n```\n\nAnd, as you can see, evalset also suport \"string named variables\" with the following syntax:\n\n```toml\n\"@angular/version\" = \"18.9.0\"\n```\n\nThe idea behind the project is to learn more about C, compilers, interpreters, etc.\n\nThe purpose of this language is to allow the user to create a configuration file like json but with some incremental features.\n\nOne of the features **Evaluation**, where the user can do math of string operations.\nAnother feature is **Variables**, you can define top level variables and reference them later.\nIn the end of the day, when the user try to get a value from a property, the property will be evaluated and returned the result to the user.\n\nOne of the thougts is to have a possibility to convert the `evalset` to json format, by evaluating all the fields and creating a valid json file. \n\n\u003e [!NOTE]\n\u003e Probably it'll be lazy evaluated to avoid big files being slow to load, it should be optional to the user api.\n\n\u003e [!NOTE]\n\u003e Comma to separate elements inside arrays, objects and function arguments are entirely optional\n\n## Data types\n\n- String (\"....\")\n- Integer (c int)\n- Float (c doubles)\n- Nullables (nil)\n- Boolean (true | false)\n- Array\n- Object\n- Paths ($/[a-zA-Z_])\n\n## To implement\n\nI think the API to this language in C should work in a very special way.\n\nSo, we'll have a function, maybe called `evalset_get` which returns a \"generic type\".\n\nBasically this will return the primitive types already evaluated like: int, nil, array, object, etc.\n\nSo, this function will expect an instance of the evalset and a string as second parameter.\n\nThe second parameter should basically accept an evalset syntax, which you will be able to reference variables, get indexes call builtin functions and all of it.\n\nBut, it'll not have the possibility to create variables, only to do some work upon all of them.\n\nIf you look carefully to the code, the file itself is an object of many keys, so you will be able to iterate over this keys refering to it as `$/root`, then inside `$/root` you'll have\naccess to all other variables and do syntax like `$/root[\"permissions\"][sub_i(len($/root[\"permissions\"]), 1)]` and all kind of available syntax.\n\n\u003e [!WARNING]\n\u003e This is not the final thought about how it'll be implemented, it's just one of many ideas. But, to be honest, I like this one\n\n## Internal functions\n\n- [x] `sum`\n    - [x] `integer sum(integer, N...)`\n    - [x] `float sum(float, N...)`\n    - [x] `integer sum([]integer)`\n    - [x] `float sum([](float \u0026 integer))`\n- [x] `join`\n    - [x] `string join([]string, string?)`\n    - [x] `[]any join([]any, []any, N...)`\n    - [x] `string join(string, string, N...)`\n- [x] `[]string keys(object)`\n- [x] `integer len([]any|string)`\n- [x] `integer iota()`, returns an integer which auto-increment every time it's called\n\nI still have some internal functions in my, but for now, I'll leave only these ones.\nI'm thinking about the best way to implement this yet.\n\n**Another important point, is to have a special function to allow the user to debug, some kind of print**\n**But today we cannot parse a function without associating it to a variable**\n\n## The name\n\nThe name _evalset_ is due to the language properties you \"set vars and evaluate the\" so, _evalset_ (believe it or not).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmarcos-venicius%2Fevalset","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmarcos-venicius%2Fevalset","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmarcos-venicius%2Fevalset/lists"}