8000 repository.ConfigScoped and worktree.Commit with empty CommitOptions by mcuadros · Pull Request #75 · go-git/go-git · GitHub
[go: up one dir, main page]

Skip to content

repository.ConfigScoped and worktree.Commit with empty CommitOptions #75

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

Merged
merged 8 commits into from
May 24, 2020

Conversation

mcuadros
Copy link
Member
@mcuadros mcuadros commented May 24, 2020

This PR allows implements the tools to read git config files in the different scopes, local, global, and system.

It also allows to do Repository.Commit with an empty CommitOptions, since the author and committer information is read from the global scope, or wherever is defined.

The PRs were reverted due to the old implementation was mixing in the filesystem storer, files from billy's filesystems and os.Files. Also, the implementation didn't suit the final implementation details (see #23). Thanks @cap10morgan for your excellent work, but I did a poor work reviewing the design of it.

Reverts #20
Reverts #31
Closes #23
Fixes #19

@mcuadros mcuadros changed the title Scope config repository.ConfigScoped and repository.Commit with empty CommitOptions May 24, 2020
@mcuadros mcuadros changed the title repository.ConfigScoped and repository.Commit with empty CommitOptions repository.ConfigScoped and worktree.Commit with empty CommitOptions May 24, 2020
@mcuadros mcuadros merged commit e7f5448 into go-git:master May 24, 2020
cmiller01 added a commit to cmiller01/go-git that referenced this pull request Jul 26, 2022
* previously an example existed for working with `config.Config`, but changes in implementation made the example not usable. (see go-git#75)
* this mostly puts back the original example with some modifications to
make it work with current implementation
traidare pushed a commit to traidare/go-git that referenced this pull request Oct 26, 2024
repository.ConfigScoped and worktree.Commit with empty CommitOptions
pjbgf pushed a commit to pjbgf/go-git that referenced this pull request Dec 19, 2024
* previously an example existed for working with `config.Config`, but changes in implementation made the example not usable. (see go-git#75)
* this mostly puts back the original example with some modifications to
make it work with current implementation
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.

Worktree.Commit() read git config user data
2 participants
0