Check if there are uncommitted changes (only returns an exit code)

etckeeper

sudo etckeeper unclean

click the source code to copy install etckeeper on any operating system with command-not-found.com