Page MenuHomeFreeBSD

git-arc: Globally save and restore the git checkout head
ClosedPublic

Authored by markj on Feb 12 2021, 9:56 PM.
Tags
None
Referenced Files
Unknown Object (File)
Apr 21 2025, 2:55 PM
Unknown Object (File)
Apr 17 2025, 12:36 PM
Unknown Object (File)
Apr 16 2025, 10:00 AM
Unknown Object (File)
Apr 9 2025, 12:44 PM
Unknown Object (File)
Mar 21 2025, 6:05 PM
Unknown Object (File)
Mar 6 2025, 1:53 AM
Unknown Object (File)
Mar 5 2025, 4:15 PM
Unknown Object (File)
Mar 4 2025, 9:49 PM
Subscribers

Details

Summary

This script uses -e, so it's prone to exiting in awkward places. In
particular, if arc diff fails, the script just exits without restoring
the checkout.

Mitigate this for now by using a global variable to record the previous
checkout and use a trap handler to restore it in the face of errors. A
better solution might be to use arc diff's --head parameter but that
will require more testing.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 36945
Build 33834: arc lint + arc unit