If I change my research group, can my former supervisor restrict my access to my codes that are written by myself? Recently, I quitted my current research group and I will start to work with someone else. I was in my former research group for almost three years and during these three years I wrote more 200,000 lines of codes by myself alone. These codes rest in my former advisor group repository in Github, but I have copies of them locally in my computer. I know and I understand totally that I'm not allowed to use those codes without my former adviser agreement and also he is not allowed to do so without my agreement. Recently, he removed and revoked my access to the codes that are written by myself during these three years. As I said, I don't want to use them without his agreement, but I'm wondering why he restricted my access to something that completely is written by me and from scratch. I have the local backups but it just makes me upset and I'm wondering if he is allowed to remove my access or not?
Any supervisor (including the OP's former supervisor) is free to block access to their resources, even when those resources include code written by the person being block (including former students).