summaryrefslogtreecommitdiff
path: root/priv
diff options
context:
space:
mode:
Diffstat (limited to 'priv')
-rw-r--r--priv/repo/migrations/20190315101315_create_registrations.exs18
-rw-r--r--priv/repo/migrations/20190325215156_update_status_reply_count.exs48
-rw-r--r--priv/repo/migrations/20190328053912_create_scheduled_activities.exs16
-rw-r--r--priv/repo/migrations/20190403131720_add_oauth_token_indexes.exs9
-rw-r--r--priv/static/images/pleroma-fox-tan-smol.pngbin0 -> 874668 bytes
-rw-r--r--priv/static/images/pleroma-fox-tan.pngbin0 -> 2044257 bytes
-rw-r--r--priv/static/images/pleroma-tan.pngbin0 -> 545742 bytes
7 files changed, 43 insertions, 48 deletions
diff --git a/priv/repo/migrations/20190315101315_create_registrations.exs b/priv/repo/migrations/20190315101315_create_registrations.exs
new file mode 100644
index 000000000..6b28cbdd3
--- /dev/null
+++ b/priv/repo/migrations/20190315101315_create_registrations.exs
@@ -0,0 +1,18 @@
+defmodule Pleroma.Repo.Migrations.CreateRegistrations do
+ use Ecto.Migration
+
+ def change do
+ create table(:registrations, primary_key: false) do
+ add :id, :uuid, primary_key: true
+ add :user_id, references(:users, type: :uuid, on_delete: :delete_all)
+ add :provider, :string
+ add :uid, :string
+ add :info, :map, default: %{}
+
+ timestamps()
+ end
+
+ create unique_index(:registrations, [:provider, :uid])
+ create unique_index(:registrations, [:user_id, :provider, :uid])
+ end
+end
diff --git a/priv/repo/migrations/20190325215156_update_status_reply_count.exs b/priv/repo/migrations/20190325215156_update_status_reply_count.exs
deleted file mode 100644
index 50f1fe10b..000000000
--- a/priv/repo/migrations/20190325215156_update_status_reply_count.exs
+++ /dev/null
@@ -1,48 +0,0 @@
-defmodule Pleroma.Repo.Migrations.UpdateStatusReplyCount do
- use Ecto.Migration
-
- @public "https://www.w3.org/ns/activitystreams#Public"
-
- def up do
- execute("""
- WITH reply_count AS (
- SELECT count(*) AS count, data->>'inReplyTo' AS ap_id
- FROM objects
- WHERE
- data->>'inReplyTo' IS NOT NULL AND
- data->>'type' = 'Note' AND (
- data->'cc' ? '#{@public}' OR
- data->'to' ? '#{@public}')
- GROUP BY data->>'inReplyTo'
- )
- UPDATE objects AS o
- SET "data" = jsonb_set(o.data, '{repliesCount}', reply_count.count::varchar::jsonb, true)
- FROM reply_count
- WHERE reply_count.ap_id = o.data->>'id';
- """)
-
- execute("""
- WITH reply_count AS (SELECT
- count(*) as count,
- data->'object'->>'inReplyTo' AS ap_id
- FROM
- activities
- WHERE
- data->'object'->>'inReplyTo' IS NOT NULL AND
- data->'object'->>'type' = 'Note' AND (
- data->'object'->'cc' ? '#{@public}' OR
- data->'object'->'to' ? '#{@public}')
- GROUP BY
- data->'object'->>'inReplyTo'
- )
- UPDATE activities AS a
- SET "data" = jsonb_set(a.data, '{object, repliesCount}', reply_count.count::varchar::jsonb, true)
- FROM reply_count
- WHERE reply_count.ap_id = a.data->'object'->>'id';
- """)
- end
-
- def down do
- :noop
- end
-end
diff --git a/priv/repo/migrations/20190328053912_create_scheduled_activities.exs b/priv/repo/migrations/20190328053912_create_scheduled_activities.exs
new file mode 100644
index 000000000..dd737e25a
--- /dev/null
+++ b/priv/repo/migrations/20190328053912_create_scheduled_activities.exs
@@ -0,0 +1,16 @@
+defmodule Pleroma.Repo.Migrations.CreateScheduledActivities do
+ use Ecto.Migration
+
+ def change do
+ create table(:scheduled_activities) do
+ add(:user_id, references(:users, type: :uuid, on_delete: :delete_all))
+ add(:scheduled_at, :naive_datetime, null: false)
+ add(:params, :map, null: false)
+
+ timestamps()
+ end
+
+ create(index(:scheduled_activities, [:scheduled_at]))
+ create(index(:scheduled_activities, [:user_id]))
+ end
+end
diff --git a/priv/repo/migrations/20190403131720_add_oauth_token_indexes.exs b/priv/repo/migrations/20190403131720_add_oauth_token_indexes.exs
new file mode 100644
index 000000000..ebcd29389
--- /dev/null
+++ b/priv/repo/migrations/20190403131720_add_oauth_token_indexes.exs
@@ -0,0 +1,9 @@
+defmodule Pleroma.Repo.Migrations.AddOauthTokenIndexes do
+ use Ecto.Migration
+
+ def change do
+ create(unique_index(:oauth_tokens, [:token]))
+ create(index(:oauth_tokens, [:app_id]))
+ create(index(:oauth_tokens, [:user_id]))
+ end
+end
diff --git a/priv/static/images/pleroma-fox-tan-smol.png b/priv/static/images/pleroma-fox-tan-smol.png
new file mode 100644
index 000000000..e944d0e2a
--- /dev/null
+++ b/priv/static/images/pleroma-fox-tan-smol.png
Binary files differ
diff --git a/priv/static/images/pleroma-fox-tan.png b/priv/static/images/pleroma-fox-tan.png
new file mode 100644
index 000000000..da0022ff2
--- /dev/null
+++ b/priv/static/images/pleroma-fox-tan.png
Binary files differ
diff --git a/priv/static/images/pleroma-tan.png b/priv/static/images/pleroma-tan.png
new file mode 100644
index 000000000..6c12c8e46
--- /dev/null
+++ b/priv/static/images/pleroma-tan.png
Binary files differ