Building with uncommitted changes on MacOS and Windows #17
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
aab build dev
wasn't working for me on MacOS, because the command being executed to get timestamps of uncommitted changes was different. The original code had a link to this StackOverflow post, which conveniently lists the code that needs to be run on Linux, MacOS, and Windows to get timestamps. All this PR does is check for the user's OS, and run the appropriate command. This fixed the command for me on MacOS. I don't have access to a Windows computer, so I haven't tested it on there.Aside from that simple change, I also had to use a regex to extract the digits in the timestamp out from the entire command output. I'm not sure why this wasn't necessary before, so if this breaks something for someone else, please let me know. From my tests, though, the commands from the StackOverflow post print output in the form
M 1618523117 designer/options.ui
, so to convert it to an integer we'd have to pick out the part of the string that was an integer.Checklist:
Please replace the space inside the brackets with an x and fill out the ellipses if the following items apply: