{"id":19056381,"url":"https://github.com/lamnhan066/dmg","last_synced_at":"2025-09-07T07:31:23.447Z","repository":{"id":190233545,"uuid":"682242972","full_name":"lamnhan066/dmg","owner":"lamnhan066","description":"A Flutter package helps you to create, sign, notarize and staple a .dmg installer for Flutter projects.","archived":false,"fork":false,"pushed_at":"2025-08-01T01:08:58.000Z","size":47,"stargazers_count":5,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-08-01T03:19:39.708Z","etag":null,"topics":["dmg","flutter","macos","notarize","package","plugin","staple"],"latest_commit_sha":null,"homepage":"https://pub.dev/packages/dmg","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/lamnhan066.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}},"created_at":"2023-08-23T18:47:23.000Z","updated_at":"2025-08-01T01:09:02.000Z","dependencies_parsed_at":null,"dependency_job_id":"6d9b013c-2095-4878-b737-9fcc99e4c125","html_url":"https://github.com/lamnhan066/dmg","commit_stats":null,"previous_names":["vnniz/dmg","lamnhan066/dmg"],"tags_count":12,"template":false,"template_full_name":null,"purl":"pkg:github/lamnhan066/dmg","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lamnhan066%2Fdmg","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lamnhan066%2Fdmg/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lamnhan066%2Fdmg/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lamnhan066%2Fdmg/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lamnhan066","download_url":"https://codeload.github.com/lamnhan066/dmg/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lamnhan066%2Fdmg/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274010102,"owners_count":25206763,"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-09-07T02:00:09.463Z","response_time":67,"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":["dmg","flutter","macos","notarize","package","plugin","staple"],"created_at":"2024-11-08T23:49:14.891Z","updated_at":"2025-09-07T07:31:23.420Z","avatar_url":"https://github.com/lamnhan066.png","language":"Dart","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# DMG\n\nA Flutter package that helps you create, sign, notarize, and staple a .DMG with a single command.\n\n## Features\n\n- **Easy to use**: Streamline the entire process with one command\n- **Comprehensive**: Handles building, signing, notarizing, and stapling\n- **Error handling**: Robust error handling with detailed logging\n- **Security**: Ensures your .DMG files are signed and notarized as per Apple's requirements\n- **Flexible**: Supports custom settings, license files, and build configurations\n\n## Requirements\n\nAll these steps are needed only for the first app. You can reuse these settings in other apps.\n\n### Before installation, ensure you have the following\n\n- Python (version 3.x or later)\n- Flutter\n- Xcode (for macOS)\n- A valid Apple Developer account with certificates\n\n### Install `dmgbuild` if you haven't ([documentation](https://dmgbuild.readthedocs.io/en/latest/))\n\n```shell\npip install dmgbuild\n```\n\n### Create a `NotaryProfile`\n\n**1.** Go to [App Store Connect -\u003e Users and Access -\u003e Integrations -\u003e App Store Connect API](https://appstoreconnect.apple.com/access/integrations/api).\n\n**2.** Click (+) to generate a new API key, input a Name (normally use `NotaryProfile`) and Access (normally use `Admin`).\n\n**3.** Download the generated file and save it somewhere secure. Also, note the `Issuer ID` and `Key ID`.\n\n**4.** Open the terminal and run `xcrun notarytool store-credentials`. Input all the above data, ensuring the name is input as `NotaryProfile`.\n\n### Create a `Developer ID Application` certificate if you don't have one\n\n**1.** Open Xcode.\n\n**2.** Go to `Xcode` -\u003e `Preferences` -\u003e `Accounts`.\n\n**3.** Click `Manage Certificates...` -\u003e Click (+) -\u003e Choose `Developer ID Application` -\u003e Click `Done`.\n\n## Usage\n\nAdd this package to your development dependency:\n\n```shell\nflutter pub add --dev dmg\n```\n\n### Basic Usage\n\nOpen a terminal in your Flutter project root, then run:\n\n```shell\ndart run dmg\n```\n\nThis will automatically:\n\n1. Clean the build directory (optional)\n2. Run `flutter build macos --release --obfuscate --split-debug-info=debug-macos-info`\n3. Code sign the .app bundle\n4. Create a DMG file\n5. Code sign the DMG\n6. Submit for notarization\n7. Wait for notarization to complete\n8. Staple the notarized DMG\n\n### Advanced Options\n\n#### Custom Signing Certificate\n\nThe package will automatically retrieve and select your Developer ID certificate. If multiple certificates are available, you'll be prompted to choose one. To specify a certificate manually:\n\n```shell\n--sign-certificate \"Developer ID Application: Your Company\"\n```\n\n**Note**: Sometimes you may need to add extra spaces between words, e.g., `\"Your  Company\"`.\n\nThe package will automatically run `flutter build macos --release --obfuscate --split-debug-info=debug-macos-info`. If you want to do it yourself, you can pass this flag to the command:\n\n```shell\n--no-build\n```\n\nWhen the package runs the `build` command, it will also clean the `build/macos` folder to ensure the output files is valid. If you want to skip this behavior, you can pass this flag:\n\n```shell\n--no-clean-build\n```\n\nChange the notary profile name if you haven't used the default by adding:\n\n```shell\n--notary-profile \"NotaryProfile\"\n```\n\nIf you want to add a license (a window will show up asking for acceptance before showing the installation for the .dmg), add this line to the above code:\n\n```shell\n--license-path \"./path/to/license.txt\"\n```\n\nYou can also add your own `settings.py` from [dmg-build](https://dmgbuild.readthedocs.io/en/latest/settings.html) by adding:\n\n```shell\n--settings \"./path/to/settings.py\"\n```\n\nNote that the `--license-path` will be ignored when you use your own `settings.py`.\n\nYour output `DMG` is expected at `build/macos/Build/Products/Release/\u003cname\u003e.dmg`.\n\n## Contributions\n\nThis package is still in the early stages. File an issue if you have one, and PRs are welcome.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flamnhan066%2Fdmg","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flamnhan066%2Fdmg","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flamnhan066%2Fdmg/lists"}