feat: always initialize git repository
This fixes issues where alternative tools that don't trigger the init via sshcommand - such as git-http-backend - are not able to setup applications correctly. Note that those apps could always manually trigger git:initialize if desired, but if the app already exists, then this should already _just work_ without that extra initialization.
This commit is contained in:
14
plugins/git/post-create
Executable file
14
plugins/git/post-create
Executable file
@@ -0,0 +1,14 @@
|
||||
#!/usr/bin/env bash
|
||||
set -eo pipefail
|
||||
[[ $DOKKU_TRACE ]] && set -x
|
||||
source "$PLUGIN_AVAILABLE_PATH/git/functions"
|
||||
|
||||
trigger-git-post-create() {
|
||||
declare desc="initializes an app with the correct git repository structure"
|
||||
declare trigger="post-create"
|
||||
declare APP="$1"
|
||||
|
||||
fn-git-create-hook "$APP"
|
||||
}
|
||||
|
||||
trigger-git-post-create "$@"
|
||||
Reference in New Issue
Block a user