trayN is a Windows task-tray quick memo app for temporary plain-text notes. It stays in the notification area, opens with the default hotkey Ctrl + Alt + M, and saves one memo automatically.
trayN.sln
TrayN/
TrayN.csproj
Program.cs
TrayApplicationContext.cs
MemoForm.cs
MemoStore.cs
SettingsStore.cs
HotKeyManager.cs
HotKeySettings.cs
HotKeySettingsForm.cs
HotKeyFormatter.cs
HotKeyValidator.cs
SingleInstanceManager.cs
IpcSignal.cs
IpcServer.cs
UpdateService.cs
TrayN.Updater/
TrayN.Updater.csproj
Program.cs
UpdaterOptions.cs
- Windows
- .NET 10 SDK
- No Visual Studio requirement
- No external NuGet packages
dotnet build .\trayN.slndotnet run --project .\TrayN\TrayN.csprojThe app starts in the task tray without showing the memo window.
Publish both projects as Windows x64 self-contained single-file executables:
dotnet publish .\TrayN\TrayN.csproj -c Release -r win-x64 --self-contained true -p:PublishSingleFile=true
dotnet publish .\TrayN.Updater\TrayN.Updater.csproj -c Release -r win-x64 --self-contained true -p:PublishSingleFile=trueExpected executable names:
trayN.exetrayN.Updater.exe
Place both files in the same writable directory. The built-in updater assumes both executables are next to each other and that the current user can replace trayN.exe.
trayN stores user data under:
%LOCALAPPDATA%\trayn\
Files:
%LOCALAPPDATA%\trayn\memo.txt%LOCALAPPDATA%\trayn\settings.json
The memo file is UTF-8. Settings include the memo window bounds, hotkey settings, and the last automatic update check time in UTC.
Hotkey settings are stored in a human-readable form:
{
"hotKey": {
"control": true,
"alt": true,
"shift": false,
"win": false,
"key": "M"
}
}If hotKey is missing or invalid, trayN uses Ctrl + Alt + M.
- Default hotkey:
Ctrl + Alt + M - The hotkey shows or hides the memo window
Esc: hide the memo window- Window close button: hide the memo window
- Tray icon double-click: show the memo window
- Tray menu:
メモを表示ホットキー設定- current hotkey display
アップデートを確認終了
Choose ホットキー設定 from the tray menu to change the global hotkey. The setting dialog captures the actual key combination you press, supports Ctrl, Alt, Shift, Win, and one normal key, and applies the new hotkey immediately after saving.
Remote Desktop, Amazon WorkSpaces, and similar environments may let a local app or the host OS capture global hotkeys before trayN receives them. If the hotkey does not work, choose another combination from the tray menu. If hotkey registration fails, trayN keeps running and the memo can still be opened from the tray icon.
Normal user exit is only through the tray menu 終了.
Update checking uses the GitHub latest release API:
https://api.github.com/repos/<owner>/<repo>/releases/latest
Configure the repository constants in TrayN/UpdateService.cs:
private const string GitHubOwner = "fclef819";
private const string GitHubRepository = "trayN";Release tags must use this form:
v1.2.3
Draft and prerelease releases are ignored.
This repository includes a GitHub Actions workflow at .github/workflows/release.yml.
When a tag matching v*.*.* is pushed, the workflow builds both projects, publishes Windows x64 self-contained single-file executables, generates trayN.exe.sha256, packages the two executables into trayN.zip, and creates a GitHub Release.
Create a release by pushing a version tag:
git tag v1.2.3
git push origin v1.2.3Attach these release assets:
trayN.exetrayN.exe.sha256trayN.Updater.exetrayN.zip
The updater replaces only trayN.exe. Updating trayN.Updater.exe itself is intentionally not implemented.
trayN.exe.sha256 must contain:
<SHA-256 hash> trayN.exe
Generate it with PowerShell:
$hash = (Get-FileHash .\trayN.exe -Algorithm SHA256).Hash
"$hash trayN.exe" | Set-Content .\trayN.exe.sha256 -Encoding ascii- trayN checks GitHub Releases in the background on startup.
- Automatic startup checks run at most once every 24 hours.
- Manual checks from the tray menu ignore the 24-hour limit.
- If a newer version exists, trayN shows a tray balloon or confirmation dialog.
- Update download starts only after user approval.
trayN.exeandtrayN.exe.sha256are downloaded to a temporary directory.- SHA-256 is verified before applying the update.
- trayN saves pending memo/settings data and starts
trayN.Updater.exe. - The updater waits for trayN to exit, backs up the old
trayN.exe, replaces it, starts the newtrayN.exe, and removes temporary files. - If replacement fails, the updater restores the backup when possible.
- Start trayN and confirm only the tray icon appears.
- Press the default
Ctrl + Alt + Mand confirm the memo window toggles on first launch. - Open
ホットキー設定and confirm the current value is shown. - Change to a new hotkey and confirm it works immediately without restarting.
- Restart trayN and confirm the changed hotkey is restored.
- Cancel the hotkey dialog and confirm the setting is not changed.
- Use
既定値へ戻す, save, and confirmCtrl + Alt + Mis restored. - Try a hotkey already used by another app and confirm an error is shown.
- After a registration failure, confirm the previous hotkey still works.
- Confirm modifier-only input cannot be saved.
- Confirm reserved Windows shortcuts such as
Alt + Tab,Alt + F4,Win + L, andWin + Rcannot be saved. - Confirm the tray menu still opens the memo when no hotkey is registered.
- Close the memo window and confirm trayN remains resident.
- Type text, wait briefly, restart, and confirm the memo is restored.
- Type text and exit immediately from the tray menu, then confirm text is not lost.
- Start a second
trayN.exeand confirm the existing memo window is shown. - Corrupt
%LOCALAPPDATA%\trayn\settings.jsonand confirm startup still works. - Remove
hotKeyfrom%LOCALAPPDATA%\trayn\settings.jsonand confirmCtrl + Alt + Mis used. - Put an invalid
hotKey.keyvalue in%LOCALAPPDATA%\trayn\settings.jsonand confirm startup still works. - Move monitors or edit saved bounds off-screen and confirm the window returns to a visible area.
- Confirm the tray icon disappears after exit.
- Confirm manual update check does not block memo editing.
- Confirm hash mismatch stops update and leaves the old
trayN.exeintact. - Confirm update failure restores the backup where possible.