kittygirl
kittygirl

Reputation: 2443

How to change git repo's owner?

I used the root user to init, add, and commit git repo. (bad habit)
Now, I create a new normal user me.
How to let me to handle the repo made by root?

Upvotes: 3

Views: 19816

Answers (1)

weeska
weeska

Reputation: 461

Use:

sudo chown user[:group] . -R

from within the repositories folder to change the owner, where user is the desired user (and optionally a group name may also be supplied).

Upvotes: 10

Related Questions