{"id":21731779,"url":"https://github.com/evref-bl/smaccdart","last_synced_at":"2026-05-20T10:35:43.746Z","repository":{"id":91712920,"uuid":"597070978","full_name":"Evref-BL/SmaccDart","owner":"Evref-BL","description":"A Smacc Parser for Dart ","archived":false,"fork":false,"pushed_at":"2023-09-08T09:58:50.000Z","size":1274,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-01-25T20:26:38.137Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Smalltalk","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/Evref-BL.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}},"created_at":"2023-02-03T15:07:54.000Z","updated_at":"2023-02-03T15:09:32.000Z","dependencies_parsed_at":"2024-11-26T04:38:40.451Z","dependency_job_id":null,"html_url":"https://github.com/Evref-BL/SmaccDart","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/Evref-BL%2FSmaccDart","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Evref-BL%2FSmaccDart/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Evref-BL%2FSmaccDart/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Evref-BL%2FSmaccDart/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Evref-BL","download_url":"https://codeload.github.com/Evref-BL/SmaccDart/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244711938,"owners_count":20497417,"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-11-26T04:27:22.389Z","updated_at":"2026-05-20T10:35:38.708Z","avatar_url":"https://github.com/Evref-BL.png","language":"Smalltalk","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SmaCC Dart\n\nThis is a dart parser made in Pharo.\n\n## Installation\n\nTo install it, first create a [BLMoose image](https://gitlab.forge.berger-levrault.com/bl-drit/bl-moose/bl-moose).\n\nThen, in a playground perform:\n\n```st\nMetacello new\n  githubUser: 'Evref-BL' project: 'SmaccDart' commitish: 'main' path: 'src';\n  baseline: 'SmaccDart';\n  onConflict: [ :ex | ex useIncoming ];\n  onUpgrade: [ :ex | ex useIncoming ];\n  onDowngrade: [ :ex | ex useLoaded ];\n  load\n  \n```\n\n## Usage\n\nTo parse a string: \n\n```st\nDartParser parse:  'class A {\n  final int myInt;\n  final String myString;\n}'\n```\n\nFrom a file\n\n```st\nDartParser parseFile:  'path/to/the/file.dart'\n```\n\n## Example of parsing dependencies of Dart file \n\nWith the project [dart-dep-resolver](https://github.com/Evref-BL/dart-dep-resolver), we use the parser to look for dependencies between dart file (using import declaration) and create a Mermaid diagram of these dependencies. \nThe following is an example created from the template of the helloWorld app in Flutter.\n```mermaid\nflowchart\n    widget_test.dart --\u003e main.dart\n    main.dart --\u003e material.dart\n    widget_test.dart --\u003e material.dart\n    widget_test.dart --\u003e flutter_test.dart\n```\n\n\n## Developer\n\nYou will find the grammar used for the parser in the file `grammar/dart.g`.\nTo reimport it, use:\n\n```st\ndefinition := ('path\\to\\grammar\\dart.g' asFileReference contents).\ngrammarCompiler := SmaCCGrammarCompiler new.\ngrammarCompiler codeGenerator defaultCategory: 'SmaCC_Dart'.\ngrammarCompiler\n\tbuildDefinition: definition;\n\tcompileInto: 'DartScanner' andParser: 'DartParser'.\n```\n\nYou can modify the dart.g file to improve the parser.\n\n\u003e Each time you modify the .g file, remember to regenerate before commiting\n\n## SmaCC documentation\n\nPlease refer to the [official book](http://books.pharo.org/booklet-Smacc/html/Chapters/Smacc/SmaccDirectives.html) of SmaCC (or its [archived version](https://web.archive.org/web/20210925202114/http://books.pharo.org/booklet-Smacc/html/Chapters/Smacc/SmaccDirectives.html)).\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fevref-bl%2Fsmaccdart","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fevref-bl%2Fsmaccdart","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fevref-bl%2Fsmaccdart/lists"}