1
mirror of https://github.com/s4turns/Injected.git synced 2026-05-17 20:58:05 +00:00

Injected

A modern IRC client built with Electron, React, and TypeScript.

Features

  • Multi-server support - Connect to multiple IRC networks simultaneously
  • SSL/TLS & SASL - Secure connections with optional SASL authentication
  • Full IRC command set - /join, /part, /kick, /ban, /mode, /whois, /oper, and more
  • IRCv3 services - Built-in NickServ, ChanServ, OperServ, and MemoServ integration with context menus
  • IRC operator tools - Kill, G-Line, K-Line, Z-Line, SAJOIN, SANICK, WALLOPS, GLOBOPS, rehash, and more
  • Scripting engine - JavaScript scripting via sandboxed VM with persistent storage and IRC event hooks
  • Theming - Fully customizable JSON themes (colors, fonts, nick colors, timestamp format)
  • Tab completion - Nick tab-completion with cycling
  • Command history - Arrow keys to navigate input history
  • Channel list - Browse and search available channels
  • WHOIS dialog - View detailed user information
  • IRC color rendering - Full mIRC color code and formatting support
  • Context menus - Right-click users, channels, and servers for quick actions

Screenshot

image

Getting Started

Prerequisites

Install

git clone https://github.com/s4turns/injected.git
cd injected
npm install

Development

npm run dev

This compiles the main process TypeScript and starts both the Vite dev server (renderer) and Electron concurrently.

Build

npm run build

Produces platform-specific installers in the release/ directory:

Platform Format
Windows NSIS installer
Linux AppImage, .deb

Project Structure

src/
  main/               # Electron main process
    irc/              # IRC connection manager, event handling, protocol parsing
    scripting/        # JavaScript scripting engine (VM sandbox)
    services/         # NickServ, ChanServ, OperServ, MemoServ handlers
    main.ts           # App entry point, window creation
    ipc.ts            # IPC handler registration
    preload.ts        # Context bridge API
    store.ts          # Settings persistence (electron-store)
  renderer/           # React frontend (Vite)
    components/
      chat/           # Message rendering, IRC color formatting
      context-menus/  # User, channel, server right-click menus
      dialogs/        # Server config, settings, WHOIS, channel list, script editor
      layout/         # Sidebar, main panel, nick list, input bar, status bar
      theme/          # Theme provider and customizer
    hooks/            # useIRC, useTheme, useContextMenu
    stores/           # Zustand state (channels, connections, settings, UI)
  shared/             # Types and constants shared between processes
scripts/              # User scripts directory
themes/               # JSON theme files

Scripting

Drop .js files into the scripts/ directory. Scripts run in a sandboxed VM with access to the irc API:

irc.on('message', (data) => {
  if (data.message === '!hello') {
    irc.send(data.serverId, data.channel, 'Hello ' + data.nick + '!');
  }
});

// Persistent key-value storage
irc.store.set('key', 'value');
irc.store.get('key');

See scripts/example.js for more examples.

Theming

Themes are JSON files in themes/. The default theme uses a Tokyo Night-inspired dark palette. Customize colors, fonts, nick colors, and timestamp format.

Tech Stack

  • Electron 28 - Desktop runtime
  • React 18 - UI framework
  • TypeScript 5 - Type safety
  • Vite 5 - Renderer bundling and dev server
  • Zustand 4 - State management
  • irc-framework - IRC protocol library
  • electron-store - Settings persistence
  • electron-builder - Packaging and distribution

Troubleshooting

Windows

Symlink errors during npm install or build

ERROR: Cannot create symbolic link : A required privilege is not held by the client.

Either enable Developer Mode (Settings > System > For developers) or run your terminal as Administrator.

EFTYPE / esbuild errors

spawnSync ...\esbuild.exe EFTYPE

Your Node.js version may be too new. Use Node.js 22 LTS from nodejs.org. Then:

Remove-Item -Recurse -Force node_modules
npm cache clean --force
npm install

TAR_ENTRY_ERROR / bad file descriptor during npm install

npm warn tar TAR_ENTRY_ERROR EBADF: bad file descriptor, write

This happens when the project is on a Google Drive or cloud-synced folder. Move the project to a local drive (e.g. C:\Users\you\injected) and run npm install there.

Installer doesn't launch / app won't start

  • Right-click the installer and select Run as administrator
  • If Windows SmartScreen blocks it, click More info > Run anyway (the app is unsigned)
  • Try running the unpacked exe directly: release\win-unpacked\Injected.exe

EBUSY / locked files when reinstalling

EBUSY: resource busy or locked, rmdir '...\node_modules\electron'

Close any running Electron/Injected processes, close editors that may have files open, then retry.

Linux

AppImage won't run

chmod +x Injected-*.AppImage
./Injected-*.AppImage

If it still fails, try with --no-sandbox:

./Injected-*.AppImage --no-sandbox

Missing dependencies on Debian/Ubuntu

sudo apt install libgtk-3-0 libnotify4 libnss3 libxss1 libxtst6 xdg-utils libatspi2.0-0 libsecret-1-0

GPU/rendering issues If you see a blank window or graphical glitches:

./Injected-*.AppImage --disable-gpu

Tray icon not showing (Wayland) XWayland may be required for tray support. Run with:

GDK_BACKEND=x11 ./Injected-*.AppImage

License

MIT

Description
A modern IRC client built with Electron, React, and TypeScript
Readme 238 KiB
Languages
TypeScript 96%
CSS 2.9%
JavaScript 0.9%
HTML 0.2%