mirror of
https://github.com/SrIzan10/hc-harbor.git
synced 2026-05-01 10:45:21 +00:00
Sync in commit data
This commit is contained in:
10
db/migrate/20250514212714_create_commits.rb
Normal file
10
db/migrate/20250514212714_create_commits.rb
Normal file
@@ -0,0 +1,10 @@
|
||||
class CreateCommits < ActiveRecord::Migration[8.0]
|
||||
def change
|
||||
create_table :commits, primary_key: :sha, id: :string do |t|
|
||||
t.references :user, null: false, foreign_key: true
|
||||
t.jsonb :github_raw
|
||||
|
||||
t.timestamps null: false
|
||||
end
|
||||
end
|
||||
end
|
||||
11
db/schema.rb
generated
11
db/schema.rb
generated
@@ -10,7 +10,7 @@
|
||||
#
|
||||
# It's strongly recommended that you check this file into your version control system.
|
||||
|
||||
ActiveRecord::Schema[8.0].define(version: 2025_05_14_180503) do
|
||||
ActiveRecord::Schema[8.0].define(version: 2025_05_14_212714) do
|
||||
create_schema "pganalyze"
|
||||
|
||||
# These are extensions that must be enabled in order to support this database
|
||||
@@ -72,6 +72,14 @@ ActiveRecord::Schema[8.0].define(version: 2025_05_14_180503) do
|
||||
t.index ["user_id"], name: "index_api_keys_on_user_id"
|
||||
end
|
||||
|
||||
create_table "commits", primary_key: "sha", id: :string, force: :cascade do |t|
|
||||
t.bigint "user_id", null: false
|
||||
t.jsonb "github_raw"
|
||||
t.datetime "created_at", null: false
|
||||
t.datetime "updated_at", null: false
|
||||
t.index ["user_id"], name: "index_commits_on_user_id"
|
||||
end
|
||||
|
||||
create_table "email_addresses", force: :cascade do |t|
|
||||
t.string "email"
|
||||
t.bigint "user_id", null: false
|
||||
@@ -389,6 +397,7 @@ ActiveRecord::Schema[8.0].define(version: 2025_05_14_180503) do
|
||||
end
|
||||
|
||||
add_foreign_key "api_keys", "users"
|
||||
add_foreign_key "commits", "users"
|
||||
add_foreign_key "email_addresses", "users"
|
||||
add_foreign_key "email_verification_requests", "users"
|
||||
add_foreign_key "heartbeats", "raw_heartbeat_uploads"
|
||||
|
||||
Reference in New Issue
Block a user