For example, in a Daml project that has other dependencies.
triggers git:(develop) ✗ daml build
2022-09-02 00:34:29.78 [INFO] [build]
Compiling top-secret-triggers to a DAR.
2022-09-02 00:34:31.64 [INFO] [build]
Created .daml/dist/top-secret-triggers-0.0.2.dar
➜ triggers git:(develop) ✗ daml damlc inspect-dar --json .daml/dist/top-secret-triggers-0.0.2.dar | jq -r .main_package_id
fa33e26ff5a74d0d2735699723aaa7403e0a3aacf7c48725d0534ea5a7ae5376
➜ triggers git:(develop) ✗ rm -rf .daml
➜ triggers git:(develop) ✗ daml build
2022-09-02 00:34:59.53 [INFO] [build]
Compiling top-secret-triggers to a DAR.
2022-09-02 00:35:01.30 [INFO] [build]
Created .daml/dist/top-secret-triggers-0.0.2.dar
➜ triggers git:(develop) ✗ daml damlc inspect-dar --json .daml/dist/top-secret-triggers-0.0.2.dar | jq -r .main_package_id
54f9d30d5547382281eed2125a299352fb4259d0c56f651804b65b9840075a09