{"id":49823893,"url":"https://github.com/andrewdongminyoo/merry","last_synced_at":"2026-05-13T14:05:00.542Z","repository":{"id":353611422,"uuid":"1198027359","full_name":"AndrewDongminYoo/merry","owner":"AndrewDongminYoo","description":"Dart용 스크립트 관리자. Merry는 플러터 프로젝트에서 단축키 스크립트를 정의하는 데 도움을 주며, 길고 기억하기 힘든 스크립트를 플랫폼별로 반복해서 입력해야 하는 번거로움을 덜어줍니다","archived":false,"fork":false,"pushed_at":"2026-04-24T16:09:33.000Z","size":7123,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-24T18:12:31.341Z","etag":null,"topics":["dart-script","derry","flutter","flutter-devtools","merry","script-management","script-manager"],"latest_commit_sha":null,"homepage":"https://pub.dev/packages/merry","language":"Dart","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/AndrewDongminYoo.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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":"AGENTS.md","dco":null,"cla":null}},"created_at":"2026-04-01T04:09:49.000Z","updated_at":"2026-04-24T16:09:33.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/AndrewDongminYoo/merry","commit_stats":null,"previous_names":["andrewdongminyoo/merry"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/AndrewDongminYoo/merry","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AndrewDongminYoo%2Fmerry","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AndrewDongminYoo%2Fmerry/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AndrewDongminYoo%2Fmerry/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AndrewDongminYoo%2Fmerry/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/AndrewDongminYoo","download_url":"https://codeload.github.com/AndrewDongminYoo/merry/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AndrewDongminYoo%2Fmerry/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32985796,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-13T13:14:54.681Z","status":"ssl_error","status_checked_at":"2026-05-13T13:14:51.610Z","response_time":115,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["dart-script","derry","flutter","flutter-devtools","merry","script-management","script-manager"],"created_at":"2026-05-13T14:04:57.679Z","updated_at":"2026-05-13T14:05:00.526Z","avatar_url":"https://github.com/AndrewDongminYoo.png","language":"Dart","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Merry\n\nMerry is a script manager for Dart.\n\n\u003e **Merry** is a maintained fork of [derry](https://pub.dev/packages/derry) by [Frenco](https://github.com/frencojobs).\n\u003e All script definitions are compatible — only the CLI command changes from `derry` to `merry`.\n\u003e See [Migrating from derry](#migrating-from-derry) below.\n\n## Overview\n\nMerry helps you define shortcut scripts, and save you from having to type very long and forgettable long lines of scripts, again and again.\n\nInstead of running this every time,\n\n```bash\ndart run build_runner build --delete-conflicting-outputs\n```\n\nAdd this to `pubspec.yaml`,\n\n```yaml\nscripts:\n  build: dart run build_runner build --delete-conflicting-outputs\n```\n\nand run\n\n```bash\nmerry build\n```\n\n\u003cbr\u003e\n\n## Fork, License, and Credits\n\nMerry is a maintained fork of [derry](https://pub.dev/packages/derry). This repository keeps the upstream MIT license and preserves the original `derry` copyright notice alongside Merry's own copyright notice in [LICENSE](LICENSE).\n\nThe script definition format stays compatible with `derry`, while ongoing development in this fork continues under the `merry` CLI name. Changes added in Merry include:\n\n- command-group defaults with `(default)`\n- positional argument placeholders such as `$1`, `$2`, and so on\n- per-script working directories with `(workdir)`\n- platform-specific keys such as `(linux)`, `(macos)`, and `(windows)`\n- command aliases via `(aliases)`\n- variable substitution with `${VAR}`\n- JSON output for `merry ls` via `--output=json`\n\n## Acknowledgements\n\nThis project is based on `derry`, originally created by Frenco Jobs. Thanks to Frenco Jobs and the upstream `derry` contributors whose work continues in this fork. Contributors visible in the preserved project history include Phoe Lapyae, Britannio Jarrett, and lynnphayu.\n\n\u003cbr\u003e\n\n## Installation\n\nInstall merry as a global dependency from [pub.dev](https://pub.dev) like this.\n\n```bash\ndart pub global activate merry\n```\n\nThen use merry to run a command from the current dart/flutter project.\n\n```bash\nmerry [script]\n```\n\n\u003cbr\u003e\n\n## Usage\n\nWhen called, merry will look for a `pubspec.yaml` file in the current directory, and will throw an error if it doesn't exist. The scripts can be declared within the `scripts` node of the `pubspec.yaml` file.\n\n```yaml\nscripts:\n  build: dart run build_runner build\n```\n\n```bash\nmerry build\n# or even with additional arguments\nmerry build -- --delete-conflicting-outputs\n```\n\n\u003cbr\u003e\n\n## API Documentation\n\n**Use definition file**\n\nScripts can be configured just inside the `pubspec.yaml` file or within a separate file. When using a separate file to configure scripts, pass the file name as the value of the `scripts` node in the `pubspec.yaml` file.\n\n```yaml\n# pubspec.yaml\nscripts: merry.yaml\n```\n\n```yaml\n# merry.yaml\nbuild: dart run build_runner build\n```\n\n**Use scripts as List**\n\nA script can either be a single string or a list of strings. If it is a list, the strings inside of the list will be executed synchronously in the given order of the list.\n\n```yaml\nbuild:\n  - dart test\n  - echo \"test completed\"\n  - dart run build_runner build\n```\n\n**Nested scripts**\n\nScripts can be nested as the user needed. For example, you can use them to use different implementations of the build script based on operating system.\n\n```yaml\nbuild:\n  windows:\n    - echo 0 # do something\n  mac:\n    - echo 1 # do something else\n```\n\nAnd you can use them by calling `merry build windows` on windows and `merry build mac` on macOS.\n\n**Pre and post scripts**\n\nWith pre \u0026 post scripts, you can easily define a script to run before and after a specific script without hassling with references. Merry automatically understands them from the names.\n\n```yaml\nprepublish:\n  - cargo build \u0026\u0026 copy target blob\n  - dart test\npublish:\n  - dart pub publish\npostpublish:\n  - rm -rf blob\n```\n\n**Configure script descriptions**\n\nYou can add a string to `(description)` option, which can be useful when viewing through a list of available via `merry ls -d` command. When you are using `(description)` field, you must use `(script)` field to define scripts.\n\n```yaml\nbuild:\n  (description): script to be called after every update to x.dart file\n  (scripts):\n    - cat generated.txt\n    - dart run build_runner build\n```\n\n**Configure multiline scripts**\n\nNote that in the list of scripts, executions will happen in separate processes. You can use `\u0026\u0026` to execute multiple scripts in the same process.\n\n```yaml\n# \u003e or | can be used to define multiline strings, this is a standard YAML syntax\nbuild: \u003e\n  cat generated.txt \u0026\u0026\n  dart run build_runner build\n\n# the second line won't be called if generated.txt does not exist\n```\n\n**Use references**\n\nWhen defining scripts, you can reference to other scripts via `$` syntax. These references to scripts won't be executed with a separate merry process. For example,\n\n```yaml\ntest:\n  - dart run test\n  - echo \"test completed\"\nbuild:\n  - $test # instead of using merry test\n  - $test --ignored # even with arguments\n  - flutter build\ngenerate:\n  env:\n    - echo env\nrelease:\n  - $generate:env # use nested references via :\n  - $build\n```\n\n`merry test` will spawn a new merry process to execute, while references won't, reducing the time took to run dart code, and spawn that process.\nBut note that references will take a whole line of script. For example, you have to give a separate line for a subcommand, you can't use them together with other scripts or sandwiched in a string.\n\n**Platform-specific scripts**\n\nUse `(linux)`, `(macos)`, or `(windows)` keys to define platform-dependent scripts. The correct one is selected automatically at runtime; `(scripts)` is used as a fallback when no key matches the current OS.\n\n```yaml\nopen:\n  (linux): xdg-open .\n  (macos): open .\n  (windows): explorer .\n```\n\n**Default script for a command group**\n\nWhen a command group is called without a sub-command, the `(default)` script is executed.\n\n```yaml\nbuild:\n  (default): flutter build apk\n  web: flutter build web\n```\n\n```bash\nmerry build      # runs flutter build apk\nmerry build web  # runs flutter build web\n```\n\n**Positional arguments**\n\nUse `$1`, `$2`, etc. to inject individual arguments from the command line into a script. Remaining arguments not consumed by positional tokens are appended at the end.\n\n```yaml\ngreet: echo Hello $1\nrun: dart run $1 $2\n```\n\n```bash\nmerry greet World   # → echo Hello World\nmerry run bin/main  # → dart run bin/main\n```\n\n**Working directory**\n\nUse `(workdir)` to run a script inside a specific directory. The path is relative to the project root.\n\n```yaml\nnative:\n  (workdir): packages/native\n  (scripts): cargo build --release\n```\n\n**Command aliases**\n\nUse `(aliases)` to define short aliases for a command. Aliases can be a single string or a list of strings.\n\n```yaml\ninstall:\n  (aliases): [i, in]\n  (scripts): dart pub get\n```\n\n```bash\nmerry i   # → merry install\nmerry in  # → merry install\n```\n\n**Variable substitution**\n\nDefine reusable variables in a `(variables)` section at the top level or inside any command group. Reference them with `${VAR}` syntax in scripts. Environment variables are used as a fallback for undefined names.\n\n```yaml\n(variables):\n  OUTPUT: build/release\n  MODE: release\n\nbundle: flutter build apk --output ${OUTPUT} --${MODE}\n```\n\n**JSON output for tooling integration**\n\nUse `--output=json` (or `-o json`) to emit a machine-readable JSON payload — useful for VS Code extensions, shell scripts, or any tool that needs to enumerate available scripts programmatically.\n\n```bash\nmerry ls --output=json\n```\n\n```json\n{\n  \"name\": \"my_app\",\n  \"version\": \"1.0.0\",\n  \"scripts\": [\n    {\n      \"path\": \"build\",\n      \"commands\": [\"dart run build_runner build\"],\n      \"description\": \"Regenerate all generated files\"\n    },\n    {\n      \"path\": \"native build\",\n      \"commands\": [\"cargo build --release\"],\n      \"workdir\": \"packages/native\"\n    }\n  ]\n}\n```\n\n```bash\nmerry ls --output=tree  # human-readable tree (default)\nmerry ls -o json        # machine-readable JSON\n```\n\n**List available scripts**\n\nUse this command to see what scripts are available in the current configuration.\n\n```bash\nmerry ls # --description or -d to output descriptions\n```\n\n**Check the location of the merry scripts**\n\nUse this command to see the location (both absolute and relative) path of the merry script file. You can also use this to check if the scripts are correctly formatted or the location is correct.\n\n```bash\nmerry source # --absolute or -a to show absolute path\n```\n\n**Upgrade merry**\n\n```bash\ndart pub global activate merry # or\nmerry upgrade # will run `dart pub global activate merry`\n```\n\n\u003cbr\u003e\n\n## Migrating from derry\n\n1. Deactivate derry and install merry:\n   ```bash\n   dart pub global deactivate derry\n   dart pub global activate merry\n   ```\n2. Replace all `derry` invocations with `merry`\n3. Optionally rename `derry.yaml` → `merry.yaml` and update the `scripts:` value in `pubspec.yaml`\n4. No changes to script definitions are required — the format is fully compatible\n\n\u003cbr\u003e\n\n## Why \u0026 How\n\nHonestly, I needed it. It was easy to make, though I had a hard time implementing the script execution. Since Dart's `Process` isn't good at executing system commands, I used Rust with the help of _Foreign Function Interfaces_. For execution, currently `cmd` is used for Windows and `bash` is used for Linux and Mac.\n\n\u003cbr\u003e\n\n## Currently Supported Platforms\n\n64bit Linux, Windows, and Mac are currently supported.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandrewdongminyoo%2Fmerry","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fandrewdongminyoo%2Fmerry","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fandrewdongminyoo%2Fmerry/lists"}