Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The first step of the acquiring logic (`acquire-git` and `acquire-repository` commands) is removing obsolete configuration options (keys). Now it consists of 2 steps: 1. removing of `elegant.acquired` key as it was replaced with `elegant-git.acquired` key 2. removing Elegant Git aliases as they should be reconfigured each time acquiring works Also, now the `libexec/plugins/configuration-acquired` plugin encapsulates acquiring logic.
- Loading branch information
Showing
9 changed files
with
41 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
#!/usr/bin/env bash | ||
# The plugin provides configuration for "acquired" logic that determines | ||
# whether Elegant Git global configuration is applied or not. | ||
|
||
acquired=("elegant-git.acquired" "true") | ||
|
||
is-git-acquired() { | ||
# usage : is-git-acquired | ||
# result: 0 or 1 | ||
if [[ "$(git config --global --get ${acquired[0]} || true)" == ${acquired[1]} ]]; then | ||
return 0 | ||
fi | ||
return 1 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters