Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cache blame results with a project-specific filename instead of always using blame.json #15

Open
thehale opened this issue Apr 1, 2023 · 1 comment
Labels
enhancement New feature or request good first issue Good for newcomers hacktoberfest

Comments

@thehale
Copy link
Owner

thehale commented Apr 1, 2023

It would be nice to support caching blame results for multiple projects at the same time so that blame doesn't have to be recomputed every time a user switches projects.

This could be accomplished by changing the naming format of the cached blame file to include project specific information. When that project information changes, a new cached blame file will be created/read as appropriate.

The proposed naming format is

OWNER-PROJECT-COMMIT_HASH.json

For example, the current tip of this project would have a cache file of

thehale-git-authorship-1e244fd8fb4efdec68a598fdf1154c48909e76b9.json

This format will cache blame files for a specific commit in a specific project.

@thehale thehale added enhancement New feature or request good first issue Good for newcomers labels Apr 1, 2023
@thehale
Copy link
Owner Author

thehale commented Sep 18, 2023

An alternate approach that would also be welcome is a subfolder approach:

./cache/OWNER/PROJECT/COMMIT_HASH.json

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers hacktoberfest
Projects
None yet
Development

No branches or pull requests

1 participant