I am trying to write a shell script
, from which i can get to know the size of remote GIT
repository and SVN
repository.
Example:
My GIT repository
name : MyGITProject
Username : MMMMM
password : yyyyy
My SVN repository
name : MySVNProject
Username : SSSSSSS
password : kkkkkk
You can use git-sizer
for this purpose. Here it has been explained completely on how to do this process. Note that you need a local copy of your git to be able to do so.
To make it as a shell script:
git-sizer
in you shell Also, as a pure-shell workaround for SVN, I did this :
du
recursively for the folders you need: du -sh --max-depth=x
(X the depth of folder structure) Technically, this is not a good idea to put max-depth
to a high number. As your SVN might have astronomical number of files and folders in and this will bring a substantial overhead to your I/O and CPU. But it can help you write a useful script.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.