Skip to content

Commit c1821d8

Browse files
authored
First cut
1 parent 81712ed commit c1821d8

17 files changed

+41
-7
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,3 +33,5 @@
3333

3434
# Ignore master key for decrypting credentials and more.
3535
/config/master.key
36+
37+
dump.rdb

Gemfile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ gem "stimulus-rails"
2828
gem "jbuilder"
2929

3030
# Use Redis adapter to run Action Cable in production
31-
# gem "redis", "~> 4.0"
31+
gem "redis", "~> 4.0"
3232

3333
# Use Kredis to get higher-level data types in Redis [https://github.com/rails/kredis]
3434
# gem "kredis"
@@ -74,3 +74,5 @@ group :test do
7474
gem "selenium-webdriver"
7575
gem "webdrivers"
7676
end
77+
78+
gem "hotwire-livereload", "~> 1.2"

Gemfile.lock

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,8 +108,12 @@ GEM
108108
rubocop
109109
smart_properties
110110
erubi (1.11.0)
111+
ffi (1.15.5)
111112
globalid (1.0.0)
112113
activesupport (>= 5.0)
114+
hotwire-livereload (1.2.2)
115+
listen (>= 3.0.0)
116+
rails (>= 6.0.0)
113117
i18n (1.12.0)
114118
concurrent-ruby (~> 1.0)
115119
importmap-rails (1.1.5)
@@ -127,6 +131,9 @@ GEM
127131
rexml
128132
kramdown-parser-gfm (1.1.0)
129133
kramdown (~> 2.0)
134+
listen (3.7.1)
135+
rb-fsevent (~> 0.10, >= 0.10.3)
136+
rb-inotify (~> 0.9, >= 0.9.10)
130137
loofah (2.18.0)
131138
crass (~> 1.0.2)
132139
nokogiri (>= 1.5.9)
@@ -193,6 +200,10 @@ GEM
193200
zeitwerk (~> 2.5)
194201
rainbow (3.1.1)
195202
rake (13.0.6)
203+
rb-fsevent (0.11.2)
204+
rb-inotify (0.10.1)
205+
ffi (~> 1.0)
206+
redis (4.8.0)
196207
regexp_parser (2.5.0)
197208
reline (0.3.1)
198209
io-console (~> 0.5)
@@ -283,10 +294,12 @@ DEPENDENCIES
283294
capybara
284295
debug
285296
erb_lint
297+
hotwire-livereload (~> 1.2)
286298
importmap-rails
287299
jbuilder
288300
puma (~> 5.0)
289301
rails (~> 7.0.3)
302+
redis (~> 4.0)
290303
selenium-webdriver
291304
solargraph
292305
sprockets-rails
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
class HelloCodespacesController < ApplicationController
2+
def index
3+
end
4+
end
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
module HelloCodespacesHelper
2+
end
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
<h1>HelloCodespaces#index</h1>
2+
<p>Find me in app/views/hello_codespaces/index.html.erb!!</p>

app/views/layouts/application.html.erb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88

99
<%= stylesheet_link_tag "application", "data-turbo-track": "reload" %>
1010
<%= javascript_importmap_tags %>
11+
<%= hotwire_livereload_tags if Rails.env.development? %>
1112
</head>
1213

1314
<body>

config/cable.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
development:
2-
adapter: async
2+
adapter: redis
3+
url: redis://localhost:6379/1
34

45
test:
56
adapter: test

config/environments/development.rb

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,10 @@
7070
# config.action_view.annotate_rendered_view_with_filenames = true
7171

7272
# Uncomment if you wish to allow Action Cable access from any origin.
73-
# config.action_cable.disable_request_forgery_protection = true
73+
config.action_cable.disable_request_forgery_protection = true
7474

7575
# Allow requests from our preview domain.
7676
config.hosts << "#{ENV['CODESPACE_NAME']}-3000.preview.app.github.dev"
77+
78+
# config.action_cable.allowed_request_origins = ["#{ENV['CODESPACE_NAME']}-3000.preview.app.github.dev"]
7779
end

config/routes.rb

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
11
Rails.application.routes.draw do
2-
# Define your application routes per the DSL in https://guides.rubyonrails.org/routing.html
3-
4-
# Defines the root path route ("/")
5-
# root "articles#index"
2+
root "hello_codespaces#index"
63
end

0 commit comments

Comments
 (0)