这是indexloc提供的服务,不要输入任何密码
Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion plugins/config/functions
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ config_unset() {

for var in $VARS; do
dokku_log_info1 "Unsetting $var"
ENV_TEMP=$(echo -e "${ENV_TEMP}" | sed "/^export $var=/ d")
ENV_TEMP=$(echo "${ENV_TEMP}" | sed "/^export $var=/ d")

config_write "$ENV_TEMP"
done
Expand Down
6 changes: 5 additions & 1 deletion tests/unit/config.bats
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ teardown() {
}

@test "(config) config:unset" {
run ssh dokku@dokku.me config:set $TEST_APP test_var=true test_var2=\"hello world\"
run ssh dokku@dokku.me config:set $TEST_APP test_var=true test_var2=\"hello world\" test_var3=\"with\\nnewline\"
echo "output: "$output
echo "status: "$status
assert_success
Expand All @@ -93,6 +93,10 @@ teardown() {
echo "output: "$output
echo "status: "$status
assert_output ""
run dokku config:get $TEST_APP test_var3
echo "output: "$output
echo "status: "$status
assert_output 'with\nnewline'
}

@test "(config) global config (herokuish)" {
Expand Down