cmor_files 0.0.1.pre
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/MIT-LICENSE +20 -0
- data/README.md +44 -0
- data/Rakefile +19 -0
- data/app/assets/config/cmor_files_manifest.js +2 -0
- data/app/assets/javascripts/cmor/files/application/keep.js +0 -0
- data/app/assets/javascripts/cmor/files/application.js +14 -0
- data/app/assets/stylesheets/cmor/files/application/keep.css +0 -0
- data/app/assets/stylesheets/cmor/files/application.css +15 -0
- data/app/controllers/cmor/files/application_controller.rb +5 -0
- data/app/controllers/cmor/files/application_resources_controller.rb +18 -0
- data/app/controllers/cmor/files/folders_controller.rb +19 -0
- data/app/helpers/cmor/files/application_helper.rb +4 -0
- data/app/jobs/cmor/files/application_job.rb +4 -0
- data/app/mailers/cmor/files/application_mailer.rb +6 -0
- data/app/models/cmor/files/application_record.rb +5 -0
- data/app/models/cmor/files/file_detail.rb +6 -0
- data/app/models/cmor/files/folder.rb +71 -0
- data/app/views/cmor/files/folders/index.haml +9 -0
- data/app/views/cmor/files/folders/show.haml +17 -0
- data/app/views/layouts/cmor/files/application.html.erb +14 -0
- data/config/initializers/assets.rb +1 -0
- data/config/initializers/i18n.rb +2 -0
- data/config/locales/de.yml +44 -0
- data/config/locales/en.yml +44 -0
- data/config/routes.rb +7 -0
- data/db/migrate/20180301094240_create_cmor_files_folders.rb +11 -0
- data/db/migrate/20180302082402_create_cmor_files_file_details.rb +13 -0
- data/lib/cmor/files/configuration.rb +9 -0
- data/lib/cmor/files/engine.rb +13 -0
- data/lib/cmor/files/version.rb +7 -0
- data/lib/cmor/files.rb +10 -0
- data/lib/cmor_files.rb +6 -0
- data/lib/generators/cmor/files/install/install_generator.rb +24 -0
- data/lib/generators/cmor/files/install/templates/initializer.rb +7 -0
- data/lib/generators/cmor/files/install/templates/routes.source +3 -0
- data/lib/tasks/cmor_files_tasks.rake +4 -0
- data/spec/config/locales/de.yml +3 -0
- data/spec/dummy/config/initializers/cmor_files.rb +7 -0
- data/spec/dummy/config/initializers/i18n.rb +2 -0
- data/spec/dummy/db/development.sqlite3 +0 -0
- data/spec/dummy/db/migrate/20190325174535_create_active_storage_tables.active_storage.rb +27 -0
- data/spec/dummy/db/migrate/20190325174557_create_cmor_files_folders.cmor_files.rb +12 -0
- data/spec/dummy/db/migrate/20190325174558_create_cmor_files_file_details.cmor_files.rb +14 -0
- data/spec/dummy/db/test.sqlite3 +0 -0
- data/spec/dummy/log/development.log +122 -0
- data/spec/dummy/log/test.log +143 -0
- data/spec/dummy/tmp/development_secret.txt +1 -0
- data/spec/dummy/tmp/storage/Bh/RE/BhREgVesQFJGKZawuwybEm9o +0 -0
- data/spec/dummy/tmp/storage/x9/kn/x9knsAYKxaGksCFoE1kksZUn +0 -0
- data/spec/dummy~/Rakefile +6 -0
- data/spec/dummy~/app/assets/config/manifest.js +4 -0
- data/spec/dummy~/app/assets/javascripts/application.js +14 -0
- data/spec/dummy~/app/assets/javascripts/cable.js +13 -0
- data/spec/dummy~/app/assets/stylesheets/application.css +15 -0
- data/spec/dummy~/app/channels/application_cable/channel.rb +4 -0
- data/spec/dummy~/app/channels/application_cable/connection.rb +4 -0
- data/spec/dummy~/app/controllers/application_controller.rb +2 -0
- data/spec/dummy~/app/helpers/application_helper.rb +2 -0
- data/spec/dummy~/app/jobs/application_job.rb +2 -0
- data/spec/dummy~/app/mailers/application_mailer.rb +4 -0
- data/spec/dummy~/app/models/application_record.rb +3 -0
- data/spec/dummy~/app/views/layouts/application.html.erb +14 -0
- data/spec/dummy~/app/views/layouts/mailer.html.erb +13 -0
- data/spec/dummy~/app/views/layouts/mailer.text.erb +1 -0
- data/spec/dummy~/bin/bundle +3 -0
- data/spec/dummy~/bin/rails +4 -0
- data/spec/dummy~/bin/rake +4 -0
- data/spec/dummy~/bin/setup +36 -0
- data/spec/dummy~/bin/update +31 -0
- data/spec/dummy~/bin/yarn +11 -0
- data/spec/dummy~/config/application.rb +30 -0
- data/spec/dummy~/config/boot.rb +5 -0
- data/spec/dummy~/config/cable.yml +10 -0
- data/spec/dummy~/config/database.yml +25 -0
- data/spec/dummy~/config/environment.rb +5 -0
- data/spec/dummy~/config/environments/development.rb +61 -0
- data/spec/dummy~/config/environments/production.rb +94 -0
- data/spec/dummy~/config/environments/test.rb +46 -0
- data/spec/dummy~/config/initializers/application_controller_renderer.rb +8 -0
- data/spec/dummy~/config/initializers/assets.rb +14 -0
- data/spec/dummy~/config/initializers/backtrace_silencers.rb +7 -0
- data/spec/dummy~/config/initializers/cmor/files.rb +7 -0
- data/spec/dummy~/config/initializers/content_security_policy.rb +22 -0
- data/spec/dummy~/config/initializers/cookies_serializer.rb +5 -0
- data/spec/dummy~/config/initializers/filter_parameter_logging.rb +4 -0
- data/spec/dummy~/config/initializers/inflections.rb +16 -0
- data/spec/dummy~/config/initializers/mime_types.rb +4 -0
- data/spec/dummy~/config/initializers/wrap_parameters.rb +14 -0
- data/spec/dummy~/config/locales/en.yml +33 -0
- data/spec/dummy~/config/puma.rb +34 -0
- data/spec/dummy~/config/routes.rb +3 -0
- data/spec/dummy~/config/spring.rb +6 -0
- data/spec/dummy~/config/storage.yml +35 -0
- data/spec/dummy~/config.ru +5 -0
- data/spec/dummy~/db/development.sqlite3 +0 -0
- data/spec/dummy~/db/schema.rb +41 -0
- data/spec/dummy~/db/test.sqlite3 +0 -0
- data/spec/dummy~/log/test.log +0 -0
- data/spec/dummy~/package.json +5 -0
- data/spec/dummy~/public/404.html +67 -0
- data/spec/dummy~/public/422.html +67 -0
- data/spec/dummy~/public/500.html +66 -0
- data/spec/dummy~/public/apple-touch-icon-precomposed.png +0 -0
- data/spec/dummy~/public/apple-touch-icon.png +0 -0
- data/spec/dummy~/public/favicon.ico +0 -0
- data/spec/factories/cmor_files_file_details.rb +17 -0
- data/spec/factories/cmor_files_folders.rb +5 -0
- data/spec/files/cmor/files/file_details/example.png +0 -0
- data/spec/models/cmor/files/file_detail_spec.rb +7 -0
- data/spec/models/cmor/files/folder_spec.rb +12 -0
- data/spec/models/generic_spec.rb +50 -0
- data/spec/models/i18n_spec.rb +41 -0
- data/spec/rails_helper.rb +62 -0
- data/spec/spec_helper.rb +96 -0
- data/spec/support/capybara.rb +1 -0
- data/spec/support/factory_bot.rb +5 -0
- data/spec/support/rao-shoulda_matchers.rb +5 -0
- data/spec/support/shoulda_matchers.rb +8 -0
- metadata +469 -0
@@ -0,0 +1,122 @@
|
|
1
|
+
[1m[35m (0.1ms)[0m [1m[34mSELECT sqlite_version(*)[0m
|
2
|
+
↳ bin/rails:4
|
3
|
+
[1m[35m (7.6ms)[0m [1m[35mCREATE TABLE "schema_migrations" ("version" varchar NOT NULL PRIMARY KEY)[0m
|
4
|
+
↳ bin/rails:4
|
5
|
+
[1m[35m (11.2ms)[0m [1m[35mCREATE TABLE "ar_internal_metadata" ("key" varchar NOT NULL PRIMARY KEY, "value" varchar, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)[0m
|
6
|
+
↳ bin/rails:4
|
7
|
+
[1m[35m (0.5ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
8
|
+
↳ bin/rails:4
|
9
|
+
Migrating to CreateActiveStorageTables (20190325174535)
|
10
|
+
[1m[35m (0.2ms)[0m [1m[36mbegin transaction[0m
|
11
|
+
↳ bin/rails:4
|
12
|
+
[1m[35m (1.5ms)[0m [1m[35mCREATE TABLE "active_storage_blobs" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "key" varchar NOT NULL, "filename" varchar NOT NULL, "content_type" varchar, "metadata" text, "byte_size" bigint NOT NULL, "checksum" varchar NOT NULL, "created_at" datetime NOT NULL)[0m
|
13
|
+
↳ db/migrate/20190325174535_create_active_storage_tables.active_storage.rb:4
|
14
|
+
[1m[35m (0.4ms)[0m [1m[35mCREATE UNIQUE INDEX "index_active_storage_blobs_on_key" ON "active_storage_blobs" ("key")[0m
|
15
|
+
↳ db/migrate/20190325174535_create_active_storage_tables.active_storage.rb:4
|
16
|
+
[1m[35m (0.4ms)[0m [1m[35mCREATE TABLE "active_storage_attachments" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar NOT NULL, "record_type" varchar NOT NULL, "record_id" integer NOT NULL, "blob_id" integer NOT NULL, "created_at" datetime NOT NULL, CONSTRAINT "fk_rails_c3b3935057"
|
17
|
+
FOREIGN KEY ("blob_id")
|
18
|
+
REFERENCES "active_storage_blobs" ("id")
|
19
|
+
)[0m
|
20
|
+
↳ db/migrate/20190325174535_create_active_storage_tables.active_storage.rb:16
|
21
|
+
[1m[35m (0.2ms)[0m [1m[35mCREATE INDEX "index_active_storage_attachments_on_blob_id" ON "active_storage_attachments" ("blob_id")[0m
|
22
|
+
↳ db/migrate/20190325174535_create_active_storage_tables.active_storage.rb:16
|
23
|
+
[1m[35m (0.4ms)[0m [1m[35mCREATE UNIQUE INDEX "index_active_storage_attachments_uniqueness" ON "active_storage_attachments" ("record_type", "record_id", "name", "blob_id")[0m
|
24
|
+
↳ db/migrate/20190325174535_create_active_storage_tables.active_storage.rb:16
|
25
|
+
[1m[36mActiveRecord::SchemaMigration Create (0.4ms)[0m [1m[32mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "20190325174535"]]
|
26
|
+
↳ bin/rails:4
|
27
|
+
[1m[35m (13.1ms)[0m [1m[36mcommit transaction[0m
|
28
|
+
↳ bin/rails:4
|
29
|
+
Migrating to CreateCmorFilesFolders (20190325174557)
|
30
|
+
[1m[35m (0.3ms)[0m [1m[36mbegin transaction[0m
|
31
|
+
↳ bin/rails:4
|
32
|
+
[1m[35m (1.5ms)[0m [1m[35mCREATE TABLE "cmor_files_folders" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "published_at" datetime, "description" text, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)[0m
|
33
|
+
↳ db/migrate/20190325174557_create_cmor_files_folders.cmor_files.rb:4
|
34
|
+
[1m[36mActiveRecord::SchemaMigration Create (0.7ms)[0m [1m[32mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "20190325174557"]]
|
35
|
+
↳ bin/rails:4
|
36
|
+
[1m[35m (26.0ms)[0m [1m[36mcommit transaction[0m
|
37
|
+
↳ bin/rails:4
|
38
|
+
Migrating to CreateCmorFilesFileDetails (20190325174558)
|
39
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
40
|
+
↳ bin/rails:4
|
41
|
+
[1m[35m (1.0ms)[0m [1m[35mCREATE TABLE "cmor_files_file_details" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "folder_id" integer, "asset_id" integer, "title" varchar, "description" text, "position" integer, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)[0m
|
42
|
+
↳ db/migrate/20190325174558_create_cmor_files_file_details.cmor_files.rb:4
|
43
|
+
[1m[36mActiveRecord::SchemaMigration Create (0.3ms)[0m [1m[32mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "20190325174558"]]
|
44
|
+
↳ bin/rails:4
|
45
|
+
[1m[35m (5.7ms)[0m [1m[36mcommit transaction[0m
|
46
|
+
↳ bin/rails:4
|
47
|
+
[1m[36mActiveRecord::InternalMetadata Load (0.4ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
|
48
|
+
↳ bin/rails:4
|
49
|
+
[1m[35m (0.4ms)[0m [1m[36mbegin transaction[0m
|
50
|
+
↳ bin/rails:4
|
51
|
+
[1m[36mActiveRecord::InternalMetadata Create (0.8ms)[0m [1m[32mINSERT INTO "ar_internal_metadata" ("key", "value", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["key", "environment"], ["value", "development"], ["created_at", "2019-03-25 17:45:57.917361"], ["updated_at", "2019-03-25 17:45:57.917361"]]
|
52
|
+
↳ bin/rails:4
|
53
|
+
[1m[35m (16.7ms)[0m [1m[36mcommit transaction[0m
|
54
|
+
↳ bin/rails:4
|
55
|
+
[1m[35m (0.3ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
56
|
+
↳ bin/rails:4
|
57
|
+
[1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
58
|
+
↳ bin/rails:4
|
59
|
+
[1m[35m (0.2ms)[0m [1m[34mSELECT "ar_internal_metadata"."value" FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ?[0m [["key", "environment"]]
|
60
|
+
↳ bin/rails:4
|
61
|
+
[1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
62
|
+
↳ bin/rails:4
|
63
|
+
[1m[35m (0.1ms)[0m [1m[34mSELECT "ar_internal_metadata"."value" FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ?[0m [["key", "environment"]]
|
64
|
+
↳ bin/rails:4
|
65
|
+
[1m[35m (0.3ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
66
|
+
↳ bin/rails:4
|
67
|
+
[1m[35m (0.2ms)[0m [1m[34mSELECT "ar_internal_metadata"."value" FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ?[0m [["key", "environment"]]
|
68
|
+
↳ bin/rails:4
|
69
|
+
[1m[35m (1.0ms)[0m [1m[35mDROP TABLE IF EXISTS "active_storage_attachments"[0m
|
70
|
+
↳ db/schema.rb:15
|
71
|
+
[1m[35m (0.2ms)[0m [1m[34mSELECT sqlite_version(*)[0m
|
72
|
+
↳ db/schema.rb:15
|
73
|
+
[1m[35m (6.2ms)[0m [1m[35mCREATE TABLE "active_storage_attachments" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar NOT NULL, "record_type" varchar NOT NULL, "record_id" integer NOT NULL, "blob_id" integer NOT NULL, "created_at" datetime NOT NULL)[0m
|
74
|
+
↳ db/schema.rb:15
|
75
|
+
[1m[35m (5.1ms)[0m [1m[35mCREATE INDEX "index_active_storage_attachments_on_blob_id" ON "active_storage_attachments" ("blob_id")[0m
|
76
|
+
↳ db/schema.rb:15
|
77
|
+
[1m[35m (4.8ms)[0m [1m[35mCREATE UNIQUE INDEX "index_active_storage_attachments_uniqueness" ON "active_storage_attachments" ("record_type", "record_id", "name", "blob_id")[0m
|
78
|
+
↳ db/schema.rb:15
|
79
|
+
[1m[35m (0.9ms)[0m [1m[35mDROP TABLE IF EXISTS "active_storage_blobs"[0m
|
80
|
+
↳ db/schema.rb:25
|
81
|
+
[1m[35m (6.0ms)[0m [1m[35mCREATE TABLE "active_storage_blobs" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "key" varchar NOT NULL, "filename" varchar NOT NULL, "content_type" varchar, "metadata" text, "byte_size" bigint NOT NULL, "checksum" varchar NOT NULL, "created_at" datetime NOT NULL)[0m
|
82
|
+
↳ db/schema.rb:25
|
83
|
+
[1m[35m (21.9ms)[0m [1m[35mCREATE UNIQUE INDEX "index_active_storage_blobs_on_key" ON "active_storage_blobs" ("key")[0m
|
84
|
+
↳ db/schema.rb:25
|
85
|
+
[1m[35m (0.3ms)[0m [1m[35mDROP TABLE IF EXISTS "cmor_files_file_details"[0m
|
86
|
+
↳ db/schema.rb:36
|
87
|
+
[1m[35m (29.1ms)[0m [1m[35mCREATE TABLE "cmor_files_file_details" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "folder_id" integer, "asset_id" integer, "title" varchar, "description" text, "position" integer, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)[0m
|
88
|
+
↳ db/schema.rb:36
|
89
|
+
[1m[35m (0.2ms)[0m [1m[35mDROP TABLE IF EXISTS "cmor_files_folders"[0m
|
90
|
+
↳ db/schema.rb:46
|
91
|
+
[1m[35m (26.5ms)[0m [1m[35mCREATE TABLE "cmor_files_folders" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "published_at" datetime, "description" text, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)[0m
|
92
|
+
↳ db/schema.rb:46
|
93
|
+
[1m[35m (6.2ms)[0m [1m[35mCREATE TABLE "schema_migrations" ("version" varchar NOT NULL PRIMARY KEY)[0m
|
94
|
+
↳ db/schema.rb:13
|
95
|
+
[1m[35m (0.4ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
96
|
+
↳ db/schema.rb:13
|
97
|
+
[1m[35m (4.9ms)[0m [1m[32mINSERT INTO "schema_migrations" (version) VALUES (20190325174558)[0m
|
98
|
+
↳ db/schema.rb:13
|
99
|
+
[1m[35m (5.2ms)[0m [1m[32mINSERT INTO "schema_migrations" (version) VALUES
|
100
|
+
(20190325174557),
|
101
|
+
(20190325174535);
|
102
|
+
|
103
|
+
[0m
|
104
|
+
↳ db/schema.rb:13
|
105
|
+
[1m[35m (5.7ms)[0m [1m[35mCREATE TABLE "ar_internal_metadata" ("key" varchar NOT NULL PRIMARY KEY, "value" varchar, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)[0m
|
106
|
+
↳ db/schema.rb:13
|
107
|
+
[1m[36mActiveRecord::InternalMetadata Load (0.5ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
|
108
|
+
↳ db/schema.rb:13
|
109
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
110
|
+
↳ db/schema.rb:13
|
111
|
+
[1m[36mActiveRecord::InternalMetadata Create (0.3ms)[0m [1m[32mINSERT INTO "ar_internal_metadata" ("key", "value", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["key", "environment"], ["value", "development"], ["created_at", "2019-03-25 17:45:58.135166"], ["updated_at", "2019-03-25 17:45:58.135166"]]
|
112
|
+
↳ db/schema.rb:13
|
113
|
+
[1m[35m (5.8ms)[0m [1m[36mcommit transaction[0m
|
114
|
+
↳ db/schema.rb:13
|
115
|
+
[1m[36mActiveRecord::InternalMetadata Load (0.2ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
|
116
|
+
↳ bin/rails:4
|
117
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
118
|
+
↳ bin/rails:4
|
119
|
+
[1m[36mActiveRecord::InternalMetadata Update (0.4ms)[0m [1m[33mUPDATE "ar_internal_metadata" SET "value" = ?, "updated_at" = ? WHERE "ar_internal_metadata"."key" = ?[0m [["value", "test"], ["updated_at", "2019-03-25 17:45:58.150845"], ["key", "environment"]]
|
120
|
+
↳ bin/rails:4
|
121
|
+
[1m[35m (4.1ms)[0m [1m[36mcommit transaction[0m
|
122
|
+
↳ bin/rails:4
|
@@ -0,0 +1,143 @@
|
|
1
|
+
[1m[35m (0.2ms)[0m [1m[36mbegin transaction[0m
|
2
|
+
[1m[35m (0.2ms)[0m [1m[31mrollback transaction[0m
|
3
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
4
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
5
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
6
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
7
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
8
|
+
[1m[36mCmor::Files::Folder Exists (0.3ms)[0m [1m[34mSELECT 1 AS one FROM "cmor_files_folders" WHERE "cmor_files_folders"."name" IS NULL LIMIT ?[0m [["LIMIT", 1]]
|
9
|
+
[1m[35m (0.2ms)[0m [1m[31mrollback transaction[0m
|
10
|
+
[1m[35m (0.2ms)[0m [1m[36mbegin transaction[0m
|
11
|
+
[1m[36mCmor::Files::Folder Load (0.6ms)[0m [1m[34mSELECT "cmor_files_folders".* FROM "cmor_files_folders" ORDER BY "cmor_files_folders"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
|
12
|
+
[1m[35m (0.2ms)[0m [1m[35mSAVEPOINT active_record_1[0m
|
13
|
+
[1m[36mCmor::Files::Folder Create (0.6ms)[0m [1m[32mINSERT INTO "cmor_files_folders" ("created_at", "updated_at") VALUES (?, ?)[0m [["created_at", "2019-03-25 17:46:06.468881"], ["updated_at", "2019-03-25 17:46:06.468881"]]
|
14
|
+
[1m[35m (0.2ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
|
15
|
+
[1m[35m (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
|
16
|
+
[1m[36mCmor::Files::Folder Update (0.5ms)[0m [1m[33mUPDATE "cmor_files_folders" SET "name" = ?, "updated_at" = ? WHERE "cmor_files_folders"."id" = ?[0m [["name", "dummy value"], ["updated_at", "2019-03-25 17:46:06.473487"], ["id", 1]]
|
17
|
+
[1m[35m (0.1ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
|
18
|
+
[1m[36mCmor::Files::Folder Exists (0.5ms)[0m [1m[34mSELECT 1 AS one FROM "cmor_files_folders" WHERE "cmor_files_folders"."name" = ? LIMIT ?[0m [["name", "dummy value"], ["LIMIT", 1]]
|
19
|
+
[1m[36mCmor::Files::Folder Exists (0.5ms)[0m [1m[34mSELECT 1 AS one FROM "cmor_files_folders" WHERE "cmor_files_folders"."name" = ? LIMIT ?[0m [["name", "DUMMY VALUE"], ["LIMIT", 1]]
|
20
|
+
[1m[35m (2.6ms)[0m [1m[31mrollback transaction[0m
|
21
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
22
|
+
[1m[35m (1.1ms)[0m [1m[31mrollback transaction[0m
|
23
|
+
[1m[35m (0.2ms)[0m [1m[36mbegin transaction[0m
|
24
|
+
[1m[35m (0.8ms)[0m [1m[31mrollback transaction[0m
|
25
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
26
|
+
[1m[36mCmor::Files::Folder Exists (0.5ms)[0m [1m[34mSELECT 1 AS one FROM "cmor_files_folders" WHERE "cmor_files_folders"."name" = ? LIMIT ?[0m [["name", "Folder #1"], ["LIMIT", 1]]
|
27
|
+
[1m[35m (0.2ms)[0m [1m[31mrollback transaction[0m
|
28
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
29
|
+
[1m[36mCmor::Files::Folder Exists (0.4ms)[0m [1m[34mSELECT 1 AS one FROM "cmor_files_folders" WHERE "cmor_files_folders"."name" IS NULL LIMIT ?[0m [["LIMIT", 1]]
|
30
|
+
[1m[35m (0.0ms)[0m [1m[31mrollback transaction[0m
|
31
|
+
[1m[35m (0.3ms)[0m [1m[36mbegin transaction[0m
|
32
|
+
[1m[35m (0.2ms)[0m [1m[35mSAVEPOINT active_record_1[0m
|
33
|
+
[1m[36mCmor::Files::Folder Exists (0.4ms)[0m [1m[34mSELECT 1 AS one FROM "cmor_files_folders" WHERE "cmor_files_folders"."name" = ? LIMIT ?[0m [["name", "Folder #2"], ["LIMIT", 1]]
|
34
|
+
[1m[36mCmor::Files::Folder Create (0.3ms)[0m [1m[32mINSERT INTO "cmor_files_folders" ("name", "created_at", "updated_at") VALUES (?, ?, ?)[0m [["name", "Folder #2"], ["created_at", "2019-03-25 17:46:06.542916"], ["updated_at", "2019-03-25 17:46:06.542916"]]
|
35
|
+
[1m[35m (0.1ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
|
36
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
37
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
38
|
+
[1m[35m (0.2ms)[0m [1m[31mrollback transaction[0m
|
39
|
+
[1m[35m (0.2ms)[0m [1m[36mbegin transaction[0m
|
40
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
41
|
+
[1m[35m (0.2ms)[0m [1m[36mbegin transaction[0m
|
42
|
+
[36m Disk Storage (1.1ms) [0m[32mUploaded file to key: BhREgVesQFJGKZawuwybEm9o (checksum: PQckBuk+cVT3lBy73cnuAQ==)[0m
|
43
|
+
[1m[35m (0.2ms)[0m [1m[35mSAVEPOINT active_record_1[0m
|
44
|
+
[1m[36mActiveStorage::Blob Create (0.4ms)[0m [1m[32mINSERT INTO "active_storage_blobs" ("key", "filename", "content_type", "metadata", "byte_size", "checksum", "created_at") VALUES (?, ?, ?, ?, ?, ?, ?)[0m [["key", "BhREgVesQFJGKZawuwybEm9o"], ["filename", "example.png"], ["content_type", "image/png"], ["metadata", "{\"identified\":true}"], ["byte_size", 9691], ["checksum", "PQckBuk+cVT3lBy73cnuAQ=="], ["created_at", "2019-03-25 17:46:06.763658"]]
|
45
|
+
[1m[35m (0.1ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
|
46
|
+
[1m[35m (0.9ms)[0m [1m[31mrollback transaction[0m
|
47
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
48
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
49
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
50
|
+
[36m Disk Storage (3.7ms) [0m[32mUploaded file to key: x9knsAYKxaGksCFoE1kksZUn (checksum: PQckBuk+cVT3lBy73cnuAQ==)[0m
|
51
|
+
[1m[35m (0.2ms)[0m [1m[35mSAVEPOINT active_record_1[0m
|
52
|
+
[1m[36mActiveStorage::Blob Create (0.7ms)[0m [1m[32mINSERT INTO "active_storage_blobs" ("key", "filename", "content_type", "metadata", "byte_size", "checksum", "created_at") VALUES (?, ?, ?, ?, ?, ?, ?)[0m [["key", "x9knsAYKxaGksCFoE1kksZUn"], ["filename", "example.png"], ["content_type", "image/png"], ["metadata", "{\"identified\":true}"], ["byte_size", 9691], ["checksum", "PQckBuk+cVT3lBy73cnuAQ=="], ["created_at", "2019-03-25 17:46:06.896898"]]
|
53
|
+
[1m[35m (0.1ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
|
54
|
+
[1m[35m (1.6ms)[0m [1m[35mSAVEPOINT active_record_1[0m
|
55
|
+
[1m[36mCmor::Files::Folder Exists (0.2ms)[0m [1m[34mSELECT 1 AS one FROM "cmor_files_folders" WHERE "cmor_files_folders"."name" = ? LIMIT ?[0m [["name", "Folder #4"], ["LIMIT", 1]]
|
56
|
+
[1m[36mCmor::Files::Folder Create (0.3ms)[0m [1m[32mINSERT INTO "cmor_files_folders" ("name", "created_at", "updated_at") VALUES (?, ?, ?)[0m [["name", "Folder #4"], ["created_at", "2019-03-25 17:46:06.907880"], ["updated_at", "2019-03-25 17:46:06.907880"]]
|
57
|
+
[1m[36mActiveStorage::Attachment Create (0.4ms)[0m [1m[32mINSERT INTO "active_storage_attachments" ("name", "record_type", "record_id", "blob_id", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["name", "assets"], ["record_type", "Cmor::Files::Folder"], ["record_id", 1], ["blob_id", 1], ["created_at", "2019-03-25 17:46:06.910426"]]
|
58
|
+
[1m[36mCmor::Files::FileDetail Create (0.3ms)[0m [1m[32mINSERT INTO "cmor_files_file_details" ("folder_id", "asset_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["folder_id", 1], ["asset_id", 1], ["created_at", "2019-03-25 17:46:06.914198"], ["updated_at", "2019-03-25 17:46:06.914198"]]
|
59
|
+
[1m[36mCmor::Files::FileDetail Create (1.0ms)[0m [1m[32mINSERT INTO "cmor_files_file_details" ("folder_id", "asset_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["folder_id", 1], ["asset_id", 1], ["created_at", "2019-03-25 17:46:06.916209"], ["updated_at", "2019-03-25 17:46:06.916209"]]
|
60
|
+
[1m[36mCmor::Files::Folder Update (0.2ms)[0m [1m[33mUPDATE "cmor_files_folders" SET "updated_at" = ? WHERE "cmor_files_folders"."id" = ?[0m [["updated_at", "2019-03-25 17:46:06.913187"], ["id", 1]]
|
61
|
+
[1m[35m (0.2ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
|
62
|
+
[ActiveJob] Enqueued ActiveStorage::AnalyzeJob (Job ID: dd2d96ea-50bb-4dd3-aa3c-c65f490fa47a) to Async(default) with arguments: #<GlobalID:0x0000000007170898 @uri=#<URI::GID gid://dummy/ActiveStorage::Blob/1>>
|
63
|
+
[1m[36mActiveStorage::Blob Load (2.1ms)[0m [1m[34mSELECT "active_storage_blobs".* FROM "active_storage_blobs" WHERE "active_storage_blobs"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
|
64
|
+
[ActiveJob] [ActiveStorage::AnalyzeJob] [dd2d96ea-50bb-4dd3-aa3c-c65f490fa47a] Performing ActiveStorage::AnalyzeJob (Job ID: dd2d96ea-50bb-4dd3-aa3c-c65f490fa47a) from Async(default) with arguments: #<GlobalID:0x00000000071173d8 @uri=#<URI::GID gid://dummy/ActiveStorage::Blob/1>>
|
65
|
+
[ActiveJob] [ActiveStorage::AnalyzeJob] [dd2d96ea-50bb-4dd3-aa3c-c65f490fa47a] [36m Disk Storage (0.2ms) [0m[34mDownloaded file from key: x9knsAYKxaGksCFoE1kksZUn[0m
|
66
|
+
[ActiveJob] [ActiveStorage::AnalyzeJob] [dd2d96ea-50bb-4dd3-aa3c-c65f490fa47a] Skipping image analysis because the mini_magick gem isn't installed
|
67
|
+
[1m[35m (2.0ms)[0m [1m[31mrollback transaction[0m
|
68
|
+
[ActiveJob] [ActiveStorage::AnalyzeJob] [dd2d96ea-50bb-4dd3-aa3c-c65f490fa47a] [1m[35m (0.2ms)[0m [1m[36mbegin transaction[0m
|
69
|
+
[ActiveJob] [ActiveStorage::AnalyzeJob] [dd2d96ea-50bb-4dd3-aa3c-c65f490fa47a] [1m[36mActiveStorage::Blob Update (0.6ms)[0m [1m[33mUPDATE "active_storage_blobs" SET "metadata" = ? WHERE "active_storage_blobs"."id" = ?[0m [["metadata", "{\"identified\":true,\"analyzed\":true}"], ["id", 1]]
|
70
|
+
[ActiveJob] [ActiveStorage::AnalyzeJob] [dd2d96ea-50bb-4dd3-aa3c-c65f490fa47a] [1m[35m (0.2ms)[0m [1m[36mcommit transaction[0m
|
71
|
+
[ActiveJob] [ActiveStorage::AnalyzeJob] [dd2d96ea-50bb-4dd3-aa3c-c65f490fa47a] Performed ActiveStorage::AnalyzeJob (Job ID: dd2d96ea-50bb-4dd3-aa3c-c65f490fa47a) from Async(default) in 22.07ms
|
72
|
+
[1m[35m (0.4ms)[0m [1m[36mbegin transaction[0m
|
73
|
+
[1m[35m (0.2ms)[0m [1m[31mrollback transaction[0m
|
74
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
75
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
76
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
77
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
78
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
79
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
80
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
81
|
+
[1m[35m (0.4ms)[0m [1m[31mrollback transaction[0m
|
82
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
83
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
84
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
85
|
+
[1m[35m (0.2ms)[0m [1m[31mrollback transaction[0m
|
86
|
+
[1m[35m (0.3ms)[0m [1m[36mbegin transaction[0m
|
87
|
+
[1m[35m (0.3ms)[0m [1m[31mrollback transaction[0m
|
88
|
+
[1m[35m (1.3ms)[0m [1m[36mbegin transaction[0m
|
89
|
+
[1m[35m (0.3ms)[0m [1m[31mrollback transaction[0m
|
90
|
+
[1m[35m (0.3ms)[0m [1m[36mbegin transaction[0m
|
91
|
+
[1m[35m (0.2ms)[0m [1m[31mrollback transaction[0m
|
92
|
+
[1m[35m (0.3ms)[0m [1m[36mbegin transaction[0m
|
93
|
+
[1m[35m (0.3ms)[0m [1m[31mrollback transaction[0m
|
94
|
+
[1m[35m (0.4ms)[0m [1m[36mbegin transaction[0m
|
95
|
+
[1m[35m (0.2ms)[0m [1m[31mrollback transaction[0m
|
96
|
+
[1m[35m (0.2ms)[0m [1m[36mbegin transaction[0m
|
97
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
98
|
+
[1m[35m (0.3ms)[0m [1m[36mbegin transaction[0m
|
99
|
+
[1m[35m (0.2ms)[0m [1m[31mrollback transaction[0m
|
100
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
101
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
102
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
103
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
104
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
105
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
106
|
+
[1m[35m (0.2ms)[0m [1m[36mbegin transaction[0m
|
107
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
108
|
+
[1m[35m (0.3ms)[0m [1m[36mbegin transaction[0m
|
109
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
110
|
+
[1m[35m (0.3ms)[0m [1m[36mbegin transaction[0m
|
111
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
112
|
+
[1m[35m (0.2ms)[0m [1m[36mbegin transaction[0m
|
113
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
114
|
+
[1m[35m (0.2ms)[0m [1m[36mbegin transaction[0m
|
115
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
116
|
+
[1m[35m (0.3ms)[0m [1m[36mbegin transaction[0m
|
117
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
118
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
119
|
+
[1m[35m (0.2ms)[0m [1m[31mrollback transaction[0m
|
120
|
+
[1m[35m (0.2ms)[0m [1m[36mbegin transaction[0m
|
121
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
122
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
123
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
124
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
125
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
126
|
+
[1m[35m (0.2ms)[0m [1m[36mbegin transaction[0m
|
127
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
128
|
+
[1m[35m (0.2ms)[0m [1m[36mbegin transaction[0m
|
129
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
130
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
131
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
132
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
133
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
134
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
135
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
136
|
+
[1m[35m (0.2ms)[0m [1m[36mbegin transaction[0m
|
137
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
138
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
139
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
140
|
+
[1m[35m (0.1ms)[0m [1m[36mbegin transaction[0m
|
141
|
+
[1m[35m (0.1ms)[0m [1m[31mrollback transaction[0m
|
142
|
+
[1m[35m (0.6ms)[0m [1m[36mbegin transaction[0m
|
143
|
+
[1m[35m (0.3ms)[0m [1m[31mrollback transaction[0m
|
@@ -0,0 +1 @@
|
|
1
|
+
68d4bc20833fed1daf3dfa793b6eac93173618e37355acea00cb3d5641c67e435f19f37de4d8f622072acc94f949f27ab5fbd2e262e0a62ae1fd3836507c27f2
|
Binary file
|
Binary file
|
@@ -0,0 +1,14 @@
|
|
1
|
+
// This is a manifest file that'll be compiled into application.js, which will include all the files
|
2
|
+
// listed below.
|
3
|
+
//
|
4
|
+
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
|
5
|
+
// or any plugin's vendor/assets/javascripts directory can be referenced here using a relative path.
|
6
|
+
//
|
7
|
+
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
|
8
|
+
// compiled file. JavaScript code in this file should be added after the last require_* statement.
|
9
|
+
//
|
10
|
+
// Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details
|
11
|
+
// about supported directives.
|
12
|
+
//
|
13
|
+
//= require activestorage
|
14
|
+
//= require_tree .
|
@@ -0,0 +1,13 @@
|
|
1
|
+
// Action Cable provides the framework to deal with WebSockets in Rails.
|
2
|
+
// You can generate new channels where WebSocket features live using the `rails generate channel` command.
|
3
|
+
//
|
4
|
+
//= require action_cable
|
5
|
+
//= require_self
|
6
|
+
//= require_tree ./channels
|
7
|
+
|
8
|
+
(function() {
|
9
|
+
this.App || (this.App = {});
|
10
|
+
|
11
|
+
App.cable = ActionCable.createConsumer();
|
12
|
+
|
13
|
+
}).call(this);
|
@@ -0,0 +1,15 @@
|
|
1
|
+
/*
|
2
|
+
* This is a manifest file that'll be compiled into application.css, which will include all the files
|
3
|
+
* listed below.
|
4
|
+
*
|
5
|
+
* Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
|
6
|
+
* or any plugin's vendor/assets/stylesheets directory can be referenced here using a relative path.
|
7
|
+
*
|
8
|
+
* You're free to add application-wide styles to this file and they'll appear at the bottom of the
|
9
|
+
* compiled file so the styles you add here take precedence over styles defined in any other CSS/SCSS
|
10
|
+
* files in this directory. Styles in this file should be added after the last require_* statement.
|
11
|
+
* It is generally better to create a new file per style scope.
|
12
|
+
*
|
13
|
+
*= require_tree .
|
14
|
+
*= require_self
|
15
|
+
*/
|
@@ -0,0 +1 @@
|
|
1
|
+
<%= yield %>
|
@@ -0,0 +1,36 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
require 'fileutils'
|
3
|
+
include FileUtils
|
4
|
+
|
5
|
+
# path to your application root.
|
6
|
+
APP_ROOT = File.expand_path('..', __dir__)
|
7
|
+
|
8
|
+
def system!(*args)
|
9
|
+
system(*args) || abort("\n== Command #{args} failed ==")
|
10
|
+
end
|
11
|
+
|
12
|
+
chdir APP_ROOT do
|
13
|
+
# This script is a starting point to setup your application.
|
14
|
+
# Add necessary setup steps to this file.
|
15
|
+
|
16
|
+
puts '== Installing dependencies =='
|
17
|
+
system! 'gem install bundler --conservative'
|
18
|
+
system('bundle check') || system!('bundle install')
|
19
|
+
|
20
|
+
# Install JavaScript dependencies if using Yarn
|
21
|
+
# system('bin/yarn')
|
22
|
+
|
23
|
+
# puts "\n== Copying sample files =="
|
24
|
+
# unless File.exist?('config/database.yml')
|
25
|
+
# cp 'config/database.yml.sample', 'config/database.yml'
|
26
|
+
# end
|
27
|
+
|
28
|
+
puts "\n== Preparing database =="
|
29
|
+
system! 'bin/rails db:setup'
|
30
|
+
|
31
|
+
puts "\n== Removing old logs and tempfiles =="
|
32
|
+
system! 'bin/rails log:clear tmp:clear'
|
33
|
+
|
34
|
+
puts "\n== Restarting application server =="
|
35
|
+
system! 'bin/rails restart'
|
36
|
+
end
|
@@ -0,0 +1,31 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
require 'fileutils'
|
3
|
+
include FileUtils
|
4
|
+
|
5
|
+
# path to your application root.
|
6
|
+
APP_ROOT = File.expand_path('..', __dir__)
|
7
|
+
|
8
|
+
def system!(*args)
|
9
|
+
system(*args) || abort("\n== Command #{args} failed ==")
|
10
|
+
end
|
11
|
+
|
12
|
+
chdir APP_ROOT do
|
13
|
+
# This script is a way to update your development environment automatically.
|
14
|
+
# Add necessary update steps to this file.
|
15
|
+
|
16
|
+
puts '== Installing dependencies =='
|
17
|
+
system! 'gem install bundler --conservative'
|
18
|
+
system('bundle check') || system!('bundle install')
|
19
|
+
|
20
|
+
# Install JavaScript dependencies if using Yarn
|
21
|
+
# system('bin/yarn')
|
22
|
+
|
23
|
+
puts "\n== Updating database =="
|
24
|
+
system! 'bin/rails db:migrate'
|
25
|
+
|
26
|
+
puts "\n== Removing old logs and tempfiles =="
|
27
|
+
system! 'bin/rails log:clear tmp:clear'
|
28
|
+
|
29
|
+
puts "\n== Restarting application server =="
|
30
|
+
system! 'bin/rails restart'
|
31
|
+
end
|
@@ -0,0 +1,11 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
APP_ROOT = File.expand_path('..', __dir__)
|
3
|
+
Dir.chdir(APP_ROOT) do
|
4
|
+
begin
|
5
|
+
exec "yarnpkg", *ARGV
|
6
|
+
rescue Errno::ENOENT
|
7
|
+
$stderr.puts "Yarn executable was not detected in the system."
|
8
|
+
$stderr.puts "Download Yarn at https://yarnpkg.com/en/docs/install"
|
9
|
+
exit 1
|
10
|
+
end
|
11
|
+
end
|
@@ -0,0 +1,30 @@
|
|
1
|
+
require_relative 'boot'
|
2
|
+
|
3
|
+
require "rails"
|
4
|
+
# Pick the frameworks you want:
|
5
|
+
require "active_model/railtie"
|
6
|
+
require "active_job/railtie"
|
7
|
+
require "active_record/railtie"
|
8
|
+
require "active_storage/engine"
|
9
|
+
require "action_controller/railtie"
|
10
|
+
require "action_mailer/railtie"
|
11
|
+
require "action_view/railtie"
|
12
|
+
require "action_cable/engine"
|
13
|
+
require "sprockets/railtie"
|
14
|
+
# require "rails/test_unit/railtie"
|
15
|
+
|
16
|
+
Bundler.require(*Rails.groups)
|
17
|
+
require "cmor_files"
|
18
|
+
|
19
|
+
module Dummy
|
20
|
+
class Application < Rails::Application
|
21
|
+
# Initialize configuration defaults for originally generated Rails version.
|
22
|
+
config.load_defaults 5.2
|
23
|
+
|
24
|
+
# Settings in config/environments/* take precedence over those specified here.
|
25
|
+
# Application configuration can go into files in config/initializers
|
26
|
+
# -- all .rb files in that directory are automatically loaded after loading
|
27
|
+
# the framework and any gems in your application.
|
28
|
+
end
|
29
|
+
end
|
30
|
+
|
@@ -0,0 +1,25 @@
|
|
1
|
+
# SQLite version 3.x
|
2
|
+
# gem install sqlite3
|
3
|
+
#
|
4
|
+
# Ensure the SQLite 3 gem is defined in your Gemfile
|
5
|
+
# gem 'sqlite3'
|
6
|
+
#
|
7
|
+
default: &default
|
8
|
+
adapter: sqlite3
|
9
|
+
pool: <%= ENV.fetch("RAILS_MAX_THREADS") { 5 } %>
|
10
|
+
timeout: 5000
|
11
|
+
|
12
|
+
development:
|
13
|
+
<<: *default
|
14
|
+
database: db/development.sqlite3
|
15
|
+
|
16
|
+
# Warning: The database defined as "test" will be erased and
|
17
|
+
# re-generated from your development database when you run "rake".
|
18
|
+
# Do not set this db to the same as development or production.
|
19
|
+
test:
|
20
|
+
<<: *default
|
21
|
+
database: db/test.sqlite3
|
22
|
+
|
23
|
+
production:
|
24
|
+
<<: *default
|
25
|
+
database: db/production.sqlite3
|