pulse-browser / gluon

Build firefox forks with ease
https://docs.gluon.dev/
Mozilla Public License 2.0
73 stars 7 forks source link

Do not crash if there is no commit #41

Open trickypr opened 1 year ago

trickypr commented 1 year ago

Some people are experiencing crashes when building without a commit. e.g.

Error: Command failed with exit code 128: git rev-parse HEAD
fatal: not a git repository (or any of the parent directories): .git

We should:

  1. Check if it is in a git repo
  2. Check if there is a commit

If neither of those conditions are met, we should warn the user and use a bogus commit hash (e.g. 0000000 or something)