# HG changeset patch # User nanaya # Date 1544376908 -32400 # Node ID 4608d12ebe030d9c947df949a27c1e589a40c2a4 # Parent e8d6c631a55b51c6619ae1d626e486cd6bcc8966 Sync database diff -r e8d6c631a55b -r 4608d12ebe03 db/migrate/20120826180414_create_pastes.rb --- a/db/migrate/20120826180414_create_pastes.rb Sun Dec 09 03:15:59 2018 +0900 +++ b/db/migrate/20120826180414_create_pastes.rb Mon Dec 10 02:35:08 2018 +0900 @@ -1,5 +1,5 @@ # Create basic table. -class CreatePastes < ActiveRecord::Migration +class CreatePastes < ActiveRecord::Migration[4.2] def change create_table :pastes do |t| t.string :ip, :null => false diff -r e8d6c631a55b -r 4608d12ebe03 db/migrate/20120826182012_change_column_name_to_conform_ar.rb --- a/db/migrate/20120826182012_change_column_name_to_conform_ar.rb Sun Dec 09 03:15:59 2018 +0900 +++ b/db/migrate/20120826182012_change_column_name_to_conform_ar.rb Mon Dec 10 02:35:08 2018 +0900 @@ -1,5 +1,5 @@ # Hash shouldn't be used as column name. -class ChangeColumnNameToConformAr < ActiveRecord::Migration +class ChangeColumnNameToConformAr < ActiveRecord::Migration[4.2] def change rename_column :pastes, :hash, :paste_hash end diff -r e8d6c631a55b -r 4608d12ebe03 db/migrate/20120905072325_set_limit_on_paste.rb --- a/db/migrate/20120905072325_set_limit_on_paste.rb Sun Dec 09 03:15:59 2018 +0900 +++ b/db/migrate/20120905072325_set_limit_on_paste.rb Mon Dec 10 02:35:08 2018 +0900 @@ -1,5 +1,5 @@ # Reduced size as needed. -class SetLimitOnPaste < ActiveRecord::Migration +class SetLimitOnPaste < ActiveRecord::Migration[4.2] def change change_table :pastes do |t| t.change :ip, :string, :limit => 50 diff -r e8d6c631a55b -r 4608d12ebe03 db/migrate/20120905074204_return_not_null_to_paste.rb --- a/db/migrate/20120905074204_return_not_null_to_paste.rb Sun Dec 09 03:15:59 2018 +0900 +++ b/db/migrate/20120905074204_return_not_null_to_paste.rb Mon Dec 10 02:35:08 2018 +0900 @@ -1,5 +1,5 @@ # Add constraints. -class ReturnNotNullToPaste < ActiveRecord::Migration +class ReturnNotNullToPaste < ActiveRecord::Migration[4.2] def change change_table :pastes do |t| t.change :ip, :string, :limit => 50, :null => false diff -r e8d6c631a55b -r 4608d12ebe03 db/migrate/20130201150322_add_key_to_paste.rb --- a/db/migrate/20130201150322_add_key_to_paste.rb Sun Dec 09 03:15:59 2018 +0900 +++ b/db/migrate/20130201150322_add_key_to_paste.rb Mon Dec 10 02:35:08 2018 +0900 @@ -1,5 +1,5 @@ # For deletion. -class AddKeyToPaste < ActiveRecord::Migration +class AddKeyToPaste < ActiveRecord::Migration[4.2] def change add_column :pastes, :key, :string end diff -r e8d6c631a55b -r 4608d12ebe03 db/migrate/20130511133450_add_secret_to_pastes.rb --- a/db/migrate/20130511133450_add_secret_to_pastes.rb Sun Dec 09 03:15:59 2018 +0900 +++ b/db/migrate/20130511133450_add_secret_to_pastes.rb Mon Dec 10 02:35:08 2018 +0900 @@ -1,5 +1,5 @@ # Private paste column. -class AddSecretToPastes < ActiveRecord::Migration +class AddSecretToPastes < ActiveRecord::Migration[4.2] def change add_column :pastes, :secret, :string end diff -r e8d6c631a55b -r 4608d12ebe03 db/migrate/20130512032335_add_index_to_pastes_secret.rb --- a/db/migrate/20130512032335_add_index_to_pastes_secret.rb Sun Dec 09 03:15:59 2018 +0900 +++ b/db/migrate/20130512032335_add_index_to_pastes_secret.rb Mon Dec 10 02:35:08 2018 +0900 @@ -1,5 +1,5 @@ # Speed up lookup. -class AddIndexToPastesSecret < ActiveRecord::Migration +class AddIndexToPastesSecret < ActiveRecord::Migration[4.2] def change add_index :pastes, :secret end diff -r e8d6c631a55b -r 4608d12ebe03 db/migrate/20150914054154_add_language_to_paste.rb --- a/db/migrate/20150914054154_add_language_to_paste.rb Sun Dec 09 03:15:59 2018 +0900 +++ b/db/migrate/20150914054154_add_language_to_paste.rb Mon Dec 10 02:35:08 2018 +0900 @@ -1,4 +1,4 @@ -class AddLanguageToPaste < ActiveRecord::Migration +class AddLanguageToPaste < ActiveRecord::Migration[4.2] def change add_column :pastes, :language, :string end diff -r e8d6c631a55b -r 4608d12ebe03 db/migrate/20150916161622_strict_character_lengths.rb --- a/db/migrate/20150916161622_strict_character_lengths.rb Sun Dec 09 03:15:59 2018 +0900 +++ b/db/migrate/20150916161622_strict_character_lengths.rb Mon Dec 10 02:35:08 2018 +0900 @@ -1,4 +1,4 @@ -class StrictCharacterLengths < ActiveRecord::Migration +class StrictCharacterLengths < ActiveRecord::Migration[4.2] def change change_table :pastes do |t| t.change :key, :string, :limit => 100 diff -r e8d6c631a55b -r 4608d12ebe03 db/structure.sql --- a/db/structure.sql Sun Dec 09 03:15:59 2018 +0900 +++ b/db/structure.sql Mon Dec 10 02:35:08 2018 +0900 @@ -8,34 +8,6 @@ SET client_min_messages = warning; SET row_security = off; --- --- Name: plpgsql; Type: EXTENSION; Schema: -; Owner: - --- - -CREATE EXTENSION IF NOT EXISTS plpgsql WITH SCHEMA pg_catalog; - - --- --- Name: EXTENSION plpgsql; Type: COMMENT; Schema: -; Owner: - --- - -COMMENT ON EXTENSION plpgsql IS 'PL/pgSQL procedural language'; - - --- --- Name: hstore; Type: EXTENSION; Schema: -; Owner: - --- - -CREATE EXTENSION IF NOT EXISTS hstore WITH SCHEMA public; - - --- --- Name: EXTENSION hstore; Type: COMMENT; Schema: -; Owner: - --- - -COMMENT ON EXTENSION hstore IS 'data type for storing sets of (key, value) pairs'; - - SET default_tablespace = ''; SET default_with_oids = false; @@ -61,8 +33,8 @@ ip character varying(50) NOT NULL, paste text NOT NULL, paste_hash character varying(150) NOT NULL, - created_at timestamp with time zone NOT NULL, - updated_at timestamp with time zone NOT NULL, + created_at timestamp with time zone, + updated_at timestamp with time zone, key character varying(100), secret character varying(100), language character varying(100) @@ -130,10 +102,10 @@ -- --- Name: index_pastes_on_ip_and_hash; Type: INDEX; Schema: public; Owner: - +-- Name: index_pastes_on_ip_and_paste_hash; Type: INDEX; Schema: public; Owner: - -- -CREATE UNIQUE INDEX index_pastes_on_ip_and_hash ON public.pastes USING btree (ip, paste_hash); +CREATE UNIQUE INDEX index_pastes_on_ip_and_paste_hash ON public.pastes USING btree (ip, paste_hash); --