Commit Graph

37 Commits

Author SHA1 Message Date
JiXieShi a1524a7e17 refactor: extract internal/session and eliminate I/O globals
Move serial port, trzsz filter, and pipe lifecycle into
internal/session.SerialSession. Replace 8 global I/O vars
(serialPort, trzszFilter, stdinPipe, stdoutPipe, clientIn,
clientOut, termch, termchOnce) with single sess variable.
Delete utils.go.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-23 21:49:43 +08:00
JiXieShi 31dd9da490 refactor: extract internal/config and eliminate global config var
Move Config struct to internal/config with exported fields. Replace
global var config with package-level cfg pointer. Add OpenLogFile to
config package. Add type alias Config = appconfig.Config in main
package for backward compatibility.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-23 21:45:08 +08:00
JiXieShi 2ce672cdde refactor: extract pkg/forward and pkg/luaplugin packages
Move ForwardManager → pkg/forward/Manager and PluginManager →
pkg/luaplugin/Manager. Move FoeWardMode (now forward.Mode) with
ParseMode/Network/String into pkg/forward. Rename constants:
NOT→None, TCPC→TCP, UDPC→UDP. Update all references in main
package.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-23 19:41:45 +08:00
JiXieShi e0de872740 refactor: extract pkg/charset and internal/event packages
Extract ConvertChunk/FormatHexFrame into pkg/charset (zero external deps).
Extract UIEvent/UIEventKind/UIPanelKind types into internal/event.
Update all references across main package to use qualified imports.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-22 02:35:30 +08:00
JiXieShi d434d961ee refactor: rename module and create directory scaffold
Rename module from COM to github.com/jixishi/SerialTerminalForWindowsTerminal.
Create target directory tree: cmd/serialterminal/, internal/{app,command,config,
console,event,flag,session,tui}, pkg/{charset,forward,luaplugin}.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-22 02:26:06 +08:00
JiXieShi 2ffb86cc17 chore: remove dead code and binary files from tracking
Remove unused global var `in`, func `strout`, func `echoConsoleInput`,
func `padRight`, func `ErrorP`, and func `ErrorF`. Inline error check
in CloseSerial. Add COM.exe and coverage.out to .gitignore.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-22 02:25:23 +08:00
jixishi f6eff2da22 Fix img名称错误 2024-06-12 14:46:29 +08:00
jixishi 2fc4b4f41a UP 多服同步 2024-06-12 14:43:43 +08:00
jixishi c841dfeae4 UP 功能建议更新 v0.9.5 2024-06-03 20:54:23 +08:00
jixishi 88285df82b UP README.md 2024-05-30 16:43:21 +08:00
jixishi 67e2f5a1c8 UP README.md 2024-05-30 16:35:29 +08:00
jixishi 17950c05dc UP releaser v0.9.4 2024-05-30 16:23:53 +08:00
jixishi 9b374fc42d Merge branch 'dev' 2024-05-30 16:04:55 +08:00
jixishi 82ec65958e 时间戳 文件传输 支持 2024-05-30 15:56:52 +08:00
jixishi 68f285b5ed up v0.9.3 2024-04-26 22:33:08 +08:00
jixishi d2f8c8a268 增加Ctrl组合键发送指令.ctrl 如.ctrl c 2024-04-26 22:29:16 +08:00
jixishi 8d4273df77 增加交互式配置支持 2024-04-26 22:29:00 +08:00
jixishi 92c92e67e1 增加交互式配置支持 2024-04-26 22:23:32 +08:00
jixishi 604e5bb4ad 修复帧指定的错误参数指向 v0.9.2 2024-04-26 12:49:32 +08:00
jixishi e3415ae05a 去除TCP服务端连接 2024-04-26 11:55:26 +08:00
jixishi d19c09e4cd TCP|UDP 客户端数据转发支持更新 帧长设置支持 2024-04-26 11:03:44 +08:00
jixishi 5bf90d1b63 TCP|UDP 客户端数据转发支持更新 2024-04-19 22:42:28 +08:00
jixishi dffb269247 RT 2024-04-19 17:03:28 +08:00
JiXieShi d450a8a019 多平台构建 v0.9.1 2024-04-19 16:18:03 +08:00
JiXieShi 8b1e5bfb06 多平台构建 v0.9 2024-04-19 16:15:28 +08:00
JiXieShi 437f309ab9 多平台构建 2024-04-19 16:08:55 +08:00
JiXieShi 1ca7e23911 优化项目结构,添加hex与原文的对照显示 v0.8 2024-04-19 15:10:16 +08:00
JiXieShi a4004a1d05 优化项目结构 2024-04-19 15:08:00 +08:00
JiXieShi 0f2fe50b04 修复终端指令卡住的问题 2024-04-13 15:27:31 +08:00
JiXieShi 03b3cf3793 Up README.md 2024-04-13 15:07:00 +08:00
JiXieShi e22b534205 Merge remote-tracking branch 'origin/main'
# Conflicts:
#	main.go
v0.7
2024-04-13 14:50:12 +08:00
JiXieShi 231560ae8e 增加hex收发功能 2024-04-13 14:49:25 +08:00
JiXieShi 61ad821ecc 增加hex收发功能 2024-04-13 14:44:48 +08:00
JiXieShi d6458dd31d Init 2024-04-12 22:30:55 +08:00
JiXieShi 5bd9108a96 Init 2024-04-12 22:30:09 +08:00
JiXieShi dcf66b6895 Init 2024-04-12 22:29:17 +08:00
JiXieShi 5d4558582a Init 2024-04-12 22:14:52 +08:00