Update env var names to SIGITSI_SMBCLOUD and improve diff UI

Switch all SMBCLOUD_* env vars to SIGITSI_SMBCLOUD_* for clarity. Refactor commit diff UI to use collapsible details with file toggles.

Seto Elkahfi committed Apr 13, 2026 at 20:41 UTC 2b554632759467ba356e69a13c58c246dbda70ed
4 files changed +22 -17
app/controllers/dev/panel_controller.rb
+1 -1
index f11c17e..fe4c45b 100644 --- a/app/controllers/dev/panel_controller.rb +++ b/app/controllers/dev/panel_controller.rb @@ -29,7 +29,7 @@ module Dev private def current_environment - Rails.cache.read(CACHE_KEY) || ENV.fetch("SMBCLOUD_ENVIRONMENT", "dev") + Rails.cache.read(CACHE_KEY) || ENV.fetch("SIGITSI_SMBCLOUD_ENVIRONMENT", "dev") end end end
app/controllers/sessions_controller.rb
+1 -1
index 0c45db7..7f6b991 100644 --- a/app/controllers/sessions_controller.rb +++ b/app/controllers/sessions_controller.rb @@ -52,7 +52,7 @@ class SessionsController < ApplicationController render :new, status: :unprocessable_entity rescue KeyError => e - # Missing SMBCLOUD_APP_ID / SMBCLOUD_APP_SECRET env vars + # Missing SIGITSI_SMBCLOUD_APP_ID / SIGITSI_SMBCLOUD_APP_SECRET env vars Rails.logger.error("smbCloud configuration error: #{e.message}") flash.now[:alert] = "Authentication service is not configured. Please contact support." render :new, status: :internal_server_error
app/services/smbcloud_auth_service.rb
+10 -10
index d161c68..64cd969 100644 --- a/app/services/smbcloud_auth_service.rb +++ b/app/services/smbcloud_auth_service.rb @@ -19,9 +19,9 @@ # client.remove(access_token:) # # Required env vars: -# SMBCLOUD_APP_ID – your smbCloud app ID -# SMBCLOUD_APP_SECRET – your smbCloud app secret -# SMBCLOUD_ENVIRONMENT – "production" (default) or "dev" +# SIGITSI_SMBCLOUD_APP_ID – your smbCloud app ID +# SIGITSI_SMBCLOUD_APP_SECRET – your smbCloud app secret +# SIGITSI_SMBCLOUD_ENVIRONMENT – "production" (default) or "dev" # require "auth" @@ -120,29 +120,29 @@ class SmbcloudAuthService def self.smbcloud_environment raw = if Rails.env.development? Rails.cache.read("dev:smbcloud_environment") || - ENV.fetch("SMBCLOUD_ENVIRONMENT", "dev") + ENV.fetch("SIGITSI_SMBCLOUD_ENVIRONMENT", "dev") else - ENV.fetch("SMBCLOUD_ENVIRONMENT", "production") + ENV.fetch("SIGITSI_SMBCLOUD_ENVIRONMENT", "production") end.strip.downcase case raw when "dev", "development" then SmbCloud::Auth::Environment::DEV when "production" then SmbCloud::Auth::Environment::PRODUCTION else - Rails.logger.warn("Unknown SMBCLOUD_ENVIRONMENT '#{raw}', defaulting to production.") + Rails.logger.warn("Unknown SIGITSI_SMBCLOUD_ENVIRONMENT '#{raw}', defaulting to production.") SmbCloud::Auth::Environment::PRODUCTION end end def self.smbcloud_app_id - ENV.fetch("SMBCLOUD_APP_ID") do - raise KeyError, "Missing required env var: SMBCLOUD_APP_ID" + ENV.fetch("SIGITSI_SMBCLOUD_APP_ID") do + raise KeyError, "Missing required env var: SIGITSI_SMBCLOUD_APP_ID" end end def self.smbcloud_app_secret - ENV.fetch("SMBCLOUD_APP_SECRET") do - raise KeyError, "Missing required env var: SMBCLOUD_APP_SECRET" + ENV.fetch("SIGITSI_SMBCLOUD_APP_SECRET") do + raise KeyError, "Missing required env var: SIGITSI_SMBCLOUD_APP_SECRET" end end
app/views/commits/show.html.erb
+10 -5
index 2e26922..7a321a5 100644 --- a/app/views/commits/show.html.erb +++ b/app/views/commits/show.html.erb @@ -75,9 +75,14 @@ deletions = fd[:lines].count { |l| l.start_with?("-") && !l.start_with?("---") } %> - <div class="card overflow-hidden"> - <div class="flex items-center justify-between px-4 py-2.5 border-b border-surface-600 bg-surface-700"> - <span class="font-mono text-xs text-gray-200 truncate"><%= filename %></span> + <details class="card overflow-hidden group" open> + <summary class="flex items-center justify-between px-4 py-2.5 border-b border-surface-600 bg-surface-700 cursor-pointer list-none hover:bg-surface-600 transition-colors"> + <div class="flex items-center gap-2 min-w-0"> + <svg class="w-3.5 h-3.5 text-gray-500 shrink-0 transition-transform group-open:rotate-90" viewBox="0 0 16 16" fill="currentColor"> + <path d="M6.22 3.22a.75.75 0 0 1 1.06 0l4.25 4.25a.75.75 0 0 1 0 1.06l-4.25 4.25a.75.75 0 0 1-1.06-1.06L9.94 8 6.22 4.28a.75.75 0 0 1 0-1.06Z"/> + </svg> + <span class="font-mono text-xs text-gray-200 truncate"><%= filename %></span> + </div> <div class="flex items-center gap-2 shrink-0 ml-4 font-mono text-xs"> <% if additions > 0 %> <span class="text-green-400">+<%= additions %></span> @@ -86,7 +91,7 @@ <span class="text-red-400">-<%= deletions %></span> <% end %> </div> - </div> + </summary> <div class="font-mono text-xs leading-5 overflow-x-auto"> <% fd[:lines].each do |line| %> @@ -102,7 +107,7 @@ <span class="<%= css %>"><%= line.chomp %></span> <% end %> </div> - </div> + </details> <% end %> <% end %> </div>