Is it possible to create a third mode, in addition to the default and gitmode, called “compact,” which would run before compact and also before exit?