kisslinux / kiss

KISS Linux - Package Manager
https://kisslinux.github.io
MIT License
464 stars 62 forks source link

Cache git source #255

Closed Rio6 closed 3 years ago

Rio6 commented 3 years ago

I was making kiss cache git clones on my own machine, then I saw in #224 there's an actual plan for this feature. So I thought might as well making a PR for it.

Right now it doesn't handle the case where the repository changes, but I think I can make it delete the cache and re-clone in that case. Changing tags works fine.

Rio6 commented 3 years ago

Played around a bit, seems like git actually can handle sparse checkout from different unrelated repos. So that means the script itself doesn't need to handle repository change.

dylanaraps commented 3 years ago

Please try: https://github.com/kisslinux/kiss/pull/261

dylanaraps commented 3 years ago

Implemented here: https://github.com/kisslinux/kiss/commit/88b5989da41261fbe10f0f78a1177049542f88a9