Rename app from chat to neoirc, binary to neoircd (closes #46)
All checks were successful
check / check (push) Successful in 4s
All checks were successful
check / check (push) Successful in 4s
- Rename Go module path: git.eeqj.de/sneak/chat -> git.eeqj.de/sneak/neoirc - Rename binary: chatd -> neoircd, chat-cli -> neoirc-cli - Rename cmd directories: cmd/chatd -> cmd/neoircd, cmd/chat-cli -> cmd/neoirc-cli - Rename Go package: chatapi -> neoircapi - Update Makefile: binary name, build targets, docker image tag, clean target - Update Dockerfile: binary paths, user/group names, ENTRYPOINT - Update .gitignore and .dockerignore - Update all Go imports and doc comments - Update default server name fallback: chat -> neoirc - Update web client: localStorage keys, page title, default server name - Update all schema $id URLs and example hostnames - Update README.md: project name, binary references, examples, directory tree - Update AGENTS.md: build command reference - Update test fixtures: app name and channel names
This commit is contained in:
4
web/dist/app.js
vendored
4
web/dist/app.js
vendored
File diff suppressed because one or more lines are too long
2
web/dist/index.html
vendored
2
web/dist/index.html
vendored
@@ -3,7 +3,7 @@
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Chat</title>
|
||||
<title>NeoIRC</title>
|
||||
<link rel="stylesheet" href="/style.css">
|
||||
</head>
|
||||
<body>
|
||||
|
||||
@@ -7,7 +7,7 @@ const RECONNECT_DELAY = 3000;
|
||||
const MEMBER_REFRESH_INTERVAL = 10000;
|
||||
|
||||
function api(path, opts = {}) {
|
||||
const token = localStorage.getItem('chat_token');
|
||||
const token = localStorage.getItem('neoirc_token');
|
||||
const headers = { 'Content-Type': 'application/json', ...(opts.headers || {}) };
|
||||
if (token) headers['Authorization'] = `Bearer ${token}`;
|
||||
const { signal, ...rest } = opts;
|
||||
@@ -34,7 +34,7 @@ function LoginScreen({ onLogin }) {
|
||||
const [nick, setNick] = useState('');
|
||||
const [error, setError] = useState('');
|
||||
const [motd, setMotd] = useState('');
|
||||
const [serverName, setServerName] = useState('Chat');
|
||||
const [serverName, setServerName] = useState('NeoIRC');
|
||||
const inputRef = useRef();
|
||||
|
||||
useEffect(() => {
|
||||
@@ -42,9 +42,9 @@ function LoginScreen({ onLogin }) {
|
||||
if (s.name) setServerName(s.name);
|
||||
if (s.motd) setMotd(s.motd);
|
||||
}).catch(() => {});
|
||||
const saved = localStorage.getItem('chat_token');
|
||||
const saved = localStorage.getItem('neoirc_token');
|
||||
if (saved) {
|
||||
api('/state').then(u => onLogin(u.nick)).catch(() => localStorage.removeItem('chat_token'));
|
||||
api('/state').then(u => onLogin(u.nick)).catch(() => localStorage.removeItem('neoirc_token'));
|
||||
}
|
||||
inputRef.current?.focus();
|
||||
}, []);
|
||||
@@ -57,7 +57,7 @@ function LoginScreen({ onLogin }) {
|
||||
method: 'POST',
|
||||
body: JSON.stringify({ nick: nick.trim() })
|
||||
});
|
||||
localStorage.setItem('chat_token', res.token);
|
||||
localStorage.setItem('neoirc_token', res.token);
|
||||
onLogin(res.nick);
|
||||
} catch (err) {
|
||||
setError(err.data?.error || 'Connection failed');
|
||||
@@ -132,7 +132,7 @@ function App() {
|
||||
// Persist joined channels
|
||||
useEffect(() => {
|
||||
const channels = tabs.filter(t => t.type === 'channel').map(t => t.name);
|
||||
localStorage.setItem('chat_channels', JSON.stringify(channels));
|
||||
localStorage.setItem('neoirc_channels', JSON.stringify(channels));
|
||||
}, [tabs]);
|
||||
|
||||
// Clear unread on tab switch
|
||||
@@ -321,7 +321,7 @@ function App() {
|
||||
setLoggedIn(true);
|
||||
addSystemMessage('Server', `Connected as ${userNick}`);
|
||||
// Auto-rejoin saved channels
|
||||
const saved = JSON.parse(localStorage.getItem('chat_channels') || '[]');
|
||||
const saved = JSON.parse(localStorage.getItem('neoirc_channels') || '[]');
|
||||
for (const ch of saved) {
|
||||
try {
|
||||
await api('/messages', { method: 'POST', body: JSON.stringify({ command: 'JOIN', to: ch }) });
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Chat</title>
|
||||
<title>NeoIRC</title>
|
||||
<link rel="stylesheet" href="/style.css">
|
||||
</head>
|
||||
<body>
|
||||
|
||||
Reference in New Issue
Block a user