Created
March 23, 2020 13:23
-
-
Save miry/1c5849c22cb3201bc33995222c3f2143 to your computer and use it in GitHub Desktop.
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
# Insert in the string `id: :integer` option any place after first argument, only if it is not specified | |
# Example without :id option provided | |
"create_table "cr_bandit_parameters", primary_key: "parameter", force: :cascade do |t|" => | |
"create_table "cr_bandit_parameters", primary_key: "parameter", force: :cascade, id: :integer do |t|" | |
# Example should not be changed because it has id: false | |
"create_table "cr_bandit_parameters", primary_key: "parameter", id: false, force: :cascade do |t|" => | |
"create_table "cr_bandit_parameters", primary_key: "parameter", id: false, force: :cascade do |t|" | |
# Example should not be changed because it has id: :ineteger | |
"create_table "cr_bandit_parameters", id: :ineteger, primary_key: "parameter", force: :cascade do |t|" => | |
"create_table "cr_bandit_parameters", id: :ineteger, primary_key: "parameter", force: :cascade do |t|" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment