repo
stringlengths
5
92
file_url
stringlengths
80
287
file_path
stringlengths
5
197
content
stringlengths
0
32.8k
language
stringclasses
1 value
license
stringclasses
7 values
commit_sha
stringlengths
40
40
retrieved_at
stringdate
2026-01-04 15:37:27
2026-01-04 17:58:21
truncated
bool
2 classes
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20250115144823_change_utm_links_target_resource_id_column_type.rb
db/migrate/20250115144823_change_utm_links_target_resource_id_column_type.rb
# frozen_string_literal: true class ChangeUtmLinksTargetResourceIdColumnType < ActiveRecord::Migration[7.1] def up change_column :utm_links, :target_resource_id, :bigint end def down change_column :utm_links, :target_resource_id, :string end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20250225090016_create_communities.rb
db/migrate/20250225090016_create_communities.rb
# frozen_string_literal: true class CreateCommunities < ActiveRecord::Migration[7.1] def change create_table :communities do |t| t.references :resource, polymorphic: true, null: false t.references :seller, null: false t.datetime :deleted_at, index: true t.timestamps t.index [:reso...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20150706100000_add_local_currency_to_payments.rb
db/migrate/20150706100000_add_local_currency_to_payments.rb
# frozen_string_literal: true class AddLocalCurrencyToPayments < ActiveRecord::Migration def change add_column :payments, :local_currency, :string end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20130419202457_add_preorder_id_to_url_redirect.rb
db/migrate/20130419202457_add_preorder_id_to_url_redirect.rb
# frozen_string_literal: true class AddPreorderIdToUrlRedirect < ActiveRecord::Migration def change add_column :url_redirects, :preorder_id, :integer add_index :url_redirects, :preorder_id end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20120706013215_delete_default_for_links_price_cents.rb
db/migrate/20120706013215_delete_default_for_links_price_cents.rb
# frozen_string_literal: true class DeleteDefaultForLinksPriceCents < ActiveRecord::Migration def up change_column_default :links, :price_cents, nil end def down change_column_default :links, :price_cents, 0 end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20210618101147_add_state_and_failed_verification_attempts_count_to_custom_domains.rb
db/migrate/20210618101147_add_state_and_failed_verification_attempts_count_to_custom_domains.rb
# frozen_string_literal: true class AddStateAndFailedVerificationAttemptsCountToCustomDomains < ActiveRecord::Migration[6.1] def change change_table :custom_domains, bulk: true do |t| t.string :state, null: false, default: "unverified" t.integer :failed_verification_attempts_count, null: false, defau...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20120502230858_remove_facebook_and_twitter_pictures_from_users.rb
db/migrate/20120502230858_remove_facebook_and_twitter_pictures_from_users.rb
# frozen_string_literal: true class RemoveFacebookAndTwitterPicturesFromUsers < ActiveRecord::Migration def up remove_column :users, :facebook_pic_large remove_column :users, :facebook_pic_square remove_column :users, :twitter_pic end def down add_column :users, :facebook_pic_large, :string ...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20121115033456_remove_error_code_as_index_on_purchases.rb
db/migrate/20121115033456_remove_error_code_as_index_on_purchases.rb
# frozen_string_literal: true class RemoveErrorCodeAsIndexOnPurchases < ActiveRecord::Migration def up remove_index :purchases, :error_code end def down add_index :purchases, :error_code end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20120911185928_add_weekly_notification_to_users.rb
db/migrate/20120911185928_add_weekly_notification_to_users.rb
# frozen_string_literal: true class AddWeeklyNotificationToUsers < ActiveRecord::Migration def change add_column(:users, :weekly_notification, :boolean, { default: true }) end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20210103203438_add_processor_reversing_payout_id_to_payments.rb
db/migrate/20210103203438_add_processor_reversing_payout_id_to_payments.rb
# frozen_string_literal: true class AddProcessorReversingPayoutIdToPayments < ActiveRecord::Migration[6.0] def change add_column :payments, :processor_reversing_payout_id, :string end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20230709185752_make_url_redirects_token_unique.rb
db/migrate/20230709185752_make_url_redirects_token_unique.rb
# frozen_string_literal: true class MakeUrlRedirectsTokenUnique < ActiveRecord::Migration[7.0] def up change_table :url_redirects, bulk: true do |t| t.change :token, :string, null: false t.remove_index :token t.index :token, unique: true end end def down change_table :url_redirects...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20120718175328_add_pagelength_to_links.rb
db/migrate/20120718175328_add_pagelength_to_links.rb
# frozen_string_literal: true class AddPagelengthToLinks < ActiveRecord::Migration def change add_column :links, :pagelength, :integer end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20190910183443_add_slug_to_installments.rb
db/migrate/20190910183443_add_slug_to_installments.rb
# frozen_string_literal: true class AddSlugToInstallments < ActiveRecord::Migration def up add_column :installments, :slug, :string add_index :installments, :slug, unique: true end def down remove_column :installments, :slug end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20120821011734_add_banned_at_to_blocked_ip.rb
db/migrate/20120821011734_add_banned_at_to_blocked_ip.rb
# frozen_string_literal: true class AddBannedAtToBlockedIp < ActiveRecord::Migration def change add_column :blocked_ips, :banned_at, :timestamp end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20240503060350_add_index_on_gift_gifter_purchase_id.rb
db/migrate/20240503060350_add_index_on_gift_gifter_purchase_id.rb
# frozen_string_literal: true class AddIndexOnGiftGifterPurchaseId < ActiveRecord::Migration[7.1] def up change_table :gifts, bulk: true do |t| t.index :gifter_purchase_id t.change :id, :bigint, null: false, auto_increment: true t.change :giftee_purchase_id, :bigint t.change :gifter_purc...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20150728164700_add_verified_at_to_merchant_accounts.rb
db/migrate/20150728164700_add_verified_at_to_merchant_accounts.rb
# frozen_string_literal: true class AddVerifiedAtToMerchantAccounts < ActiveRecord::Migration def change add_column :merchant_accounts, :charge_processor_verified_at, :datetime end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20111122014046_add_link_to_purchase.rb
db/migrate/20111122014046_add_link_to_purchase.rb
# frozen_string_literal: true class AddLinkToPurchase < ActiveRecord::Migration def change add_column :purchases, :link_id, :integer end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20220723200147_recreate_products_index_for_user_id_type_change.rb
db/migrate/20220723200147_recreate_products_index_for_user_id_type_change.rb
# frozen_string_literal: true class RecreateProductsIndexForUserIdTypeChange < ActiveRecord::Migration[6.1] def up return unless Rails.env.development? Link.__elasticsearch__.create_index!(force: true) Link.import end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20121030215656_add_unbannable_to_users.rb
db/migrate/20121030215656_add_unbannable_to_users.rb
# frozen_string_literal: true class AddUnbannableToUsers < ActiveRecord::Migration def change add_column :users, :unbannable, :boolean, default: false end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20231101082733_add_merchant_accounts_index_on_charge_processor_merchant_id.rb
db/migrate/20231101082733_add_merchant_accounts_index_on_charge_processor_merchant_id.rb
# frozen_string_literal: true class AddMerchantAccountsIndexOnChargeProcessorMerchantId < ActiveRecord::Migration[7.0] def change add_index :merchant_accounts, :charge_processor_merchant_id end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20220430002128_add_index_to_users_created_at.rb
db/migrate/20220430002128_add_index_to_users_created_at.rb
# frozen_string_literal: true class AddIndexToUsersCreatedAt < ActiveRecord::Migration[6.1] def change change_table :users, bulk: true do |t| t.index :created_at end end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20200921213213_create_subscription_plan_changes.rb
db/migrate/20200921213213_create_subscription_plan_changes.rb
# frozen_string_literal: true class CreateSubscriptionPlanChanges < ActiveRecord::Migration[5.2] def change create_table :subscription_plan_changes do |t| t.references :subscription, null: false, index: true t.references :base_variant, null: false, index: true t.string :recurrence, null: false ...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20131115164420_index_transcoded_videos_on_product_file_id.rb
db/migrate/20131115164420_index_transcoded_videos_on_product_file_id.rb
# frozen_string_literal: true class IndexTranscodedVideosOnProductFileId < ActiveRecord::Migration def up add_index :transcoded_videos, :product_file_id end def down remove_index :transcoded_videos, :product_file_id end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20141218034833_create_workflows.rb
db/migrate/20141218034833_create_workflows.rb
# frozen_string_literal: true class CreateWorkflows < ActiveRecord::Migration def change create_table :workflows do |t| t.string :name t.integer :seller_id t.integer :link_id t.string :workflow_type t.datetime :published_at t.datetime :deleted_at t.timestamps end ...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20210924172723_remove_code_columns_from_links.rb
db/migrate/20210924172723_remove_code_columns_from_links.rb
# frozen_string_literal: true class RemoveCodeColumnsFromLinks < ActiveRecord::Migration[6.1] def up change_table :links, bulk: true do |t| t.change :id, :bigint, null: false, unique: true, auto_increment: true t.change :user_id, :bigint t.change :flags, :bigint, default: 0, null: false t...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20250213174713_create_product_installment_plans.rb
db/migrate/20250213174713_create_product_installment_plans.rb
# frozen_string_literal: true class CreateProductInstallmentPlans < ActiveRecord::Migration[7.1] def change create_table :product_installment_plans do |t| t.references :link, null: false t.integer :number_of_installments, null: false t.string :recurrence, null: false t.timestamps end...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20230509105457_add_title_and_position_to_rich_contents.rb
db/migrate/20230509105457_add_title_and_position_to_rich_contents.rb
# frozen_string_literal: true class AddTitleAndPositionToRichContents < ActiveRecord::Migration[7.0] def change change_table :rich_contents, bulk: true do |t| t.string :title t.integer :position, default: 0, null: false end end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20231231000023_add_json_data_to_seller_profile_sections.rb
db/migrate/20231231000023_add_json_data_to_seller_profile_sections.rb
# frozen_string_literal: true class AddJsonDataToSellerProfileSections < ActiveRecord::Migration[7.0] def change change_table :seller_profile_sections, bulk: true do |t| t.column :json_data, :json t.column :type, :string, null: false, default: "SellerProfileProductsSection" t.change_null :shown...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20120718175414_add_duration_to_links.rb
db/migrate/20120718175414_add_duration_to_links.rb
# frozen_string_literal: true class AddDurationToLinks < ActiveRecord::Migration def change add_column :links, :duration, :integer end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20240423185410_add_charge_id_to_purchase_early_fraud_warnings.rb
db/migrate/20240423185410_add_charge_id_to_purchase_early_fraud_warnings.rb
# frozen_string_literal: true class AddChargeIdToPurchaseEarlyFraudWarnings < ActiveRecord::Migration[7.1] def up change_table :purchase_early_fraud_warnings, bulk: true do |t| t.bigint :charge_id, index: { unique: true } t.change :purchase_id, :bigint, null: true t.index :processor_id, unique...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20201214172042_add_stripe_sca_columns_to_purchase.rb
db/migrate/20201214172042_add_stripe_sca_columns_to_purchase.rb
# frozen_string_literal: true class AddStripeScaColumnsToPurchase < ActiveRecord::Migration[6.0] def up # Using raw SQL due to a bug in departure gem: https://github.com/gumroad/web/pull/17299#issuecomment-786054996 execute <<~SQL ALTER TABLE purchases ADD COLUMN processor_payment_intent_id VAR...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20130226051039_add_subscription_id_to_purchases.rb
db/migrate/20130226051039_add_subscription_id_to_purchases.rb
# frozen_string_literal: true class AddSubscriptionIdToPurchases < ActiveRecord::Migration def change add_column :purchases, :subscription_id, :integer end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20111110202009_salt.rb
db/migrate/20111110202009_salt.rb
# frozen_string_literal: true class Salt < ActiveRecord::Migration def up add_column :users, :password_salt, :string end def down remove_column :users, :password_salt end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20230605234115_create_taxonomy_stats.rb
db/migrate/20230605234115_create_taxonomy_stats.rb
# frozen_string_literal: true class CreateTaxonomyStats < ActiveRecord::Migration[7.0] def change create_table :taxonomy_stats do |t| t.references :taxonomy, null: false t.integer :creators_count, null: false, default: 0 t.integer :products_count, null: false, default: 0 t.integer :sales_...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20230125164938_add_price_change_attributes_to_variants.rb
db/migrate/20230125164938_add_price_change_attributes_to_variants.rb
# frozen_string_literal: true class AddPriceChangeAttributesToVariants < ActiveRecord::Migration[7.0] def change change_table :base_variants, bulk: true do |t| t.date :subscription_price_change_effective_date t.text :subscription_price_change_message, size: :long end end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20121127215553_add_notification_endpoint_to_users.rb
db/migrate/20121127215553_add_notification_endpoint_to_users.rb
# frozen_string_literal: true class AddNotificationEndpointToUsers < ActiveRecord::Migration def change add_column :users, :notification_endpoint, :text end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20120528234200_add_zip_code_to_users.rb
db/migrate/20120528234200_add_zip_code_to_users.rb
# frozen_string_literal: true class AddZipCodeToUsers < ActiveRecord::Migration def change add_column :users, :zip_code, :string end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20170511105947_add_link_id_to_refund.rb
db/migrate/20170511105947_add_link_id_to_refund.rb
# frozen_string_literal: true class AddLinkIdToRefund < ActiveRecord::Migration def change add_column :refunds, :link_id, :integer add_index :refunds, :link_id end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20240422093212_create_wishlist_followers.rb
db/migrate/20240422093212_create_wishlist_followers.rb
# frozen_string_literal: true class CreateWishlistFollowers < ActiveRecord::Migration[7.1] def change create_table :wishlist_followers do |t| t.belongs_to :wishlist, null: false t.belongs_to :follower_user, null: false t.datetime :deleted_at t.timestamps end end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20130223002446_add_index_to_offer_codes.rb
db/migrate/20130223002446_add_index_to_offer_codes.rb
# frozen_string_literal: true class AddIndexToOfferCodes < ActiveRecord::Migration def change add_index :offer_codes, [:link_id, :name], unique: true end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20230322212701_add_recommender_model_name_to_recommended_purchase_infos.rb
db/migrate/20230322212701_add_recommender_model_name_to_recommended_purchase_infos.rb
# frozen_string_literal: true class AddRecommenderModelNameToRecommendedPurchaseInfos < ActiveRecord::Migration[7.0] def change add_column :recommended_purchase_infos, :recommender_model_name, :string end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20130109002024_create_installments.rb
db/migrate/20130109002024_create_installments.rb
# frozen_string_literal: true class CreateInstallments < ActiveRecord::Migration def change create_table :installments do |t| t.integer :link_id t.text :message t.text :url t.timestamps end end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20120528234240_add_street_address_to_users.rb
db/migrate/20120528234240_add_street_address_to_users.rb
# frozen_string_literal: true class AddStreetAddressToUsers < ActiveRecord::Migration def change add_column :users, :street_address, :string end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20210510195127_create_audience_landing_page_view_events.rb
db/migrate/20210510195127_create_audience_landing_page_view_events.rb
# frozen_string_literal: true class CreateAudienceLandingPageViewEvents < ActiveRecord::Migration[6.1] def change # https://dev.mysql.com/doc/refman/5.6/en/integer-types.html starting_id = 2147483648 # INT maximum value signed + 1 create_table "audience_landing_page_view_events", options: "ENGINE=InnoDB ...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20120112220152_redirect_has_purchase.rb
db/migrate/20120112220152_redirect_has_purchase.rb
# frozen_string_literal: true class RedirectHasPurchase < ActiveRecord::Migration def up add_column :url_redirects, :purchase_id, :integer remove_column :url_redirects, :link_id end def down remove_column :url_redirects, :purchase_id add_column :url_redirects, :link_id, :integer end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20220913190940_create_team_memberships.rb
db/migrate/20220913190940_create_team_memberships.rb
# frozen_string_literal: true class CreateTeamMemberships < ActiveRecord::Migration[6.1] def change create_table :team_memberships do |t| t.bigint :seller_id, null: false t.bigint :user_id, null: false t.string :role, null: false t.datetime :last_accessed_at t.datetime :deleted_at ...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20201221130000_sync_dev_tables_collations_with_prod.rb
db/migrate/20201221130000_sync_dev_tables_collations_with_prod.rb
# frozen_string_literal: true class SyncDevTablesCollationsWithProd < ActiveRecord::Migration[6.0] def up execute %(ALTER TABLE affiliate_credits CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci) execute %(ALTER TABLE affiliate_partial_refunds CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci) execute %(A...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
true
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20170511111723_populate_link_ids_to_refund.rb
db/migrate/20170511111723_populate_link_ids_to_refund.rb
# frozen_string_literal: true class PopulateLinkIdsToRefund < ActiveRecord::Migration def change Refund.find_each do |refund| refund.link_id = refund.purchase.link_id if refund.purchase refund.save! end end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20230412221903_rename_upsells_products_to_upsells_selected_products.rb
db/migrate/20230412221903_rename_upsells_products_to_upsells_selected_products.rb
# frozen_string_literal: true class RenameUpsellsProductsToUpsellsSelectedProducts < ActiveRecord::Migration[7.0] def change rename_table :upsells_products, :upsells_selected_products end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20121113194639_add_card_bin_to_purchases.rb
db/migrate/20121113194639_add_card_bin_to_purchases.rb
# frozen_string_literal: true class AddCardBinToPurchases < ActiveRecord::Migration def change add_column :purchases, :card_bin, :string end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20120226203341_change_bitrate_to_integer.rb
db/migrate/20120226203341_change_bitrate_to_integer.rb
# frozen_string_literal: true class ChangeBitrateToInteger < ActiveRecord::Migration def up change_column :infos, :bitrate, :integer end def down change_column :infos, :bitrate, :string end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20230116193007_add_product_files_stampable_pdf.rb
db/migrate/20230116193007_add_product_files_stampable_pdf.rb
# frozen_string_literal: true class AddProductFilesStampablePdf < ActiveRecord::Migration[7.0] def change add_column :product_files, :stampable_pdf, :boolean end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20130108210059_add_credit_granting_user_id_to_credits.rb
db/migrate/20130108210059_add_credit_granting_user_id_to_credits.rb
# frozen_string_literal: true class AddCreditGrantingUserIdToCredits < ActiveRecord::Migration def change add_column :credits, :crediting_user_id, :integer end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20120706001847_change_url_to_text.rb
db/migrate/20120706001847_change_url_to_text.rb
# frozen_string_literal: true class ChangeUrlToText < ActiveRecord::Migration def up change_column :links, :url, :text end def down change_column :links, :url, :string end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20211221202333_create_sales_exports.rb
db/migrate/20211221202333_create_sales_exports.rb
# frozen_string_literal: true class CreateSalesExports < ActiveRecord::Migration[6.1] def change create_table :sales_exports do |t| t.bigint :recipient_id, null: false, index: true t.text :query t.timestamps end end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20121011224111_changed_purchase_state_type.rb
db/migrate/20121011224111_changed_purchase_state_type.rb
# frozen_string_literal: true class ChangedPurchaseStateType < ActiveRecord::Migration def change change_column :events, :purchase_state, :string change_column_default(:events, :purchase_state, nil) end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20151020214443_make_product_tags_not_unique.rb
db/migrate/20151020214443_make_product_tags_not_unique.rb
# frozen_string_literal: true class MakeProductTagsNotUnique < ActiveRecord::Migration def change remove_index :product_tags, [:link_id, :tag] add_index :product_tags, [:link_id, :tag] end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20240410225020_create_email_info_charges.rb
db/migrate/20240410225020_create_email_info_charges.rb
# frozen_string_literal: true class CreateEmailInfoCharges < ActiveRecord::Migration[7.0] def change create_table :email_info_charges do |t| t.references :email_info, index: true, null: false t.references :charge, index: true, null: false end end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20220222171855_add_unsplash_url_to_asset_preview.rb
db/migrate/20220222171855_add_unsplash_url_to_asset_preview.rb
# frozen_string_literal: true class AddUnsplashUrlToAssetPreview < ActiveRecord::Migration[6.1] def change add_column :asset_previews, :unsplash_url, :string end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20190528172432_add_megaphone_states_datetimes.rb
db/migrate/20190528172432_add_megaphone_states_datetimes.rb
# frozen_string_literal: true class AddMegaphoneStatesDatetimes < ActiveRecord::Migration def change add_column :megaphone_states, :created_at, :datetime add_column :megaphone_states, :updated_at, :datetime end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20151207191059_add_service_charge_to_events.rb
db/migrate/20151207191059_add_service_charge_to_events.rb
# frozen_string_literal: true class AddServiceChargeToEvents < ActiveRecord::Migration def change add_column :events, :service_charge_id, :integer end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20220308192852_remove_name_from_taxonomies.rb
db/migrate/20220308192852_remove_name_from_taxonomies.rb
# frozen_string_literal: true class RemoveNameFromTaxonomies < ActiveRecord::Migration[6.1] def up change_table(:taxonomies, bulk: true) do |t| t.remove :name t.index "(IFNULL(`parent_id`,0)), `slug`", name: :index_taxonomies_on_parent_id_and_slug, unique: true end end def down change_ta...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20120614180000_remove_currency.rb
db/migrate/20120614180000_remove_currency.rb
# frozen_string_literal: true class RemoveCurrency < ActiveRecord::Migration def up drop_table :currencies end def down create_table :currencies do |t| t.float :currency_rate t.string :currency_type end end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20251110144032_remove_foreign_key_from_installment_plan_snapshots.rb
db/migrate/20251110144032_remove_foreign_key_from_installment_plan_snapshots.rb
# frozen_string_literal: true class RemoveForeignKeyFromInstallmentPlanSnapshots < ActiveRecord::Migration[7.1] def change remove_foreign_key :installment_plan_snapshots, :payment_options end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20201207040118_remove_import_jobs.rb
db/migrate/20201207040118_remove_import_jobs.rb
# frozen_string_literal: true class RemoveImportJobs < ActiveRecord::Migration[6.0] def up drop_table :import_jobs end def down create_table "import_jobs", id: :integer, options: "ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci", force: :cascade do |t| t.string "import_file_url", ...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20120522211546_add_meta_to_links_and_users.rb
db/migrate/20120522211546_add_meta_to_links_and_users.rb
# frozen_string_literal: true class AddMetaToLinksAndUsers < ActiveRecord::Migration def up add_column :links, :preview_meta, :string add_column :links, :attachment_meta, :string add_column :users, :profile_meta, :string end def down remove_column :links, :preview_meta remove_column :links, ...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20210622064046_remove_unused_columns_from_preorder_links.rb
db/migrate/20210622064046_remove_unused_columns_from_preorder_links.rb
# frozen_string_literal: true class RemoveUnusedColumnsFromPreorderLinks < ActiveRecord::Migration[6.1] def up change_table :preorder_links, bulk: true do |t| t.remove :attachment_guid t.change :id, :bigint, null: false, unique: true, auto_increment: true t.change :link_id, :bigint end en...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20230316123640_add_flags_to_subscription_plan_changes.rb
db/migrate/20230316123640_add_flags_to_subscription_plan_changes.rb
# frozen_string_literal: true class AddFlagsToSubscriptionPlanChanges < ActiveRecord::Migration[7.0] def change add_column :subscription_plan_changes, :flags, :bigint, default: 0, null: false end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20150202000000_create_merchant_account.rb
db/migrate/20150202000000_create_merchant_account.rb
# frozen_string_literal: true class CreateMerchantAccount < ActiveRecord::Migration def up create_table :merchant_accounts, options: "DEFAULT CHARACTER SET=utf8 COLLATE=utf8_unicode_ci" do |t| t.references :user t.string :acquirer_id t.string :acquirer_merchant_id t.string :charge_process...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20190910183250_create_friendly_id_slugs.rb
db/migrate/20190910183250_create_friendly_id_slugs.rb
# frozen_string_literal: true class CreateFriendlyIdSlugs < ActiveRecord::Migration def change create_table :friendly_id_slugs do |t| t.string :slug, null: false t.integer :sluggable_id, null: false t.string :sluggable_type, limit: 50 t.string :scope t.datetime :c...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20240717232811_add_index_on_carts_order_id.rb
db/migrate/20240717232811_add_index_on_carts_order_id.rb
# frozen_string_literal: true class AddIndexOnCartsOrderId < ActiveRecord::Migration[7.1] def change add_index :carts, :order_id end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20131105221317_add_affiliate_credit_cents_to_purchase.rb
db/migrate/20131105221317_add_affiliate_credit_cents_to_purchase.rb
# frozen_string_literal: true class AddAffiliateCreditCentsToPurchase < ActiveRecord::Migration def change add_column :purchases, :affiliate_credit_cents, :integer, default: 0 end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20130531183449_add_email_to_follows.rb
db/migrate/20130531183449_add_email_to_follows.rb
# frozen_string_literal: true class AddEmailToFollows < ActiveRecord::Migration def change add_column :follows, :email, :string end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20130722063333_drop_index_on_purchase_state.rb
db/migrate/20130722063333_drop_index_on_purchase_state.rb
# frozen_string_literal: true class DropIndexOnPurchaseState < ActiveRecord::Migration def change remove_index :purchases, name: "index_purchases_on_purchase_state" end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20230125154843_create_upsells.rb
db/migrate/20230125154843_create_upsells.rb
# frozen_string_literal: true class CreateUpsells < ActiveRecord::Migration[7.0] def change create_table :upsells do |t| t.references :seller, null: false t.references :offered_product, null: false t.references :offered_variant t.references :offer_code t.string :name, null: false ...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20130324192344_add_admin_meta_data_to_users.rb
db/migrate/20130324192344_add_admin_meta_data_to_users.rb
# frozen_string_literal: true class AddAdminMetaDataToUsers < ActiveRecord::Migration def change add_column :users, :admin_notes, :text end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20130625000244_create_dynamic_product_page_switches.rb
db/migrate/20130625000244_create_dynamic_product_page_switches.rb
# frozen_string_literal: true class CreateDynamicProductPageSwitches < ActiveRecord::Migration def change create_table :dynamic_product_page_switches do |t| t.string :name t.integer :default_switch_value t.integer :flags, default: 0, null: false t.timestamps end end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20240227023200_index_reviews_with_messages.rb
db/migrate/20240227023200_index_reviews_with_messages.rb
# frozen_string_literal: true class IndexReviewsWithMessages < ActiveRecord::Migration[7.1] def up change_table :product_reviews, bulk: true do |t| t.change :id, :bigint, auto_increment: true, null: false t.change :purchase_id, :bigint t.change :link_id, :bigint t.boolean :has_message, nu...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20130419202455_add_preorder_id_to_credit_cards.rb
db/migrate/20130419202455_add_preorder_id_to_credit_cards.rb
# frozen_string_literal: true class AddPreorderIdToCreditCards < ActiveRecord::Migration def change add_column :credit_cards, :preorder_id, :integer add_index :credit_cards, :preorder_id end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20230404183153_remove_failed_purchases.rb
db/migrate/20230404183153_remove_failed_purchases.rb
# frozen_string_literal: true class RemoveFailedPurchases < ActiveRecord::Migration[7.0] def up drop_table :failed_purchases end def down create_table "failed_purchases", id: :integer, charset: "utf8mb4", collation: "utf8mb4_unicode_ci" do |t| t.integer "link_id" t.text "email" t.strin...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20130531172854_add_kindle_email_to_users.rb
db/migrate/20130531172854_add_kindle_email_to_users.rb
# frozen_string_literal: true class AddKindleEmailToUsers < ActiveRecord::Migration def change add_column :users, :kindle_email, :string end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20210303113039_add_last_active_sessions_invalidated_at_to_users.rb
db/migrate/20210303113039_add_last_active_sessions_invalidated_at_to_users.rb
# frozen_string_literal: true class AddLastActiveSessionsInvalidatedAtToUsers < ActiveRecord::Migration[6.1] def up # Using raw SQL due to a bug in departure gem: https://github.com/gumroad/web/pull/17299#issuecomment-786054996 execute <<~SQL ALTER TABLE users ADD COLUMN last_active_sessions_in...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20140210055049_add_imported_customer_id_to_url_redirects.rb
db/migrate/20140210055049_add_imported_customer_id_to_url_redirects.rb
# frozen_string_literal: true class AddImportedCustomerIdToUrlRedirects < ActiveRecord::Migration def change add_column :url_redirects, :imported_customer_id, :integer end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20121004174019_add_background_color_to_users.rb
db/migrate/20121004174019_add_background_color_to_users.rb
# frozen_string_literal: true class AddBackgroundColorToUsers < ActiveRecord::Migration def change add_column :users, :background_color, :string end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20230530230438_add_google_uid_to_users.rb
db/migrate/20230530230438_add_google_uid_to_users.rb
# frozen_string_literal: true class AddGoogleUidToUsers < ActiveRecord::Migration[7.0] def up change_table :users, bulk: true do |t| t.string :google_uid, index: true end end def down remove_index :users, :google_uid remove_column :users, :google_uid, :string end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20201001091435_create_link_view_events.rb
db/migrate/20201001091435_create_link_view_events.rb
# frozen_string_literal: true class CreateLinkViewEvents < ActiveRecord::Migration[6.0] def change # https://dev.mysql.com/doc/refman/5.6/en/integer-types.html starting_id = 2147483648 # INT maximum value signed + 1 create_table "link_view_events", options: "ENGINE=InnoDB AUTO_INCREMENT=#{starting_id} DE...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20111212222310_absorb_user.rb
db/migrate/20111212222310_absorb_user.rb
# frozen_string_literal: true class AbsorbUser < ActiveRecord::Migration def up add_column :users, :absorbed_to_user_id, :integer add_column :users, :deleted_at, :datetime end def down remove_column :users, :absorbed_to_user_id, :integer remove_column :users, :deleted_at, :datetime end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20130205235701_create_banks.rb
db/migrate/20130205235701_create_banks.rb
# frozen_string_literal: true class CreateBanks < ActiveRecord::Migration def change create_table :banks do |t| t.string :routing_number t.string :name end add_index :banks, :routing_number end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20220318214047_create_rich_contents.rb
db/migrate/20220318214047_create_rich_contents.rb
# frozen_string_literal: true class CreateRichContents < ActiveRecord::Migration[6.1] def change create_table :rich_contents do |t| t.bigint :entity_id, null: false t.string :entity_type, null: false t.json :description, null: false t.timestamps end add_index :rich_contents, [:e...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20151203173638_add_themes.rb
db/migrate/20151203173638_add_themes.rb
# frozen_string_literal: true class AddThemes < ActiveRecord::Migration def change add_column(:users, :theme, :string, limit: 100) end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20190724010533_add_gifter_email_index_on_gifts.rb
db/migrate/20190724010533_add_gifter_email_index_on_gifts.rb
# frozen_string_literal: true class AddGifterEmailIndexOnGifts < ActiveRecord::Migration def up add_index :gifts, :gifter_email end def down remove_index :gifts, :gifter_email end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20231128083139_add_flags_to_workflows.rb
db/migrate/20231128083139_add_flags_to_workflows.rb
# frozen_string_literal: true class AddFlagsToWorkflows < ActiveRecord::Migration[7.0] def change add_column :workflows, :flags, :bigint, default: 0, null: false end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20210923103544_create_taxonomies.rb
db/migrate/20210923103544_create_taxonomies.rb
# frozen_string_literal: true class CreateTaxonomies < ActiveRecord::Migration[6.1] def change create_table :taxonomies do |t| t.string :name, null: false t.bigint :parent_id, index: true end end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20150525200251_create_payment_options.rb
db/migrate/20150525200251_create_payment_options.rb
# frozen_string_literal: true class CreatePaymentOptions < ActiveRecord::Migration def change create_table :payment_options, options: "DEFAULT CHARACTER SET=utf8 COLLATE=utf8_unicode_ci" do |t| t.references :subscription t.references :price t.timestamps t.datetime :deleted_at t.int...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20190906151752_create_profile_tags.rb
db/migrate/20190906151752_create_profile_tags.rb
# frozen_string_literal: true class CreateProfileTags < ActiveRecord::Migration def change create_table :profile_tags do |t| t.references :user, null: false, foreign_key: { on_delete: :cascade } t.references :tag, null: false, foreign_key: { on_delete: :cascade } t.boolean :active, default: tru...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20240726164920_add_affiliate_credit_fee_cents_to_purchases_index.rb
db/migrate/20240726164920_add_affiliate_credit_fee_cents_to_purchases_index.rb
# frozen_string_literal: true class AddAffiliateCreditFeeCentsToPurchasesIndex < ActiveRecord::Migration[7.1] def up EsClient.indices.put_mapping( index: Purchase.index_name, body: { properties: { affiliate_credit_fee_cents: { type: "long" }, } } ) end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20120322233754_add_webhook_to_links.rb
db/migrate/20120322233754_add_webhook_to_links.rb
# frozen_string_literal: true class AddWebhookToLinks < ActiveRecord::Migration def change add_column :links, :webhook, :boolean end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20241209191839_update_refund_policies.rb
db/migrate/20241209191839_update_refund_policies.rb
# frozen_string_literal: true class UpdateRefundPolicies < ActiveRecord::Migration[7.1] def up add_column :refund_policies, :max_refund_period_in_days, :integer change_column_null :refund_policies, :title, true change_column_null :refund_policies, :product_id, true end def down remove_column :re...
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20170405111708_add_disabled_at_to_licenses.rb
db/migrate/20170405111708_add_disabled_at_to_licenses.rb
# frozen_string_literal: true class AddDisabledAtToLicenses < ActiveRecord::Migration def change add_column :licenses, :disabled_at, :datetime end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false
antiwork/gumroad
https://github.com/antiwork/gumroad/blob/638f6c3a40b23b907c09f6881d4df18339da069c/db/migrate/20151109202709_add_humanized_name_and_flag_to_tags.rb
db/migrate/20151109202709_add_humanized_name_and_flag_to_tags.rb
# frozen_string_literal: true class AddHumanizedNameAndFlagToTags < ActiveRecord::Migration def change add_column(:tags, :humanized_name, :string, length: 100) add_column(:tags, :flagged_at, :datetime, default: nil) end end
ruby
MIT
638f6c3a40b23b907c09f6881d4df18339da069c
2026-01-04T15:39:11.815677Z
false