-
-
Notifications
You must be signed in to change notification settings - Fork 2k
Add git:unlock command #4465
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
josegonzalez
merged 21 commits into
dokku:master
from
Akirtovskis:4458-git-sync-clone-in-progress
Mar 12, 2021
Merged
Add git:unlock command #4465
Changes from all commits
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
b1db1e3
add git:unlock functionality
Akirtovskis 58dca68
fix has_tty if condition
Akirtovskis 741ea68
fix formatting according to shfmt
Akirtovskis c05f220
make unlock file exec
Akirtovskis 99bc51f
fix unlock command
Akirtovskis 642dc83
fix lint issue
Akirtovskis 5debadf
remove redundant code
Akirtovskis 5ae531c
remove unnecessary code
Akirtovskis 8d11789
add tests and prompt to unlock
Akirtovskis 5a002f9
update docs
Akirtovskis ebcacdb
add new line at the end of the file
Akirtovskis 888f452
fix shfmt
Akirtovskis dff21e1
fix test
Akirtovskis 76d9b37
fix typo
Akirtovskis b061843
fix formatting issue
Akirtovskis 5c27ec3
add deploy command to tests
Akirtovskis 4e50214
remove redundant commands from test
Akirtovskis f9be3dd
clean up remove clone folder fn
Akirtovskis 4cd064f
chore: run shfmt against file
josegonzalez 9781a90
fix: create correct clone directory
josegonzalez a901661
chore: set perms on tmp git directory
josegonzalez File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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 hidden or 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 hidden or 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,6 @@ | ||
| #!/usr/bin/env bash | ||
| source "$PLUGIN_AVAILABLE_PATH/git/internal-functions" | ||
| set -eo pipefail | ||
| [[ $DOKKU_TRACE ]] && set -x | ||
|
|
||
| cmd-git-unlock "$@" |
This file contains hidden or 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,30 @@ | ||
| #!/usr/bin/env bats | ||
|
|
||
| load test_helper | ||
|
|
||
| setup() { | ||
| global_setup | ||
| touch /home/dokku/.ssh/known_hosts | ||
| chown dokku:dokku /home/dokku/.ssh/known_hosts | ||
| mkdir -p "$DOKKU_LIB_ROOT/data/git/$TEST_APP" | ||
| chown dokku:dokku "$DOKKU_LIB_ROOT/data/git/$TEST_APP" | ||
| } | ||
|
|
||
| teardown() { | ||
| rm -f /home/dokku/.ssh/id_rsa.pub || true | ||
| global_teardown | ||
| } | ||
|
|
||
| @test "(git) git:unlock [success]" { | ||
| run /bin/bash -c "dokku git:unlock $TEST_APP --force" | ||
| echo "output: $output" | ||
| echo "status: $status" | ||
| assert_success | ||
| } | ||
|
|
||
| @test "(git) git:unlock [missing arg]" { | ||
| run /bin/bash -c "dokku git:unlock" | ||
| echo "output: $output" | ||
| echo "status: $status" | ||
| assert_failure | ||
| } |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.