Compare commits
2 Commits
fb7f99d67b
...
8b742cfed7
Author | SHA1 | Date | |
---|---|---|---|
8b742cfed7 | |||
5a264ddf5e |
2
.bundle/config
Normal file
2
.bundle/config
Normal file
@ -0,0 +1,2 @@
|
||||
---
|
||||
BUNDLE_PATH: "vendor/bundle"
|
@ -4,4 +4,4 @@ $conf = Config.new(File.join(__dir__, 'config/defaults.yaml'))
|
||||
|
||||
root = ::File.dirname(__FILE__)
|
||||
require ::File.join( root, 'src', 'server' )
|
||||
run GameData.new
|
||||
run Destructo.new
|
||||
|
@ -2,5 +2,5 @@ database:
|
||||
adapter: 'sqlite'
|
||||
database: 'data/destructo.db'
|
||||
|
||||
testing:
|
||||
minimum_results_required: 3
|
||||
messages:
|
||||
soft_delete: false
|
||||
|
16
db/migrations/0001_add_messages_table.rb
Normal file
16
db/migrations/0001_add_messages_table.rb
Normal file
@ -0,0 +1,16 @@
|
||||
Sequel.migration do
|
||||
|
||||
up do
|
||||
create_table(:messages) do
|
||||
primary_key :id
|
||||
String :body, null: false
|
||||
DateTime :created_at, default: Sequel::CURRENT_TIMESTAMP
|
||||
DateTime :updated_at, default: Sequel::CURRENT_TIMESTAMP
|
||||
end
|
||||
end
|
||||
|
||||
down do
|
||||
drop_table(:messages)
|
||||
end
|
||||
|
||||
end
|
@ -1,3 +1,3 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
# Will add models to load here
|
||||
require_relative 'message'
|
||||
|
5
src/models/message.rb
Normal file
5
src/models/message.rb
Normal file
@ -0,0 +1,5 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
# Message - database model for messages
|
||||
class Message < Sequel::Model
|
||||
end
|
Loading…
Reference in New Issue
Block a user