The folder name of the zip downloaded from github is like %repository-name%-master
, but I need that folder just as %repository-name%
Can this be done?
Way 1: Rename using GitHubStep 1: Open GitHub. Step 2: Open the repository to rename any file in that repository. Step 3: Open the file which we want to rename. Step 4: Click the edit button and rename the file.
You can rename a repository if you're either an organization owner or have admin permissions for the repository.
In your repository, browse to the file you want to rename. In the upper right corner of the file view, click to open the file editor. In the filename field, change the name of the file to the new filename you want. You can also update the contents of your file at the same time.
You cannot modify the name of the root directory contained in an archive from github.
Even when you download master:
wget https://github.com/user/repo/tarball/master
You will get a file named 'master', but:
tar xpvf master
The tar xpvf
will give you a repo-xxxx
directory.
I usually follow with:
mv repo-* repo
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With