Fix (Git)ResourceDirectory to be pickleable to support local persistent component registry