Deprecated: Function get_magic_quotes_gpc() is deprecated in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 99

Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 619

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1169

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176

Warning: Cannot modify header information - headers already sent by (output started at /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php:99) in /hermes/walnacweb04/walnacweb04ab/b2791/pow.jasaeld/htdocs/De1337/nothing/index.php on line 1176
8000 Start porting to SQL by biow0lf · Pull Request #2110 · errbit/errbit · GitHub
Nothing Special   »   [go: up one dir, main page]

Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
65 commits
Select commit Hold shift + click to select a range
9b10068
First try
biow0lf Jul 18, 2025
0643318
Update
biow0lf Jul 25, 2025
39053ca
Update sqlite3 gem to 2.7.3
biow0lf Jul 25, 2025
3aed073
Extract zeitwerk to GitHub Action
biow0lf Jul 25, 2025
f1d1ce2
Update pg gem to 1.6.0
biow0lf Jul 28, 2025
6cd993b
Update pg gem to 1.6.1
biow0lf Aug 3, 2025
2ae59b4
Update pg gem to 1.6.2
biow0lf Sep 3, 2025
724f6c7
Fix
biow0lf Sep 8, 2025
7c1fe36
Update
biow0lf Sep 8, 2025
1d9f19f
Update
biow0lf Sep 8, 2025
cfc91b9
Update
biow0lf Sep 11, 2025
b34901a
Add schema
biow0lf Sep 11, 2025
0e09a2e
Update
biow0lf Sep 11, 2025
a9b6d70
Add errbit user factory
biow0lf Sep 11, 2025
fca6621
Update
biow0lf Sep 12, 2025
6033d81
Update
biow0lf Sep 12, 2025
c6b6d97
Add shoulda-matchers gem
biow0lf Sep 12, 2025
28a4d99
Configure shoulda-matchers
biow0lf Sep 12, 2025
9632d32
Update
biow0lf Sep 12, 2025
587c6e1
Fix
biow0lf Sep 12, 2025
ef250da
Fix
biow0lf Sep 12, 2025
2f4dc8c
Update
biow0lf Sep 12, 2025
029fa76
Update
biow0lf Sep 12, 2025
c9a7c4c
Update
biow0lf Sep 12, 2025
3d2f7ee
Add database_rewinder gem
biow0lf Sep 12, 2025
269d401
Configure database_rewinder gem
biow0lf Sep 12, 2025
322fb7a
Update
biow0lf Sep 12, 2025
b3580de
Update
biow0lf Sep 12, 2025
c4deb09
Update
biow0lf Sep 12, 2025
138accc
Update
biow0lf Sep 12, 2025
6cd7a2f
Update
biow0lf Sep 12, 2025
710e742
Update
biow0lf Sep 12, 2025
ba17330
Update
biow0lf Sep 12, 2025
38336aa
Update
biow0lf Sep 14, 2025
de8d2d1
Update
biow0lf Sep 14, 2025
01a0a24
Update
biow0lf Sep 14, 2025
6d286cb
Update
biow0lf Sep 14, 2025
84b4c0a
Update
biow0lf Sep 14, 2025
036751d
Update
biow0lf Sep 14, 2025
b7df3e9
Update
biow0lf Sep 15, 2025
3719644
Update
biow0lf Sep 15, 2025
7eb0f45
Fix
biow0lf Sep 17, 2025
9657664
Refactoring: rename idx to index
biow0lf Sep 17, 2025
e0a6f44
Update
biow0lf Sep 19, 2025
f96ecc7
Fix
biow0lf Sep 19, 2025
ca1bb9a
Update
biow0lf Sep 21, 2025
3105eae
Update
biow0lf Sep 21, 2025
6c5442e
Update
biow0lf Sep 21, 2025
e410011
Update
biow0lf Sep 21, 2025
6aae3d9
Update
biow0lf Sep 21, 2025
4613890
Update
biow0lf Sep 21, 2025
50f9f25
Update
biow0lf Sep 21, 2025
4487c0b
Update
biow0lf Sep 21, 2025
23d6d8d
Update
biow0lf Sep 21, 2025
d6cbed4
Update
biow0lf Sep 21, 2025
fb5bdb5
Update
biow0lf Sep 21, 2025
b038998
Update
biow0lf Sep 21, 2025
20d7af0
Update
biow0lf Sep 21, 2025
7d85997
Update
biow0lf Sep 21, 2025
7b79e14
Update
biow0lf Sep 29, 2025
04da0b2
Update
biow0lf Sep 29, 2025
bd01913
Cleanup
biow0lf Sep 29, 2025
81aea28
Update
biow0lf Sep 29, 2025
73140e9
Update
biow0lf Sep 29, 2025
5f6dc6b
Update
biow0lf Sep 29, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
8000 Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/workflows/rspec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ permissions:

env:
CI: "true"
RAILS_ENV: "test"
SE_AVOID_STATS: "true"

jobs:
Expand Down Expand Up @@ -54,5 +55,6 @@ jobs:
- run: bundle exec bootsnap precompile app/ lib/ config/ Rakefile
- run: bundle exec rails zeitwerk:check
- run: bundle exec rails assets:precompile
- run: bundle exec rails db:create db:migrate
- run: bundle exec rake errbit:bootstrap
- run: bundle exec rspec
6 changes: 6 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,10 @@ gem "bootsnap", ">= 1.4.4", require: false
gem "thruster", require: false

group :development, :test do
gem "sqlite3", ">= 2.1"
gem "pg", "~> 1.1"
gem "trilogy", "~> 2.7"

gem "airbrake", "~> 4.3.5", require: false
gem "rubocop", require: false
gem "rubocop-rails", require: false
Expand All @@ -97,6 +101,7 @@ end

group :test do
gem "rails-controller-testing"
gem "shoulda-matchers"
gem "rspec-rails", require: false
gem "rspec-retry", require: false
gem "rspec-activemodel-mocks"
Expand All @@ -111,6 +116,7 @@ group :test do
gem "super_diff"
gem "webmock"
gem "vcr"
gem "database_rewinder"
end

gem "puma"
Expand Down
49 changes: 49 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ GEM
css_parser (1.21.1)
addressable
csv (3.3.5)
database_rewinder (1.1.0)
date (3.4.1)
decent_exposure (3.0.4)
activesupport (>= 4.0)
Expand Down Expand Up @@ -373,6 +374,13 @@ GEM
racc
patience_diff (1.2.0)
optimist (~> 3.0)
pg (1.6.2)
pg (1.6.2-aarch64-linux)
pg (1.6.2-aarch64-linux-musl)
pg (1.6.2-arm64-darwin)
pg (1.6.2-x86_64-darwin)
pg (1.6.2-x86_64-linux)
pg (1.6.2-x86_64-linux-musl)
pjax_rails (0.5.1)
jquery-rails
railties (>= 4.0)
Expand Down Expand Up @@ -563,6 +571,8 @@ GEM
rexml (~> 3.2, >= 3.2.5)
rubyzip (>= 1.2.2, < 4.0)
websocket (~> 1.0)
shoulda-matchers (6.5.0)
activesupport (>= 5.2.0)
simplecov (0.22.0)
docile (~> 1.1)
simplecov-html (~> 0.11)
Expand All @@ -580,6 +590,18 @@ GEM
actionpack (>= 6.1)
activesupport (>= 6.1)
sprockets (>= 3.0.0)
sqlite3 (2.7.4)
mini_portile2 (~> 2.8.0)
sqlite3 (2.7.4-aarch64-linux-gnu)
sqlite3 (2.7.4-aarch64-linux-musl)
sqlite3 (2.7.4-arm-linux-gnu)
sqlite3 (2.7.4-arm-linux-musl)
sqlite3 (2.7.4-arm64-darwin)
sqlite3 (2.7.4-x86-linux-gnu)
sqlite3 (2.7.4-x86-linux-musl)
sqlite3 (2.7.4-x86_64-darwin)
sqlite3 (2.7.4-x86_64-linux-gnu)
sqlite3 (2.7.4-x86_64-linux-musl)
standard (1.51.1)
language_server-protocol (~> 3.17.0.2)
lint_roller (~> 1.0)
Expand Down Expand Up @@ -608,6 +630,7 @@ GEM
thruster (0.1.15-x86_64-linux)
tilt (2.6.1)
timeout (0.4.3)
trilogy (2.9.0)
tsort (0.2.0)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
Expand Down Expand Up @@ -661,6 +684,7 @@ DEPENDENCIES
bundler-audit
campy
capybara
database_rewinder
decent_exposure
devise
dotenv-rails
Expand Down Expand Up @@ -694,6 +718,7 @@ DEPENDENCIES
omniauth-google-oauth2
omniauth-rails_csrf_protection
ostruct
pg (~> 1.1)
pjax_rails
pry-rails
puma
Expand All @@ -720,12 +745,15 @@ DEPENDENCIES
rubocop-thread_safety
rushover
selenium-webdriver
shoulda-matchers
simplecov
sprockets-rails
sqlite3 (>= 2.1)
standard (= 1.51.1)
sucker_punch
super_diff
thruster
trilogy (~> 2.7)
underscore-rails
uri
useragent
Expand Down Expand Up @@ -770,6 +798,7 @@ CHECKSUMS
crass (1.0.6) sha256=dc516022a56e7b3b156099abc81b6d2b08ea1ed12676ac7a5657617f012bd45d
css_parser (1.21.1) sha256=6cfd3ffc0a97333b39d2b1b49c95397b05e0e3b684d68f77ec471ba4ec2ef7c7
csv (3.3.5) sha256=6e5134ac3383ef728b7f02725d9872934f523cb40b961479f69cf3afa6c8e73f
database_rewinder (1.1.0) sha256=950398ba97bb20fb4653b6ee502a7d6658a6333a61d88ba756217f32bfa04510
date (3.4.1) sha256=bf268e14ef7158009bfeaec40b5fa3c7271906e88b196d958a89d4b408abe64f
decent_exposure (3.0.4) sha256=5ce9e3df24f8d77f094b2e612d1c43a78a2de879847ccbb57c0e596e6c303cf1
devise (4.9.4) sha256=920042fe5e704c548aa4eb65ebdd65980b83ffae67feb32c697206bfd975a7f8
Expand Down Expand Up @@ -888,6 +917,13 @@ CHECKSUMS
parallel (1.27.0) sha256=4ac151e1806b755fb4e2dc2332cbf0e54f2e24ba821ff2d3dcf86bf6dc4ae130
parser (3.3.9.0) sha256=94d6929354b1a6e3e1f89d79d4d302cc8f5aa814431a6c9c7e0623335d7687f2
patience_diff (1.2.0) sha256=f492094486af02fff4a80070fa6b4d0ebbcf4d42fb38bba29d095eef43f6822c
pg (1.6.2) sha256=58614afd405cc9c2c9e15bffe8432e0d6cfc58b722344ad4a47c73a85189c875
pg (1.6.2-aarch64-linux) sha256=0503c6be5b0ca5ca3aaf91f2ed638f90843313cb81e8e7d7b60ad4bb62c3d131
pg (1.6.2-aarch64-linux-musl) sha256=c4402447c56279bea80472770522e95c8a2ff49b7f3e534d0cdb01eb27fd6eb8
pg (1.6.2-arm64-darwin) sha256=4d44500b28d5193b26674583d199a6484f80f1f2ea9cf54f7d7d06a1b7e316b6
pg (1.6.2-x86_64-darwin) sha256=c441a55723584e2ae41749bf26024d7ffdfe1841b442308ed50cd6b7fda04115
pg (1.6.2-x86_64-linux) sha256=525f438137f2d1411a1ebcc4208ec35cb526b5a3b285a629355c73208506a8ea
pg (1.6.2-x86_64-linux-musl) sha256=e5c8668ffeaf7a9c3458a3dcb002dffa6d8ee1fca9ae534ffef861d2b15644ca
pjax_rails (0.5.1) sha256=3cb4b53d874de1349014aaae2cb879c8924ec86d68f3054a0d958c995b0c8ddb
pp (0.6.2) sha256=947ec3120c6f92195f8ee8aa25a7b2c5297bb106d83b41baa02983686577b6ff
premailer (1.27.0) sha256=0fe2348cd82738855c482b31c915a06ecb1d3ad004578c19042905196ddbd1e7
Expand Down Expand Up @@ -950,12 +986,24 @@ CHECKSUMS
sawyer (0.9.2) sha256=fa3a72d62a4525517b18857ddb78926aab3424de0129be6772a8e2ba240e7aca
securerandom (0.4.1) sha256=cc5193d414a4341b6e225f0cb4446aceca8e50d5e1888743fac16987638ea0b1
selenium-webdriver (4.35.0) sha256=6fc920cec4b9e6263afeb4941289d8deb0853acbc49e0d6f7de91c86986d359b
shoulda-matchers (6.5.0) sha256=ef6b572b2bed1ac4aba6ab2c5ff345a24b6d055a93a3d1c3bfc86d9d499e3f44
simplecov (0.22.0) sha256=fe2622c7834ff23b98066bb0a854284b2729a569ac659f82621fc22ef36213a5
simplecov-html (0.13.2) sha256=bd0b8e54e7c2d7685927e8d6286466359b6f16b18cb0df47b508e8d73c777246
simplecov_json_formatter (0.1.4) sha256=529418fbe8de1713ac2b2d612aa3daa56d316975d307244399fa4838c601b428
snaky_hash (2.0.3) sha256=25a3d299566e8153fb02fa23fd9a9358845950f7a523ddbbe1fa1e0d79a6d456
sprockets (4.2.2) sha256=761e5a49f1c288704763f73139763564c845a8f856d52fba013458f8af1b59b1
sprockets-rails (3.5.2) sha256=a9e88e6ce9f8c912d349aa5401509165ec42326baf9e942a85de4b76dbc4119e
sqlite3 (2.7.4) sha256=7fbc1fdb18ba1c0798fb298cb3c35c35bb1743b832a9aeb91add026a5614889c
sqlite3 (2.7.4-aarch64-linux-gnu) sha256=071da898ef968c83f62b26ed644a4e7f3544034fb2518f99f88a354d9ab6381c
sqlite3 (2.7.4-aarch64-linux-musl) sha256=a9484bef1ee9c3a55ed370baa5147823f844aebfe0df9350f2e9b5518aeee516
sqlite3 (2.7.4-arm-linux-gnu) sha256=b7b35c9802533b1b313cb1bb8e36b5c37277b6019ccf6314740fc7d4503a13d6
sqlite3 (2.7.4-arm-linux-musl) sha256=4809860528e429e24aad52b781ee56bc8e7e0d1a28b76cd6a24f5eded8e2d774
sqlite3 (2.7.4-arm64-darwin) sha256=d5b09cd4e9542aa05f0db0eb7dd868102cc23072ae378e0453e59e0efaed89b8
sqlite3 (2.7.4-x86-linux-gnu) sha256=cca2c067875c47b6e68e30728cac64db98fc05284e2a79df0484621c5e11c52b
sqlite3 (2.7.4-x86-linux-musl) sha256=29d82949963b5b71b304f360802b35c04fb5ff7f37ab584f5c586cc45880fdd4
sqlite3 (2.7.4-x86_64-darwin) sha256=a51bcab41d09311ff7ac6bd4ea5cbdeee99f2e44f22c1b8472b541e9243c1d52
sqlite3 (2.7.4-x86_64-linux-gnu) sha256=0755b458f5501e89c0d5a0003afc4fdd6fd059eb1fb1424221532917096da4be
sqlite3 (2.7.4-x86_64-linux-musl) sha256=494b4ce35524f3bf8ef6741737d0c197086ed8ac4804220fa71d653b39d82a54
standard (1.51.1) sha256=6d0d98a1fac26d660393f37b3d9c864632bb934b17abfa23811996b20f87faf2
standard-custom (1.0.2) sha256=424adc84179a074f1a2a309bb9cf7cd6bfdb2b6541f20c6bf9436c0ba22a652b
standard-performance (1.8.0) sha256=ed17b7d0e061b2a19a91dd434bef629439e2f32310f22f26acb451addc92b788
Expand All @@ -971,6 +1019,7 @@ CHECKSUMS
thruster (0.1.15-x86_64-linux) sha256=a979a3e493c111940723c08c3b7b3b6f95c5d44af26fe65b6edae1f96fc0deda
tilt (2.6.1) sha256=35a99bba2adf7c1e362f5b48f9b581cce4edfba98117e34696dde6d308d84770
timeout (0.4.3) sha256=9509f079b2b55fe4236d79633bd75e34c1c1e7e3fb4b56cb5fda61f80a0fe30e
trilogy (2.9.0) sha256=a2d63b663ba68a4758e15d1f9afb228f5d16efc7fe7cea68699e1c106ef6067f
tsort (0.2.0) sha256=9650a793f6859a43b6641671278f79cfead60ac714148aabe4e3f0060480089f
tzinfo (2.0.6) sha256=8daf828cc77bcf7d63b0e3bdb6caa47e2272dcfaf4fbfe46f8c3a9df087a829b
underscore-rails (1.8.3) sha256=d37d0a297df9078a27e00df6bfa3f3b110eb27dd8f84c1588a9727a2cfbada47
Expand Down
2 changes: 1 addition & 1 deletion app.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"description": "The connection URI to your MongoDB Cluster. If you don't have one, you can create a free plan at https://cloud.mongodb.com . Follow the Heroky deployment docs on the Errbit repo for more information on obtaining this string.",
"required": true
},
"GEMFILE_RUBY_VERSION": "3.4.4",
"GEMFILE_RUBY_VERSION": "3.4.6",
"SECRET_KEY_BASE": {
"description": "A secret key for verifying the integrity of signed cookies.",
"generator": "secret"
Expand Down
2 changes: 1 addition & 1 deletion app/controllers/unlink_githubs_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

class UnlinkGithubsController < ApplicationController
def update
@user = User.find(params[:user_id])
@user = Errbit::User.find(params[:user_id])

authorize @user

Expand Down
2 changes: 1 addition & 1 deletion app/controllers/unlink_googles_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

class UnlinkGooglesController < ApplicationController
def update
@user = User.find(params[:user_id])
@user = Errbit::User.find(params[:user_id])

authorize @user

Expand Down
16 changes: 8 additions & 8 deletions app/controllers/users_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,32 +2,32 @@

class UsersController < ApplicationController
def index
@users = policy_scope(User)
.order_by(name: :asc)
@users = policy_scope(Errbit::User)
.order(name: :asc)
.page(params[:page])
.per(current_user.per_page)
end

def show
@user = User.find(params[:id])
@user = Errbit::User.find(params[:id])

authorize @user
end

def new
@user = User.new
@user = Errbit::User.new

authorize @user
end

def edit
@user = User.find(params[:id])
@user = Errbit::User.find(params[:id])

authorize @user
end

def create
@user = User.new(permitted_attributes(User.new))
32E8 @user = Errbit::User.new(permitted_attributes(Errbit::User.new))

authorize @user

Expand All @@ -41,7 +41,7 @@ def create
end

def update
@user = User.find(params[:id])
@user = Errbit::User.find(params[:id])

authorize @user

Expand All @@ -55,7 +55,7 @@ def update
end

def destroy
@user = User.find(params[:id])
@user = Errbit::User.find(params[:id])

if @user == current_user
flash[:error] = t(".error")
Expand Down
4 changes: 2 additions & 2 deletions app/helpers/application_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ def message_graph(problem)

def generate_problem_ical(notices)
RiCal.Calendar do |cal|
notices.each_with_index do |notice, idx|
notices.each_with_index do |notice, index|
cal.event do |event|
event.summary = "#{idx + 1} #{notice.message}"
event.summary = "#{index + 1} #{notice.message}"
event.description = notice.url if notice.url
event.dtstart = notice.created_at.utc
event.dtend = notice.created_at.utc + 60.minutes
Expand Down
4 changes: 2 additions & 2 deletions app/interactors/user_destroy.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
class UserDestroy
attr_reader :user

# @param user [User] User to destroy
# @param user [Errbit::User] User to destroy
def initialize(user)
@user = user
end
Expand All @@ -15,6 +15,6 @@ def destroy
app.watchers.delete(watcher)
end

user.destroy
user.destroy!
end
end
7 changes: 7 additions & 0 deletions app/models/errbit.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# frozen_string_literal: true

module Errbit
def self.table_name_prefix
"errbit_"
end
end
6 changes: 6 additions & 0 deletions app/models/errbit/app.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# frozen_string_literal: true

module Errbit
class App < ApplicationRecord
end
end
7 changes: 7 additions & 0 deletions app/models/errbit/application_record.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# frozen_string_literal: true

module Errbit
class ApplicationRecord < ActiveRecord::Base
primary_abstract_class
end
end
76 changes: 76 additions & 0 deletions app/models/errbit/user.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
# frozen_string_literal: true

module Errbit
class User < ApplicationRecord
PER_PAGE = 30

devise(*Errbit::Config.devise_modules)

validates :name, presence: true
validates :github_login, uniqueness: {allow_nil: true}

def per_page
super || PER_PAGE
end

# def watching?(app)
# # apps.all.include?(app)
# end

# def password_required?
# github_login.present? ? false : super
# end

# def github_account?
# github_login.present? && github_oauth_token.present?
# end

# def can_create_github_issues?
# # github_account? && Errbit::Config.github_access_scope.include?("repo")
# end

# def github_login=(login)
# # login = nil if login.is_a?(String) && login.strip.empty?
# # self[:github_login] = login
# end

# def google_account?
# google_uid.present?
# end

# def ensure_authentication_token
# # if authentication_token.blank?
# # self.authentication_token = generate_authentication_token
# # end
# end

# def self.token_authentication_key
# # :auth_token
# end

# def reset_password(new_password, new_password_confirmation)
# # self.password = new_password
# # self.password_confirmation = new_password_confirmation
# #
# # self.class.validators_on(:password).map { |v| v.validate_each(self, :password, password) }
# # return false if errors.any?
# # save(validate: false)
# end

def attributes_for_super_diff
{
id: id,
name: name
}
end

private

def generate_authentication_token
loop do
token = Devise.friendly_token
break token unless Errbit::User.where(authentication_token: token).first
end
end
end
end
Loading
Loading
0