forked from Kong/kong
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(migrations) handle missing schema_migrations
Handle occasional error where the schema_migrations columnfamily would be missing thus preventing the migrations to work properly. We now print a better error for the unaware user and suggest that the "kong migrations reset" command should be run to fix this. Fix Kong#250 Former-commit-id: 4e62f5f36fd20dc029a92f2f54e88a372879ad06
- Loading branch information
1 parent
4ae3e35
commit c94f8a7
Showing
5 changed files
with
49 additions
and
27 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
local _M = {} | ||
|
||
local ANSWERS = { | ||
y = true, | ||
Y = true, | ||
yes = true, | ||
YES = true, | ||
n = false, | ||
N = false, | ||
no = false, | ||
NO = false | ||
} | ||
|
||
function _M.confirm(question) | ||
local answer | ||
repeat | ||
io.write(question.." [Y/n] ") | ||
answer = ANSWERS[io.read("*l")] | ||
until answer ~= nil | ||
|
||
return answer | ||
end | ||
|
||
return _M |
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