mirror of
https://github.com/TheLocehiliosan/yadm
synced 2024-10-27 20:34:27 +00:00
Translate gitconfig to config inside git_command()
This consolidates calls to git_command()
This commit is contained in:
parent
4948f1b137
commit
431f149730
9
yadm
9
yadm
@ -43,10 +43,6 @@ function main() {
|
|||||||
if [ -z "$*" ] ; then
|
if [ -z "$*" ] ; then
|
||||||
#; no argumnts will result in help()
|
#; no argumnts will result in help()
|
||||||
help
|
help
|
||||||
elif [ "$1" = "gitconfig" ] ; then
|
|
||||||
#; 'config' is used for yadm, need to use 'gitcofnig' to pass through to git
|
|
||||||
shift
|
|
||||||
git_command config "$@"
|
|
||||||
elif [[ "$1" =~ $internal_commands ]] ; then
|
elif [[ "$1" =~ $internal_commands ]] ; then
|
||||||
#; for internal commands, process all of the arguments
|
#; for internal commands, process all of the arguments
|
||||||
YADM_COMMAND="$1"
|
YADM_COMMAND="$1"
|
||||||
@ -261,6 +257,11 @@ function git_command() {
|
|||||||
|
|
||||||
require_repo
|
require_repo
|
||||||
|
|
||||||
|
#; translate 'gitconfig' to 'config' -- 'config' is reserved for yadm
|
||||||
|
if [ "$1" = "gitconfig" ] ; then
|
||||||
|
set -- "config" "${@:2}"
|
||||||
|
fi
|
||||||
|
|
||||||
#; pass commands through to git
|
#; pass commands through to git
|
||||||
git "$@"
|
git "$@"
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user