Skip to content

Store cached git repos by URL, not submodule directory name#18

Open
abranson wants to merge 1 commit into
MeeGoIntegration:masterfrom
abranson:submodname
Open

Store cached git repos by URL, not submodule directory name#18
abranson wants to merge 1 commit into
MeeGoIntegration:masterfrom
abranson:submodname

Conversation

@abranson
Copy link
Copy Markdown

Remove name parameter from cache_prefetch, as the local directory name
may clash with other repos (e.g. 'upstream'). Instead just use the
remaining last path component of the URL.

may clash with other repos (e.g. 'upstream'). Instead just use the
remaining last path component of the URL.
Copy link
Copy Markdown
Contributor

@larstiq larstiq left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With this change it's possible submodules will be cached in a different directory. Initial clone will then be a bit slower, and total disk usage higher until the cache is cleared out.

Will keep this in mind when deploying.

Comment thread src/service/tar_git
URL=$MYURL
cache_prefetch $CLONE_NAME $URL
cache_prefetch $URL
MYURL=$URL
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was afraid for CLONE_NAME we'd lose the logic of parse_url, but basename nicely does the same thing \o/

@keto keto closed this Apr 12, 2017
@keto keto changed the base branch from devel to master April 12, 2017 12:25
@keto keto reopened this Apr 12, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants