A kódbázis kommentek nélkül marad
Kérésre: minden magyarázó komment kikerült a forrásfájlokból — 89 Ruby, 16 TypeScript, 14 Vue, plusz a CSS/JS/CJS. Nem soralapú kereséssel: a Ruby-t a Ripper tokenizálta, a JS/TS/CSS-t állapotgép járta végig, hogy az URL-ekben, reguláris kifejezésekben és heredocokban álló // és # jelek helyükön maradjanak. Három komment maradt, mert nélkülük nem indul a kód: az entrypoint.sh shebangja, a vite-env.d.ts hármas perjeles referenciája, és a sanitize teszt @vitest-environment direktívája (ez utóbbi a magyarázó része nélkül). Egy helyen kódot is kellett írni: a CommandBlock másolás-hibaágán a komment volt a catch egyetlen tartalma, és üres blokkot az eslint nem enged — a copied jelző visszaállítása került a helyére. A yaml, Dockerfile, Makefile, erb és markdown fájlokat nem érintettem. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -1,7 +1,4 @@
|
||||
ActiveAdmin.register WarpEngine::DeviceGrant, as: "Device Sign-in" do
|
||||
# Read-only on purpose. A grant is created by a client and answered by a person on the
|
||||
# host's own page; an admin creating one by hand would be issuing somebody else a
|
||||
# credential, which is not a thing this page should make easy.
|
||||
actions :index, :show
|
||||
|
||||
menu parent: "🌀 WarpEngine", priority: 10, label: "📱 Device Sign-ins",
|
||||
@@ -45,8 +42,7 @@ ActiveAdmin.register WarpEngine::DeviceGrant, as: "Device Sign-in" do
|
||||
subject = g.subject
|
||||
subject.try(:email) || subject.try(:name) || "#{g.subject_type} ##{g.subject_id}"
|
||||
end
|
||||
# The device code itself is never shown: it is the client's live credential for as
|
||||
# long as the grant is pending, and this page is not where it should leak from.
|
||||
|
||||
row("Token") do |g|
|
||||
token = g.application_token
|
||||
next "—" if token.nil?
|
||||
|
||||
Reference in New Issue
Block a user