confict resolve
commit
3daec70ef9
|
|
@ -1,3 +1,4 @@
|
||||||
{
|
{
|
||||||
"accentColor": ""
|
"accentColor": "#5ccef5",
|
||||||
|
"theme": "obsidian"
|
||||||
}
|
}
|
||||||
|
|
@ -0,0 +1,3 @@
|
||||||
|
[
|
||||||
|
"obsidian-image-auto-upload-plugin"
|
||||||
|
]
|
||||||
File diff suppressed because one or more lines are too long
|
|
@ -0,0 +1,10 @@
|
||||||
|
{
|
||||||
|
"id": "obsidian-image-auto-upload-plugin",
|
||||||
|
"name": "Image auto upload Plugin",
|
||||||
|
"version": "3.7.0",
|
||||||
|
"minAppVersion": "0.10.7",
|
||||||
|
"description": "This plugin uploads images from your clipboard by PicGo",
|
||||||
|
"author": "renmu",
|
||||||
|
"authorUrl": "https://github.com/renmu123/obsidian-image-auto-upload-plugin",
|
||||||
|
"isDesktopOnly": true
|
||||||
|
}
|
||||||
|
|
@ -1,14 +1,14 @@
|
||||||
{
|
{
|
||||||
"main": {
|
"main": {
|
||||||
"id": "fbdd3c33f4e33e58",
|
"id": "57d6290765cc5347",
|
||||||
"type": "split",
|
"type": "split",
|
||||||
"children": [
|
"children": [
|
||||||
{
|
{
|
||||||
"id": "2000e6aa523cc82e",
|
"id": "78ae62375ca7584d",
|
||||||
"type": "tabs",
|
"type": "tabs",
|
||||||
"children": [
|
"children": [
|
||||||
{
|
{
|
||||||
"id": "784f2fbfb6622f60",
|
"id": "849b0fcc9c548d22",
|
||||||
"type": "leaf",
|
"type": "leaf",
|
||||||
"state": {
|
"state": {
|
||||||
"type": "markdown",
|
"type": "markdown",
|
||||||
|
|
@ -18,71 +18,22 @@
|
||||||
"source": false
|
"source": false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"id": "7abb266d201c3bb5",
|
|
||||||
"type": "leaf",
|
|
||||||
"state": {
|
|
||||||
"type": "markdown",
|
|
||||||
"state": {
|
|
||||||
"file": "日志检索.md",
|
|
||||||
"mode": "source",
|
|
||||||
"source": false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"id": "fcca90a4313bff23",
|
|
||||||
"type": "leaf",
|
|
||||||
"state": {
|
|
||||||
"type": "markdown",
|
|
||||||
"state": {
|
|
||||||
"file": "日志检索.md",
|
|
||||||
"mode": "source",
|
|
||||||
"source": false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"id": "90f44bcb7cbd1134",
|
|
||||||
"type": "leaf",
|
|
||||||
"state": {
|
|
||||||
"type": "markdown",
|
|
||||||
"state": {
|
|
||||||
"file": "工具相关文档/git/Git 遇到的问题.md",
|
|
||||||
"mode": "source",
|
|
||||||
"source": false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"id": "b0885c2694804173",
|
|
||||||
"type": "leaf",
|
|
||||||
"state": {
|
|
||||||
"type": "markdown",
|
|
||||||
"state": {
|
|
||||||
"file": "开发中/本地版本的cos图床.md",
|
|
||||||
"mode": "source",
|
|
||||||
"source": false
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
],
|
]
|
||||||
"currentTab": 3
|
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"direction": "vertical"
|
"direction": "vertical"
|
||||||
},
|
},
|
||||||
"left": {
|
"left": {
|
||||||
"id": "764fe86898c5e1c2",
|
"id": "443207ae1217b08c",
|
||||||
"type": "split",
|
"type": "split",
|
||||||
"children": [
|
"children": [
|
||||||
{
|
{
|
||||||
"id": "9928bdabfbd04214",
|
"id": "b446f4c77d9ae3aa",
|
||||||
"type": "tabs",
|
"type": "tabs",
|
||||||
"children": [
|
"children": [
|
||||||
{
|
{
|
||||||
"id": "30e0a2943950d852",
|
"id": "a6f9bd0297ca6644",
|
||||||
"type": "leaf",
|
"type": "leaf",
|
||||||
"state": {
|
"state": {
|
||||||
"type": "file-explorer",
|
"type": "file-explorer",
|
||||||
|
|
@ -92,7 +43,7 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"id": "748cfc8b534af159",
|
"id": "a70b5ff078ce69dd",
|
||||||
"type": "leaf",
|
"type": "leaf",
|
||||||
"state": {
|
"state": {
|
||||||
"type": "search",
|
"type": "search",
|
||||||
|
|
@ -107,7 +58,7 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"id": "f66854680163dc9a",
|
"id": "f26651f9475e8e05",
|
||||||
"type": "leaf",
|
"type": "leaf",
|
||||||
"state": {
|
"state": {
|
||||||
"type": "bookmarks",
|
"type": "bookmarks",
|
||||||
|
|
@ -121,20 +72,20 @@
|
||||||
"width": 300
|
"width": 300
|
||||||
},
|
},
|
||||||
"right": {
|
"right": {
|
||||||
"id": "20a380cfba177122",
|
"id": "4e3568ea391b3808",
|
||||||
"type": "split",
|
"type": "split",
|
||||||
"children": [
|
"children": [
|
||||||
{
|
{
|
||||||
"id": "ab4030f1e1614368",
|
"id": "0cbe374acd5d119f",
|
||||||
"type": "tabs",
|
"type": "tabs",
|
||||||
"children": [
|
"children": [
|
||||||
{
|
{
|
||||||
"id": "fb8f594511a84cdf",
|
"id": "3f62268571390df0",
|
||||||
"type": "leaf",
|
"type": "leaf",
|
||||||
"state": {
|
"state": {
|
||||||
"type": "backlink",
|
"type": "backlink",
|
||||||
"state": {
|
"state": {
|
||||||
"file": "工具相关文档/git/Git 遇到的问题.md",
|
"file": "日志检索.md",
|
||||||
"collapseAll": false,
|
"collapseAll": false,
|
||||||
"extraContext": false,
|
"extraContext": false,
|
||||||
"sortOrder": "alphabetical",
|
"sortOrder": "alphabetical",
|
||||||
|
|
@ -146,19 +97,19 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"id": "3c69a81fe677de58",
|
"id": "40cf8b1d1917faf9",
|
||||||
"type": "leaf",
|
"type": "leaf",
|
||||||
"state": {
|
"state": {
|
||||||
"type": "outgoing-link",
|
"type": "outgoing-link",
|
||||||
"state": {
|
"state": {
|
||||||
"file": "工具相关文档/git/Git 遇到的问题.md",
|
"file": "日志检索.md",
|
||||||
"linksCollapsed": false,
|
"linksCollapsed": false,
|
||||||
"unlinkedCollapsed": true
|
"unlinkedCollapsed": true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"id": "ea3d7ce319ae92e0",
|
"id": "8273fe1d7b21e20e",
|
||||||
"type": "leaf",
|
"type": "leaf",
|
||||||
"state": {
|
"state": {
|
||||||
"type": "tag",
|
"type": "tag",
|
||||||
|
|
@ -169,12 +120,12 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"id": "457117b79d0ab7f7",
|
"id": "2311921891a9e31d",
|
||||||
"type": "leaf",
|
"type": "leaf",
|
||||||
"state": {
|
"state": {
|
||||||
"type": "outline",
|
"type": "outline",
|
||||||
"state": {
|
"state": {
|
||||||
"file": "工具相关文档/git/Git 遇到的问题.md"
|
"file": "日志检索.md"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -195,43 +146,6 @@
|
||||||
"command-palette:打开命令面板": false
|
"command-palette:打开命令面板": false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"active": "90f44bcb7cbd1134",
|
"active": "849b0fcc9c548d22",
|
||||||
"lastOpenFiles": [
|
"lastOpenFiles": []
|
||||||
"工具相关文档/git/Git 笔记.md",
|
|
||||||
"工具相关文档/git/Git 遇到的问题.md",
|
|
||||||
"语言/Rust/2024-06-06.md",
|
|
||||||
"语言/Rust/Rust学习笔记一.md",
|
|
||||||
"博文计划/待写博客.md",
|
|
||||||
"日志检索.md",
|
|
||||||
"未分类日志.md",
|
|
||||||
"工具相关文档/VSCode/VSCode 连接 云服务器.md",
|
|
||||||
"工具相关文档/VSCode/VSCode 文件嵌套.md",
|
|
||||||
"工具相关文档/VSCode/VSCode 相关.md",
|
|
||||||
"博客/docker 安装 wordpress.md",
|
|
||||||
"web/Rollup 学习.md",
|
|
||||||
"web/ESBuild 学习.md",
|
|
||||||
"web/lint/前端开发中的lint.md",
|
|
||||||
"Android Hilt.md",
|
|
||||||
"web/lint",
|
|
||||||
"工具相关文档/Android Studio",
|
|
||||||
"README.md",
|
|
||||||
"开发中/Vue3 + 腾讯COS文件上传.md",
|
|
||||||
"工具相关文档/git",
|
|
||||||
"工具相关文档/未命名.md",
|
|
||||||
"开发愿望清单.md",
|
|
||||||
"开发中/本地版本的cos图床.md",
|
|
||||||
"工具相关文档/VSCode",
|
|
||||||
"未命名",
|
|
||||||
"工具相关文档/Obsidian 使用笔记.md",
|
|
||||||
"开发中/RayC后台开发日志.md",
|
|
||||||
"gitea.md",
|
|
||||||
"开发中",
|
|
||||||
"博客/Android/相机/Android Camera2 在预览时,录制视频.md",
|
|
||||||
"Bug日志/后端 -- Bug记录.md",
|
|
||||||
"极客时间学习/Nginx_geek/核心基础.md",
|
|
||||||
"语言/Kotlin",
|
|
||||||
"语言",
|
|
||||||
"文档编写/PRD",
|
|
||||||
"文档编写"
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
|
|
@ -0,0 +1,5 @@
|
||||||
|
测试图片上传
|
||||||
|

|
||||||
|
- [腾讯云 COS 配置PicGo访问](https://cloud.tencent.com/document/product/436/74373)
|
||||||
|
- Obsiandian 安装 **Image Auto Upload** 插件,然后再插件中配置未PicGo,先安装了PicGo后,会自动配置好相关的,实现如上图片的粘贴上传
|
||||||
|
- 
|
||||||
|
|
@ -0,0 +1,135 @@
|
||||||
|
## 安装Electron
|
||||||
|
- 使用npm初始化一个项目 `npm init`
|
||||||
|
- 项目内新增`.npmrc` 内容如下
|
||||||
|
```
|
||||||
|
# 添加
|
||||||
|
registry=https://registry.npmmirror.com
|
||||||
|
#
|
||||||
|
ELECTRON_MIRROR=https://npmmirror.com/mirrors/electron/
|
||||||
|
ELECTRON_CUSTOM_DIR={{ version }}
|
||||||
|
```
|
||||||
|
- 再使用 `npm install --save-dev electron`, 安装之前先把electron安装失败的cache删除掉
|
||||||
|
## Electron 打包
|
||||||
|
ubuntu 安装 `rpmbuild` [参考博客](https://juejin.cn/s/ubuntu%20%E5%AE%89%E8%A3%85rpmbuild)
|
||||||
|
|
||||||
|
## Vue3 + Electron
|
||||||
|
- 使用vite初始化一个`vue-ts` 的项目
|
||||||
|
- 安装`Electron` 相关的依赖
|
||||||
|
- `electron`
|
||||||
|
- `electron-builder`
|
||||||
|
- `electron-devtools-installer`
|
||||||
|
- `rimraf`
|
||||||
|
- [`vite-plugin-electron`](https://github.com/electron-vite/vite-plugin-electron)
|
||||||
|
- [`vite-plugin-electron-preload`](https://github.com/electron-vite/vite-plugin-electron-preload) 不配置加载preload会失败
|
||||||
|
- [`vite-plugin-electron-renderer`](https://github.com/electron-vite/vite-plugin-electron-renderer) 目前没有配置相关内容
|
||||||
|
- 注意:
|
||||||
|
- 根据vite-plugin-electron 配置项目,并运行即可
|
||||||
|
- 运行时可能会出现 `electron` 安装失败,把 `node_modules` 删除,删除掉 pnpm的lock yaml,和系统的electron的缓存,多安装几次,这个确实有点烦人
|
||||||
|
- 使用 `vite-plugin-electron` 之后,还需要使用 `vite-plugin-electron-preload` 才能正确加载preload
|
||||||
|
|
||||||
|
## Vue3 + Electron
|
||||||
|
- 使用`electron-builder` 打包
|
||||||
|
- 在项目的根目录下创建一个 `electron-builder.json`
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"productName": "ElectronViteVue3",
|
||||||
|
"appId": "top.rayc.electrontest",
|
||||||
|
"copyright": "Copyright © 2024-present Andy",
|
||||||
|
"compression": "maximum",
|
||||||
|
"asar": true,
|
||||||
|
"directories": {
|
||||||
|
"output": "release/${version}"
|
||||||
|
},
|
||||||
|
"nsis": {
|
||||||
|
"oneClick": false,
|
||||||
|
"allowToChangeInstallationDirectory": true,
|
||||||
|
"perMachine": true,
|
||||||
|
"deleteAppDataOnUninstall": true,
|
||||||
|
"createDesktopShortcut": true,
|
||||||
|
"createStartMenuShortcut": true,
|
||||||
|
"shortcutName": "ElectronVite4Vue3"
|
||||||
|
},
|
||||||
|
"win": {
|
||||||
|
"icon": "./resource/shortcut.ico",
|
||||||
|
"artifactName": "${productName}-v${version}-${platform}-${arch}-setup.${ext}",
|
||||||
|
"target": [
|
||||||
|
{
|
||||||
|
"target": "nsis",
|
||||||
|
"arch": ["ia32"]
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"mac": {
|
||||||
|
"icon": "./resource/shortcut.icns",
|
||||||
|
"artifactName": "${productName}-v${version}-${platform}-${arch}-setup.${ext}"
|
||||||
|
},
|
||||||
|
"linux": {
|
||||||
|
"icon": "./resource",
|
||||||
|
"artifactName": "${productName}-v${version}-${platform}-${arch}-setup.${ext}"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
- 使用 `electron-builder` 命令安装就行
|
||||||
|
- 注意:
|
||||||
|
- 在使用 `electron-builder` 打包需要下载几个压缩包,但是下载会失败,可以手动下载这些压缩包,把这些压缩包,保存到 `electron` 的 `Cache` 目录中
|
||||||
|
|
||||||
|
## Electron 取消顶部菜单栏
|
||||||
|
- 在 主进程程序中进行修改
|
||||||
|
- 引入菜单 `Menu`
|
||||||
|
```TypeScript
|
||||||
|
import { Menu } from "electron"
|
||||||
|
```
|
||||||
|
- 在 `createWindow` 方法中进行设置
|
||||||
|
```TypeScript
|
||||||
|
const createWindow = () => {
|
||||||
|
Menu.setApplicationMenu(null);
|
||||||
|
const win = new BrowserWindow({
|
||||||
|
title: "Electron + Vite",
|
||||||
|
webPreferences: {
|
||||||
|
contextIsolation: false, // 是否开启隔离上下文
|
||||||
|
nodeIntegration: true, // 渲染进程使用 Node.js API
|
||||||
|
// sandbox: false,
|
||||||
|
preload: path.join(__dirname, "preload.js"), // 预加载脚本
|
||||||
|
},
|
||||||
|
});
|
||||||
|
if (process.env.VITE_DEV_SERVER_URL) {
|
||||||
|
win.loadURL(process.env.VITE_DEV_SERVER_URL);
|
||||||
|
win.webContents.openDevTools();
|
||||||
|
} else {
|
||||||
|
// Load your file
|
||||||
|
win.loadFile("dist/index.html");
|
||||||
|
}
|
||||||
|
// 开启调试工具
|
||||||
|
};
|
||||||
|
```
|
||||||
|
|
||||||
|
## Electron 错误
|
||||||
|
`Uncaught TypeError: path.join is not a function at node_modules/electron/index.js`
|
||||||
|
解决办法: [参考博客](https://blog.csdn.net/q1003675852/article/details/134774965)
|
||||||
|
- 安装 `vite-plugin-optimizer`
|
||||||
|
- 在 `vite.config.ts` 中配置
|
||||||
|
```ts
|
||||||
|
import { defineConfig } from "vite";
|
||||||
|
import vue from "@vitejs/plugin-vue";
|
||||||
|
import electron from "vite-plugin-electron/simple";
|
||||||
|
import optimizer from "vite-plugin-optimizer";
|
||||||
|
|
||||||
|
// https://vitejs.dev/config/
|
||||||
|
export default defineConfig({
|
||||||
|
plugins: [
|
||||||
|
vue(),
|
||||||
|
electron({
|
||||||
|
main: {
|
||||||
|
entry: "electron/main.ts",
|
||||||
|
},
|
||||||
|
preload: {
|
||||||
|
input: "electron/preload.ts",
|
||||||
|
},
|
||||||
|
}),
|
||||||
|
// 加载ipcRenderer
|
||||||
|
optimizer({
|
||||||
|
electron: `const { ipcRenderer } = require("electron"); export { ipcRenderer};`,
|
||||||
|
}),
|
||||||
|
],
|
||||||
|
});
|
||||||
|
```
|
||||||
|
|
@ -25,4 +25,19 @@
|
||||||
- merge -- 代码合并
|
- merge -- 代码合并
|
||||||
- sync 同步主线或分支的bug
|
- sync 同步主线或分支的bug
|
||||||
- scope(可选) : 说明commit影响的范围
|
- scope(可选) : 说明commit影响的范围
|
||||||
- subject (必填):commit 目的的简短描述
|
- subject (必填):commit 目的的简短描述
|
||||||
|
|
||||||
|
|
||||||
|
### git 同步个人私有库
|
||||||
|
在同步个人的私有库时,如果没有配置用户名和密码,会出现如下错误:
|
||||||
|
`-fatal: repository not found`
|
||||||
|
这个原因
|
||||||
|
- 因为没有访问权限,配置用户名和密码,访问令牌没有正确提供
|
||||||
|
- url错误
|
||||||
|
使用访问令牌访问私有仓库
|
||||||
|
`git clone https://access-token@github.com/user_name/repository.git`
|
||||||
|
- accesstoken 是颁发的令牌
|
||||||
|
- @后面是正常情况下的url
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
6
日志检索.md
6
日志检索.md
|
|
@ -49,4 +49,8 @@
|
||||||
|
|
||||||
|
|
||||||
## 2024-04-24
|
## 2024-04-24
|
||||||
- [[Android Hilt]]e e
|
- [[Android Hilt]]e
|
||||||
|
|
||||||
|
## 2024-04-26
|
||||||
|
- [[Obsidian + PicGo + 腾讯云COS 图床配置]]
|
||||||
|
75d75761da072293fca411ec93674099c4bd65e9
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,3 @@
|
||||||
|
|
||||||
|
#### IM自定义协议组成结构 (例子)
|
||||||
|
`魔数+版本号+序列化方式+指令+数据长度+数据`
|
||||||
Loading…
Reference in New Issue