mirror of
https://github.com/QYG2297248353/IYUUPlus-Windows.git
synced 2025-12-29 08:01:35 +08:00
Compare commits
6 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 3bb4562dd5 | |||
| 438e217c33 | |||
| 357fb2ecda | |||
| 291321e268 | |||
| 08f4e70f9d | |||
| f7fa2cf0a7 |
@@ -0,0 +1,21 @@
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2024 新疆萌森软件开发工作室
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
@@ -22,6 +22,17 @@ Electron + IYUUPlus 封装而成
|
||||
下载安装包,运行即可。
|
||||
当前支持 x84 与 x64 位系统
|
||||
|
||||
+ GitHub 发布地址
|
||||
```url
|
||||
https://github.com/QYG2297248353/IYUUPlus-Windows/releases
|
||||
```
|
||||
|
||||
+ 网盘仓库
|
||||
- [文叔叔](https://f.ws59.cn/f/ehxqmk2tkrx)
|
||||
- [123云盘](https://www.123pan.com/s/AEz0Vv-xHcUh.html)
|
||||
- [Minio 仓库](https://minio.lifebus.top/api/v1/download-shared-object/https:%2F%2Ff.lifebus.top%2Fpublic%2Fiyuu-plus-1.1.0%2520Setup.exe%3FX-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=58BL7NCU45RD0CQOL44Q%252F20240702%252Fus-east-1%252Fs3%252Faws4_request&X-Amz-Date=20240702T101832Z&X-Amz-Expires=43200&X-Amz-Security-Token=eyJhbGciOiJIUzUxMiIsInR5cCI6IkpXVCJ9.eyJhY2Nlc3NLZXkiOiI1OEJMN05DVTQ1UkQwQ1FPTDQ0USIsImV4cCI6MTcxOTk1ODQ1OSwicGFyZW50Ijoicm9vdCJ9.F_AWXy0iZoSdJNm6iWb5BccHh4Rr5U8rdeKQKVXkU6dBrM_j-Lxk4NJTpSTQzupFp2TwxCVQY1PPGzeu9hGvIQ&X-Amz-SignedHeaders=host&versionId=null&X-Amz-Signature=6b1b5d5b39bff021c0dc251fc9b645f2330d082a9efe8e9023e2df8c717158a1)
|
||||
|
||||
|
||||
#### 软件介绍
|
||||
##### 初始化界面
|
||||

|
||||
|
||||
+1
-1
Submodule iyuu updated: f7eed461a0...e62cfefe35
@@ -0,0 +1,18 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>运行日志</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>IYUU 日志信息</h1>
|
||||
<pre id="log-content"></pre>
|
||||
|
||||
<script>
|
||||
window.electron.onDisplayLog((logContent) => {
|
||||
document.getElementById('log-content').innerText = logContent;
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -1,14 +1,19 @@
|
||||
const { app } = require('electron')
|
||||
const path = require('node:path')
|
||||
const server = require('./server/server');
|
||||
const log = require('electron-log')
|
||||
log.initialize();
|
||||
console.log = log.log;
|
||||
log.transports.file.resolvePathFn = () => path.join(app.getPath('appData'), 'iyuu-plus/logs/iyuu.log');
|
||||
log.transports.file.format = '[{y}-{m}-{d} {h}:{i}:{s}.{ms}] [{level}]{scope} {text}';
|
||||
log.transports.file.encoding = 'utf8';
|
||||
|
||||
log.info('App is starting...');
|
||||
|
||||
const server = require('./server/server');
|
||||
const mainWin = require('./windows/app');
|
||||
|
||||
|
||||
app.whenReady().then(() => {
|
||||
log.transports.file.encoding = 'utf8';
|
||||
log.transports.file.file = path.join(app.getPath('userData'), 'logs/iyuu.log');
|
||||
log.transports.file.format = '{y}-{m}-{d} {h}:{i}:{s} {text}';
|
||||
log.info('App is starting...');
|
||||
|
||||
server.startServer()
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
const { app, Menu, BrowserWindow } = require("electron")
|
||||
const path = require('node:path')
|
||||
const fs = require('fs')
|
||||
const server = require('../server/server');
|
||||
const mainWin = require('../windows/app');
|
||||
|
||||
@@ -72,6 +73,42 @@ let template = [
|
||||
});
|
||||
}
|
||||
},
|
||||
{
|
||||
label: "查看日志",
|
||||
click: () => {
|
||||
let win = new BrowserWindow({
|
||||
width: 800,
|
||||
height: 600,
|
||||
icon: iconPath,
|
||||
webPreferences: {
|
||||
preload: path.join(__dirname, '..', 'preload.js'),
|
||||
contextIsolation: true,
|
||||
enableRemoteModule: false,
|
||||
nodeIntegration: false
|
||||
}
|
||||
});
|
||||
win.loadFile(path.join(__dirname, '..', 'logs.html'));
|
||||
win.on("closed", () => {
|
||||
win = null;
|
||||
});
|
||||
|
||||
const logsFile = path.join(app.getPath('appData'), 'iyuu-plus/logs/iyuu.log');
|
||||
fs.readFile(logsFile, 'utf8', (err, data) => {
|
||||
if (err) {
|
||||
console.error('Error reading log file:', err);
|
||||
return;
|
||||
}
|
||||
win.webContents.send('display-log', data);
|
||||
});
|
||||
}
|
||||
},
|
||||
{
|
||||
label: "下载日志",
|
||||
click: () => {
|
||||
const logsFile = path.join(app.getPath('appData'), 'iyuu-plus/logs/iyuu.log');
|
||||
mainWin.downloadLocalFile(logsFile);
|
||||
}
|
||||
},
|
||||
{
|
||||
label: "新疆萌森软件开发工作室提供技术支持",
|
||||
click: () => {
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "iyuu-plus",
|
||||
"version": "1.1.0",
|
||||
"version": "1.1.1",
|
||||
"description": "基于特征码的索引工具",
|
||||
"main": "main.js",
|
||||
"scripts": {
|
||||
|
||||
@@ -4,4 +4,11 @@ window.addEventListener('DOMContentLoaded', () => {
|
||||
script.src = 'https://analytics.lifebus.top/script.js';
|
||||
script.setAttribute('data-website-id', '5ca63d47-0739-4059-a480-40e7edf80ff9');
|
||||
document.head.appendChild(script);
|
||||
});
|
||||
|
||||
|
||||
const { contextBridge, ipcRenderer } = require('electron');
|
||||
|
||||
contextBridge.exposeInMainWorld('electron', {
|
||||
onDisplayLog: (callback) => ipcRenderer.on('display-log', (event, data) => callback(data))
|
||||
});
|
||||
+8
-1
@@ -108,4 +108,11 @@ const visibleWindows = () => {
|
||||
}
|
||||
|
||||
|
||||
module.exports = { hideWindows, showWindows, createWindow, closeWindows, refreshWindows, rebootWindows, visibleWindows, refreshUrl };
|
||||
const downloadLocalFile = (filePath) => {
|
||||
log.info('[Download local file]: ', filePath)
|
||||
if (mainWindow) {
|
||||
mainWindow.webContents.downloadURL('file://' + filePath)
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = { hideWindows, showWindows, createWindow, closeWindows, refreshWindows, rebootWindows, visibleWindows, refreshUrl, downloadLocalFile };
|
||||
Reference in New Issue
Block a user