-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathatom.xml
501 lines (251 loc) · 50.2 KB
/
atom.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
<title>Powersee的博客</title>
<link href="https://powersee.github.io/atom.xml" rel="self"/>
<link href="https://powersee.github.io/"/>
<updated>2024-12-05T06:19:02.645Z</updated>
<id>https://powersee.github.io/</id>
<author>
<name>powersee</name>
</author>
<generator uri="https://hexo.io/">Hexo</generator>
<entry>
<title>迁移 fathom 到另一台服务器</title>
<link href="https://powersee.github.io/2024/12/fathom2/"/>
<id>https://powersee.github.io/2024/12/fathom2/</id>
<published>2024-12-05T06:18:04.000Z</published>
<updated>2024-12-05T06:19:02.645Z</updated>
<content type="html"><![CDATA[<p><a href="/2023/04/fathom/">前文回顾</a></p><p>如今 fathom 这个服务我已经运行了一年多了,感觉也还行吧,很轻量,不怎么占用服务器资源。但是会被浏览器广告拦截插件,给屏蔽。所以我后来是再加了一个 umami。</p><p>最近服务器要到期了,我需要迁移 fathom 到另一台服务器上。</p><p>已知数据库 <code>fathom.db</code> 在 <code>/app</code> 下,那么可以使用命令</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">docker cp fathom:/app/fathom.db .</span><br></pre></td></tr></table></figure><p>将它从 docker 容器中复制出来。</p><p>在新的服务器上面,先创建容器</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">docker create -p 8080:8080 --name fathom usefathom/fathom:latest</span><br></pre></td></tr></table></figure><p>把数据库 fathom.db 复制到新服务器上,再复制到刚才创建的 docker 容器中。</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">docker cp fathom.db fathom:/app/</span><br></pre></td></tr></table></figure><p>然后再启动容器</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">docker start fathom</span><br></pre></td></tr></table></figure><p>这样便迁移完成了。</p>]]></content>
<summary type="html"><p><a href="/2023/04/fathom/">前文回顾</a></p>
<p>如今 fathom 这个服务我已经运行了一年多了,感觉也还行吧,很轻量,不怎么占用服务器资源。但是会被浏览器广告拦截插件,给屏蔽。所以我后来是再加了一个 umami。</p>
<p>最近服</summary>
<category term="服务器" scheme="https://powersee.github.io/tags/%E6%9C%8D%E5%8A%A1%E5%99%A8/"/>
</entry>
<entry>
<title>威联通 qnap 外接硬盘挂载失败记录</title>
<link href="https://powersee.github.io/2024/10/qnap-mount-fail/"/>
<id>https://powersee.github.io/2024/10/qnap-mount-fail/</id>
<published>2024-10-28T07:49:57.000Z</published>
<updated>2024-10-28T07:51:33.360Z</updated>
<content type="html"><![CDATA[<p>我的 NAS 是威联通 TS-451D,它的正面有一个 USB 接口,不知什么时候开始,通过这个接口连接移动硬盘,无法成功挂载。</p><p><img src="/img/2024/can't-mount.webp" alt="can't-mount"></p><p>如图所示,会提示:<strong>磁盘群组无法被挂载或识别。</strong></p><p>但是它可以识别到硬盘的容量,而且我试过插一个 U 盘上去,可以正常挂载。按理说这个口应该没问题才对,搞不懂。</p><p>难道是我的硬盘有问题?但是我连接电脑却是可以正常读取的。于是,我把移动硬盘,连接到 NAS 后面的 USB 口,然后,就可以正常读写了。</p><p><img src="/img/2024/mount.webp" alt="mount"></p><p>也是挺奇怪的,我试了好几块硬盘,都是前面的 USB 口,可以识别到硬盘容量,但是没法挂载。使用后面的 USB 口就正常。</p><p>难道是前面的 USB 口现在供电不足了?所以连接 U 盘可以,移动硬盘不行?不清楚,本文仅仅记录一下。</p>]]></content>
<summary type="html"><p>我的 NAS 是威联通 TS-451D,它的正面有一个 USB 接口,不知什么时候开始,通过这个接口连接移动硬盘,无法成功挂载。</p>
<p><img src="/img/2024/can't-mount.webp" alt="can&#39;t-mount"></p>
</summary>
<category term="qnap" scheme="https://powersee.github.io/tags/qnap/"/>
</entry>
<entry>
<title>Mac 上的开源键盘映射应用——Karabiner-Elements</title>
<link href="https://powersee.github.io/2024/10/Karabiner-Elements/"/>
<id>https://powersee.github.io/2024/10/Karabiner-Elements/</id>
<published>2024-10-19T07:01:28.000Z</published>
<updated>2024-10-19T07:02:01.342Z</updated>
<content type="html"><![CDATA[<p>最近在看漫画,需要经常使用到 pgdn 这颗按键,来切换到下一页。</p><p>但是它在键盘的顶部,我的手需要伸长去按。于是我现在的需求,就是想把键盘右下角,小键盘区域的回车键,映射到 pgdn 上。</p><p>当我按下小键盘的回车键,效果就相当于按下 pgdn。</p><p>然后我就发现了这个软件 <a href="https://github.com/pqrs-org/Karabiner-Elements">Karabiner-Elements</a></p><p>在 GitHub 上面有 18.7 k 的 star,只有 Mac 版本。</p><blockquote><p>Supported systems</p><ul><li>macOS 15 Sequoia<ul><li>Both Intel-based Macs 和 Apple Silicon Macs</li></ul></li><li>macOS 14 Sonoma<ul><li>Both Intel-based Macs 和 Apple Silicon Macs</li></ul></li><li>macOS 13 Ventura<ul><li>Both Intel-based Macs 和 Apple Silicon Macs</li></ul></li></ul></blockquote><p><img src="/img/2024/Karabiner-Elements.webp" alt="Karabiner-Elements"></p><p>应用下载后打开,如上图这样设置一下,就可以实现我的目的了。</p>]]></content>
<summary type="html"><p>最近在看漫画,需要经常使用到 pgdn 这颗按键,来切换到下一页。</p>
<p>但是它在键盘的顶部,我的手需要伸长去按。于是我现在的需求,就是想把键盘右下角,小键盘区域的回车键,映射到 pgdn 上。</p>
<p>当我按下小键盘的回车键,效果就相当于按下 pgdn。</</summary>
<category term="Mac" scheme="https://powersee.github.io/tags/Mac/"/>
</entry>
<entry>
<title>在 Windows 的搜狗输入法中,输出直角引号「」</title>
<link href="https://powersee.github.io/2024/09/win-sougou-punctuation/"/>
<id>https://powersee.github.io/2024/09/win-sougou-punctuation/</id>
<published>2024-09-09T03:17:29.000Z</published>
<updated>2024-09-09T03:20:46.502Z</updated>
<content type="html"><![CDATA[<p>默认情况下,在 Windows 的搜狗输入法中,直接按方括号键,得到的是 <code>【】</code></p><p>而我想要的是 <code>「」</code>,要怎么打出来呢?</p><p>可以在状态栏,右键搜狗图标,选择「符号大全」,在里面它叫「左角括号」。</p><p><img src="/img/2024/sougou-fuhao.png" alt="sougou-fuhao"></p><p>如果使用频繁,这么去点选,效率就太低了。</p><p>我也尝试过,到设置里面,更改自定义标点,但是没法改为这个「左右角括号」。</p><p>所以接下来将通过修改输入法的配置文件,来实现自定义标点,最终的效果,就是我按下方括号键 <code>[</code> 就可以直接得到直角引号 <code>「</code></p><p>我的搜狗没有登录账号,所以这个配置文件的路径是</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">%USERPROFILE%\AppData\LocalLow\SogouPY</span><br></pre></td></tr></table></figure><p>把这个地址粘贴到「资源管理器」的地址栏中,然后按下回车键即可打开文件夹。</p><p>这里面有一个<code>punctures.ini</code> 文件,我们需要修改里面的内容。选中它,然后右键「编辑」,就可以使用记事本来打开它。</p><p>里面是搜狗输入法独有的键值代码,网上好像也找不到这些代码的对应表。</p><blockquote><p>左右方括号的代码是<code>[flaafl]</code>和<code>[fnaafn]</code>,我们可以通过搜索来找到它们。</p></blockquote><p>我们观察配置文件,发现这两个的 ChHalf 和 ChFull 的值是一样的,这意味着,在半角和全角状态下,按下左右方括号键,得到的都是【】</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">[flaafl]</span><br><span class="line">Name=flaaaaaafl</span><br><span class="line">ChHalf=badaaaaaca</span><br><span class="line">ChFull=badaaaaaca</span><br><span class="line"></span><br><span class="line">[fmaafm]</span><br><span class="line">xxxxxxx</span><br><span class="line"></span><br><span class="line">[fnaafn]</span><br><span class="line">Name=fnaaaaaafn</span><br><span class="line">ChHalf=bbdaaaaacb</span><br><span class="line">ChFull=bbdaaaaacb</span><br></pre></td></tr></table></figure><p>于是我只要修改 chhalf 后面的值就可以了。结果变成这样</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">[flaafl]</span><br><span class="line">Name=flaaaaaafl</span><br><span class="line">ChHalf=amdaaaaadm</span><br><span class="line">ChFull=badaaaaaca</span><br><span class="line"></span><br><span class="line">[fmaafm]</span><br><span class="line">xxx</span><br><span class="line"></span><br><span class="line">[fnaafn]</span><br><span class="line">Name=fnaaaaaafn</span><br><span class="line">ChHalf=andaaaaadn</span><br><span class="line">ChFull=bbdaaaaacb</span><br></pre></td></tr></table></figure><p>电脑重启之后就生效了。</p><p>这里的 amdaaaaadm 和 andaaaaadn 对应的是「 和 」。</p><p>参考:<a href="https://lainbo.com/article/sogou-input-straight-quotes">在Windows中,搜狗输入法输出直角引号「」的优雅方式 | Lainbo’s Blog</a></p>]]></content>
<summary type="html"><p>默认情况下,在 Windows 的搜狗输入法中,直接按方括号键,得到的是 <code>【】</code></p>
<p>而我想要的是 <code>「」</code>,要怎么打出来呢?</p>
<p>可以在状态栏,右键搜狗图标,选择「符号大全」,在里面它叫「左角括号」。</p</summary>
<category term="Windows" scheme="https://powersee.github.io/tags/Windows/"/>
</entry>
<entry>
<title>写 markdown 时中英文切换频繁?Mac 版搜狗输入法的解决方案</title>
<link href="https://powersee.github.io/2024/09/mac-sougou-zh-en/"/>
<id>https://powersee.github.io/2024/09/mac-sougou-zh-en/</id>
<published>2024-09-08T14:51:44.000Z</published>
<updated>2024-09-08T15:05:09.792Z</updated>
<content type="html"><![CDATA[<p>从我了解 markdown 距今也好几年了,目前主力的笔记工具,是付费软件 Typora,它默认新建的文档,就是 md 结尾的 markdown 文件。</p><p>这种语言给文本设置格式的时候,得使用英文的标点符号。因此经常需要按 shift 键来切换中英状态。</p><p>比如说,我现在用中文打字中,然后需要用到引用块,那么需要打出 > 这个符号,因此需要先切换为英文,打出大于号 > 然后再切换回中文,继续打字。</p><p>不过目前我找到了一个还不错的解决方案——「让输入法在中文状态下,某些按键打出的是英文标点符号」。</p><p>其实直接在中文状态下,使用全英文标点符号,是最简单的解决方案。但是我不打算用这种,因为平时常用的逗号和句号这些,还是用中文的全角符号,看起来比较美观。</p><p>平时我常用的格式,就是一二三级标题,手动输入是 <code>#</code>,不过我很少手动,设置标题用快捷键就行。cmd + 1 这样。</p><p>还有就是 <code>代码</code> 和</p><blockquote><p>引用</p></blockquote><p>这两种格式,我之前一般都是切换到英文状态下,来输入 <code>`</code> 和 <code>></code> 的。</p><p>而现在,我不需要按 shift 键来切换了。因为在 Mac 的搜狗输入法里,有一个「符号替换」功能。</p><p><img src="/img/2024/Punctuation-replace.webp" alt="Punctuation-replace"></p><p>里面默认就有几条规则,我们可以点击左下角的 + 来新建规则。</p><p><img src="/img/2024/replace-2.jpg" alt="replace-2"></p><p>它会出现两个输入框,第一个只能用英文输入法来输入字符,第二个就可以用中文。</p><p>我是这么操作的:</p><ol><li>第一个框,按一下波浪键,第二个框,切换到英文状态,按一下波浪键。</li><li>第一个框,按 shift + 大于号键,也就是输入一个大于号。第二个框,切换到英文状态,同样输入一个大于号 >。</li></ol><p>然后就 OK 了。</p><p>其实我觉得它这里的逻辑是可以优化一下的,让第一个框,也可以输入中文标点,会比较直观一些。</p><p>这样操作之后呢,我就没法打出 <code>》</code> 这个右书名号了。不过不重要,我基本没怎么使用过这个符号。</p><p>如果真要打出来,也是可以的,按快捷键 <code>Ctrl + shift + e</code> 就可以呼出「符号菜单」,在里面找就行。</p><p><img src="/img/2024/mac-sougou-fuhao.webp" alt="mac-sougou-fuhao"></p>]]></content>
<summary type="html"><p>从我了解 markdown 距今也好几年了,目前主力的笔记工具,是付费软件 Typora,它默认新建的文档,就是 md 结尾的 markdown 文件。</p>
<p>这种语言给文本设置格式的时候,得使用英文的标点符号。因此经常需要按 shift 键来切换中英状态。</p></summary>
<category term="Mac" scheme="https://powersee.github.io/tags/Mac/"/>
</entry>
<entry>
<title>Typora Mac 版本如何打开开发人员工具?</title>
<link href="https://powersee.github.io/2024/08/typora-macos-debug/"/>
<id>https://powersee.github.io/2024/08/typora-macos-debug/</id>
<published>2024-08-18T08:56:04.000Z</published>
<updated>2024-08-18T08:56:43.098Z</updated>
<content type="html"><![CDATA[<p>目前我 Mac 上的 Typora 已经升级到了 1.9.4 版本,现在我找不到调出「开发人员工具」的地方。</p><p>以前的版本,我记得在设置里面,勾选上开发工具,然后在编辑页面右键就行,现在没有了。</p><p>目前新版本,需要通过 Safari 才行。</p><p>先打开 Typora,然后打开 Safari 浏览器,点击上方的「开发」,第三行就是我们机器的名字和系统版本,鼠标放上去,就可以在右边看到 Typora。</p><p><img src="/img/2024/Safari-debug-Typora.webp" alt="Safari-debug-Typora"></p><p>我这里在 Typora 打开了 3 个文档,所以这里有 3 个选项,鼠标放到对应选项时,后面的文档会高亮起来。</p><p><img src="/img/2024/Typora-debug.webp" alt="Typora-debug"></p><p>点击之后就可以打开对应文档的「开发人员工具」了。</p><p>参考:<a href="https://support.typoraio.cn/Debug-Themes/">Debug Themes / CSS - Typora Support</a></p>]]></content>
<summary type="html"><p>目前我 Mac 上的 Typora 已经升级到了 1.9.4 版本,现在我找不到调出「开发人员工具」的地方。</p>
<p>以前的版本,我记得在设置里面,勾选上开发工具,然后在编辑页面右键就行,现在没有了。</p>
<p>目前新版本,需要通过 Safari 才行。</p>
</summary>
<category term="Mac" scheme="https://powersee.github.io/tags/Mac/"/>
</entry>
<entry>
<title>Windows 10 无法连接上 Xbox 手柄</title>
<link href="https://powersee.github.io/2024/08/xbox-controller-remove-failed/"/>
<id>https://powersee.github.io/2024/08/xbox-controller-remove-failed/</id>
<published>2024-08-16T17:33:51.000Z</published>
<updated>2024-08-16T17:35:09.537Z</updated>
<content type="html"><![CDATA[<p><img src="/img/2024/xbox-controller-keling.webp" alt="xbox-controller-keling"></p><p>又一次被这个 Xbox 手柄折磨了。</p><p>原本这个手柄在我的 win10 台式机上面,是可以正常使用的。然而前段时间,我拿另外一台电脑,通过蓝牙连接这个手柄。</p><p>手柄好像认了新电脑当主人之后,就连接不上旧电脑了。</p><p>那按理来说,我把手柄和旧电脑,重新匹配一下就好呗。然而事情没有这么简单。</p><p><img src="/img/2024/xbox-controller-remove-failed.png" alt="xbox-controller-remove-failed"></p><p>因为我在 Windows 的蓝牙设置里,没法删掉 Xbox 手柄。点击删除设备会提示「删除失败」。</p><p>而不删除的话,我让手柄进入配对模式,此时电脑是搜索不到手柄的,也就没法连接了。</p><h3 id="尝试方案一"><a href="#尝试方案一" class="headerlink" title="尝试方案一"></a>尝试方案一</h3><p>打开「设备管理器」,把上方的「查看」里面的「显示隐藏的设备」勾选上。</p><p>然后把里面的蓝牙设备都卸载掉。</p><p>我这边卸载后,还是没法连接上手柄。</p><h3 id="尝试方案二"><a href="#尝试方案二" class="headerlink" title="尝试方案二"></a>尝试方案二</h3><p>安装一个蓝牙命令行工具 <a href="https://bluetoothinstaller.com/bluetooth-command-line-tools">Bluetooth command line tools</a></p><p>安装这个主要为了使用 btpair 这个命令,网页上对它的介绍是</p><blockquote><p>Performs pairing with remote bluetooth devices.<br>与远程蓝牙设备进行配对。</p></blockquote><p>不过这个软件好像有点老了,最新的版本距今也接近 12 年。</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">Version history</span><br><span class="line">1.2.0.56 Nov 2, 2012</span><br><span class="line">Minor improvements and new featues in btconfig, btpair and bcom</span><br><span class="line">Windows 8 support.</span><br></pre></td></tr></table></figure><p>看到它这么久没更新了,我其实是有些怀疑的,老软件到底能不能解决新机器的问题呢?</p><p>最终实测是有效果,从官网下载并安装 <code>BluetoothCLTools-1.2.0.56.exe</code>,然后打开 powershell,执行 <code>btpair -u</code>,删除所有匹配过的蓝牙设备。</p><p>之后的我手柄进入匹配模式,电脑搜索蓝牙信号,就可以搜索到,然后成功连接上了。</p><p>这不是我第一次被蓝牙连接 xbox 手柄所困扰,我相信也不会是最后一次。我记得上次我是在设备管理器里面,删除 Microsoft 开头的蓝牙设备后,就可以连接手柄了。</p><p>但是这次不行,所以我找到新的方法,也成功解决了问题。这里我就把过程记录下来,希望后面其他玩家遇到同样的问题时,可以搜索到吧。</p>]]></content>
<summary type="html"><p><img src="/img/2024/xbox-controller-keling.webp" alt="xbox-controller-keling"></p>
<p>又一次被这个 Xbox 手柄折磨了。</p>
<p>原本这个手柄在我的 win10 台式机上面,是可以</summary>
<category term="Windows" scheme="https://powersee.github.io/tags/Windows/"/>
<category term="Xbox" scheme="https://powersee.github.io/tags/Xbox/"/>
</entry>
<entry>
<title>Windows 11 资源管理器的地址栏消失了</title>
<link href="https://powersee.github.io/2024/08/windows11-address-bar-missing/"/>
<id>https://powersee.github.io/2024/08/windows11-address-bar-missing/</id>
<published>2024-08-16T05:21:46.000Z</published>
<updated>2024-08-16T05:24:10.731Z</updated>
<content type="html"><![CDATA[<p>最近打开一台很久没开机的 win11 电脑,使用了一下,然后系统提示更新。</p><p>等它更新完成之后,我打开资源管理器,发现地址栏不见了。</p><p><img src="/img/2024/startallback-win7.webp" alt="startallback-win7"></p><p>看来应该和这次更新有关,网上搜索一下,有网友也遇过这样的问题,他的解决方案是,到设置里面回滚更新,好像可以退回到更新前的状态。</p><p>不过我不想这么做,继续了解,有人讲到是电脑安装 StartAllBack 这个软件导致的。需要在软件的设置里面,把「资源管理器样式」改回 Win11 就行。</p><p>(提醒一下,StartAllBack 这个软件安装后,是没有 APP 图标的,想要再次进入软件的设置界面,需要把鼠标放在「开始菜单」的位置,然后右键,选择「属性」。)</p><p><img src="/img/2024/startallback-win11.webp" alt="startallback-win11"></p><p>果然如此,我改回 Win11 之后,资源管理器的地址栏就再次出现了。</p><p><img src="/img/2024/win11-explorer-ok.webp" alt="win11-explorer-ok"></p><p>不过这个问题其实也可以通过,更新 StartAllBack 的软件版本来解决,新版本依然可以使用 win10 的样式。</p>]]></content>
<summary type="html"><p>最近打开一台很久没开机的 win11 电脑,使用了一下,然后系统提示更新。</p>
<p>等它更新完成之后,我打开资源管理器,发现地址栏不见了。</p>
<p><img src="/img/2024/startallback-win7.webp" alt="startall</summary>
<category term="Windows" scheme="https://powersee.github.io/tags/Windows/"/>
</entry>
<entry>
<title>Nu shell 的自定义命令(函数)笔记</title>
<link href="https://powersee.github.io/2024/08/nu-shell-def/"/>
<id>https://powersee.github.io/2024/08/nu-shell-def/</id>
<published>2024-08-12T15:39:09.000Z</published>
<updated>2024-08-12T15:44:17.423Z</updated>
<content type="html"><![CDATA[<p>由于我经常使用 yt-dlp 来下载视频或者音频,所以之前已经给 nu shell 添加了 alias,把 yt-dlp 缩短为 yt。</p><p>但是我平时喜欢把音频,直接下载到一个特定的目录里面。所以使用命令行,我需要先 cd xxxx,然后再执行 yt xxxx。</p><p>在 Mac 上面我使用的是 zsh,所以写一条 alias</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">alias ya="cd xxxx && yt-dlp --format 'bestaudio[ext!=webm]'"</span><br></pre></td></tr></table></figure><p>然后平时就执行 ya url,就可以下载到 url 对应的音频了。</p><p>但是我发现,在 nu shell 这边的 alias,没法这么用,即使我已经知道它不能使用 <code>&&</code>,得使用 <code>;</code> 才对。</p><p>在这边我也是折腾了不少时间,使用 alias 应该是没法达到我的目的了。</p><p>所以我寻找其它的方法——<a href="https://www.nushell.sh/zh-CN/book/custom_commands.html">自定义命令 | Nushell</a></p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">def yda [url:string] {</span><br><span class="line"> cd 'D:/xxx'</span><br><span class="line"> yt-dlp --format 'bestaudio[ext!=webm]' $url</span><br><span class="line">}</span><br></pre></td></tr></table></figure><p>最终就是写了一个函数,这样我们在 shell 里面执行 yda 后面需要一个参数。持久化的方法,我也是同样写到 env.nu 里面。</p><p><img src="/img/2024/nu-shell-yda.png" alt="nu-shell-yda"></p>]]></content>
<summary type="html"><p>由于我经常使用 yt-dlp 来下载视频或者音频,所以之前已经给 nu shell 添加了 alias,把 yt-dlp 缩短为 yt。</p>
<p>但是我平时喜欢把音频,直接下载到一个特定的目录里面。所以使用命令行,我需要先 cd xxxx,然后再执行 yt xxxx。</summary>
<category term="Windows" scheme="https://powersee.github.io/tags/Windows/"/>
<category term="shell" scheme="https://powersee.github.io/tags/shell/"/>
</entry>
<entry>
<title>Nu shell 的 alias (别名)笔记</title>
<link href="https://powersee.github.io/2024/08/nu-shell-alias/"/>
<id>https://powersee.github.io/2024/08/nu-shell-alias/</id>
<published>2024-08-11T15:54:55.000Z</published>
<updated>2024-08-12T15:41:55.993Z</updated>
<content type="html"><![CDATA[<p>平时在 Mac 和 Linux 上面,我挺喜欢使用 alias 的,可以节省我执行命令的时间。</p><p>Windows 上面,我还是用不惯 powershell 和 cmd,所以我在上面安装了 nu shell,并且把它设置为默认的 shell,打开终端 APP 的时候,就会启动 nu shell。</p><p><img src="/img/2023/nushell-ls.png"></p><p>在比较简单的情况下,它的 alias 和 bash 的差不多。</p><p>此处可以参考官方文档:<a href="https://www.nushell.sh/zh-CN/book/aliases.html">别名 | Nushell</a></p><p>例如我就把 yt-dlp 缩短为 yt</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line"> $ alias yt = yt-dlp</span><br><span class="line"> $ yt-dlp --version </span><br><span class="line">2024.08.01</span><br><span class="line"> $ yt --version </span><br><span class="line">2024.08.01</span><br></pre></td></tr></table></figure><p>不过里面说,想要持久化,可以添加到你的 config.nu 文件中。</p><p>我没有这么做,我直接写入到 env.nu 中了,直接把 env.nu 当成 .zshrc 来看待了。</p><p>如果只是简单地缩短命令,那么了解到这里就足够了。</p><p>不过使用稍微深一点,就还是容易遇到问题。</p><h3 id="首先是命令的拼接"><a href="#首先是命令的拼接" class="headerlink" title="首先是命令的拼接"></a>首先是命令的拼接</h3><p>在 bash 上面我们可以使用 && 来连接两条命令。不过在 nu 这边不行,这点我们可以参考官方的这篇文档 <a href="https://www.nushell.sh/zh-CN/book/coming_from_bash.html">从 Bash 到 Nu | Nushell</a>,这里面可以了解到 bash 上面的 &&,在 nu shell 里是使用 <code>;</code></p><h3 id="然后是-Windows-切换盘符"><a href="#然后是-Windows-切换盘符" class="headerlink" title="然后是 Windows 切换盘符"></a>然后是 Windows 切换盘符</h3><p>我们平时启动 shell 之后,默认是在 C 盘的用户目录下,此时如果想切换到 D 盘。</p><p>那么在 cmd 和 powershell,我们只需要执行</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">D:</span><br></pre></td></tr></table></figure><p>就可以切换过去。但是在 nu 这边不行,得加多一个 \</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">D:\</span><br></pre></td></tr></table></figure>]]></content>
<summary type="html"><p>平时在 Mac 和 Linux 上面,我挺喜欢使用 alias 的,可以节省我执行命令的时间。</p>
<p>Windows 上面,我还是用不惯 powershell 和 cmd,所以我在上面安装了 nu shell,并且把它设置为默认的 shell,打开终端 APP 的时</summary>
<category term="Windows" scheme="https://powersee.github.io/tags/Windows/"/>
<category term="shell" scheme="https://powersee.github.io/tags/shell/"/>
</entry>
<entry>
<title>本地部署开源语音转文字模型 SenseVoice</title>
<link href="https://powersee.github.io/2024/08/SenseVoice/"/>
<id>https://powersee.github.io/2024/08/SenseVoice/</id>
<published>2024-08-08T13:39:15.000Z</published>
<updated>2024-08-08T13:40:25.285Z</updated>
<content type="html"><![CDATA[<p>阿里的语音转文字模型 <a href="https://github.com/FunAudioLLM/SenseVoice/">https://github.com/FunAudioLLM/SenseVoice/</a></p><p>听说比 openai 的 Whisper 效果好,既然是开源的,那就下载来试试看吧。</p><ul><li><p>这个可以用 CPU 来运行,所以没有显卡也能用。</p></li><li><p>对电脑系统要求有 python 和 ffmpeg。</p></li></ul><p>首先把代码克隆到本地</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">git clone https://github.com/FunAudioLLM/SenseVoice.git</span><br></pre></td></tr></table></figure><p>然后安装依赖</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">pip install -r requirements.txt</span><br></pre></td></tr></table></figure><p>完成后启动 webui 就可以使用了</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">python webui.py</span><br></pre></td></tr></table></figure><p><img src="/img/2024/sensevoice-webui.webp" alt="sensevoice-webui"></p><p>一般运行之后,会给我们一个地址 <a href="http://127.0.0.1:7860/">http://127.0.0.1:7860</a> 打开浏览器访问它,然后上传音频上去,语言可以选择一下,这样可以更快速转换,再点击一下 「start」按键就可以了。</p><p>我使用的是 Mac mini,观察了一下,使用时占用内存 1.6GB,点击 start 后开始转换,主要是 CPU 占用增加,GPU 好像没变化,转换时内存占用会提高到 2.6GB。</p><p>速度确实挺快的,三分钟的音频,6 秒就转换好了。这点可以从终端看到。</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">time_speech: 185.867, time_escape: 6.026: 100%</span><br></pre></td></tr></table></figure><p>后面又尝试了一段 57 分钟的音频,耗时不到两分钟</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">time_speech: 3461.120, time_escape: 113.743: 100%</span><br></pre></td></tr></table></figure><p>注意,安装的依赖比较占用空间</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">torch<=2.3</span><br><span class="line">torchaudio</span><br><span class="line">modelscope</span><br><span class="line">huggingface</span><br><span class="line">huggingface_hub</span><br><span class="line">funasr>=1.1.3</span><br><span class="line">numpy<=1.26.4</span><br><span class="line">gradio</span><br><span class="line">fastapi>=0.111.1</span><br></pre></td></tr></table></figure><p>建议创建 python 虚拟环境,专门给它使用。</p><p>我这边 venv 目录占用了 883 MB。</p><p>目前好像就开源了这个 small 模型,我们好像也不能切换其它模型,不过我感觉转换的质量还不错,所以以后在 Mac 上我就使用它来语音转文字了,Windows 上面我还是会继续使用 Whisper。</p>]]></content>
<summary type="html"><p>阿里的语音转文字模型 <a href="https://github.com/FunAudioLLM/SenseVoice/">https://github.com/FunAudioLLM/SenseVoice/</a></p>
<p>听说比 openai 的 Whispe</summary>
<category term="随笔" scheme="https://powersee.github.io/tags/%E9%9A%8F%E7%AC%94/"/>
</entry>
<entry>
<title>Ollama 更改模型存放位置</title>
<link href="https://powersee.github.io/2024/08/ollama-models-path/"/>
<id>https://powersee.github.io/2024/08/ollama-models-path/</id>
<published>2024-08-05T05:09:48.000Z</published>
<updated>2024-08-05T05:13:31.723Z</updated>
<content type="html"><![CDATA[<p>想要改它的存放位置,我们需要进入环境变量。</p><p>打开 Windows 系统设置,来到【关于】,在右边找到【高级系统设置】,然后会出现一个【系统属性】窗口。</p><p>在上面的标签里选择【高级】,再点击下方的【环境变量】。</p><p>这时弹出一个【环境变量】窗口,点击【系统变量】下的新建,然后又弹出一个窗口。</p><p>变量名:OLLAMA_MODELS</p><p>变量值:D:\AI\Ollama</p><p>然后一个一个确定,就添加好环境变量了。</p><p><img src="/img/2024/Ollama-env-model.webp" alt="Ollama-env-model"></p><p>那怎么知道环境变量有没有生效呢?直接重启电脑肯定可以。</p><p>不过也有快速的方法,我们打开 cmd,然后执行一个命令 set ,它就会输出所有的环境变量,找找看有没有我们刚才添加的 OLLAMA_MODELS 就行。</p><p><img src="/img/2024/cmd-ollama-env.webp" alt="cmd-ollama-env"></p><p>这时候再执行 run 或者 pull 命令来拉去模型,就会存放在 D 盘了。</p><p>那如果我之前已经下载过模型,存放在 C 盘里面了呢?怎么迁移到 D 盘?</p><p>很简单,将 C 盘的用户目录下的 .ollama 中的两个文件夹,移动到 D 盘我们新设置的存放路径就行。</p><p>迁移之后,可以使用 ollama list 来检查</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">C:\Users\x>ollama list</span><br><span class="line">NAME ID SIZE MODIFIED</span><br><span class="line">qwen2:1.5b f6daf2b25194 934 MB 11 hours ago</span><br><span class="line">gemma2:latest ff02c3702f32 5.4 GB 46 hours ago</span><br><span class="line">qwen2:latest e0d4e1163c58 4.4 GB 47 hours ago</span><br><span class="line">qwen2:0.5b 6f48b936a09f 352 MB 2 days ago</span><br><span class="line">llama3.1:latest 62757c860e01 4.7 GB 2 days ago</span><br></pre></td></tr></table></figure>]]></content>
<summary type="html"><p>想要改它的存放位置,我们需要进入环境变量。</p>
<p>打开 Windows 系统设置,来到【关于】,在右边找到【高级系统设置】,然后会出现一个【系统属性】窗口。</p>
<p>在上面的标签里选择【高级】,再点击下方的【环境变量】。</p>
<p>这时弹出一个【环境变量】</summary>
<category term="AI" scheme="https://powersee.github.io/tags/AI/"/>
</entry>
<entry>
<title>在 B 站网页版显示用户 IP 归属地</title>
<link href="https://powersee.github.io/2024/05/bilibili-web-user-ip/"/>
<id>https://powersee.github.io/2024/05/bilibili-web-user-ip/</id>
<published>2024-05-21T04:58:12.000Z</published>
<updated>2024-05-21T04:59:08.855Z</updated>
<content type="html"><![CDATA[<p>目前使用「哔哩哔哩」的手机客户端,可以显示用户的 IP 属地。(不过用谷歌商店的「bilibili」国际版不能显示)</p><p>最近无意间发现一个油猴脚本 <a href="https://greasyfork.org/zh-CN/scripts/466815-%E5%93%94%E5%93%A9%E5%93%94%E5%93%A9%E7%BD%91%E9%A1%B5%E7%89%88%E5%B1%95%E7%A4%BA-ip-%E5%B1%9E%E5%9C%B0">哔哩哔哩网页版展示 IP 属地</a></p><p>安装之后在网页端也可以显示用户的 IP 属地了,效果如下图。</p><p><img src="/img/2024/bilibili-ip-web-preview.webp" alt="preview"></p>]]></content>
<summary type="html"><p>目前使用「哔哩哔哩」的手机客户端,可以显示用户的 IP 属地。(不过用谷歌商店的「bilibili」国际版不能显示)</p>
<p>最近无意间发现一个油猴脚本 <a href="https://greasyfork.org/zh-CN/scripts/466815-%E5%</summary>
<category term="网络" scheme="https://powersee.github.io/tags/%E7%BD%91%E7%BB%9C/"/>
</entry>
<entry>
<title>Mac 邮件 APP 老是自动退出,分享我的解决方案</title>
<link href="https://powersee.github.io/2024/05/mac-mail-app-check/"/>
<id>https://powersee.github.io/2024/05/mac-mail-app-check/</id>
<published>2024-05-18T13:08:56.000Z</published>
<updated>2024-05-18T13:09:27.624Z</updated>
<content type="html"><![CDATA[<p>不知道是不是内存不够的原因,Mac 上面的「邮件」APP 老是自动退出,这就有点难受了,我没法及时收到邮件呀。</p><p>目前我的解决方案是,通过一个定时脚本,每个小时运行一次,检查一下「邮件」APP 是否在运行,如果不是,就打开运行。</p><p>下面是脚本内容。</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">#!/bin/bash</span><br><span class="line"></span><br><span class="line"># 检查邮件应用程序是否在运行</span><br><span class="line">if ! pgrep -x "Mail" > /dev/null</span><br><span class="line">then</span><br><span class="line"> echo "Mail app is not running. Starting Mail app..."</span><br><span class="line"> open -a "Mail"</span><br><span class="line"> sleep 5 # 等待邮件应用程序完全启动</span><br><span class="line"></span><br><span class="line">else</span><br><span class="line"> echo "Mail app is already running."</span><br><span class="line">fi</span><br></pre></td></tr></table></figure><p>我把它写到 <code>$HOME/code/check_mail.sh</code> 里面,然后赋予它执行权限。</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">chmod +x $HOME/code/check_mail.sh</span><br></pre></td></tr></table></figure><p>之后 crontab 里面添加这一行内容</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">8 * * * * $HOME/code/check_mail.sh >> /tmp/check-mail.log</span><br></pre></td></tr></table></figure><p>这样每个小时的第 8 分钟,脚本就会运行一次。</p>]]></content>
<summary type="html"><p>不知道是不是内存不够的原因,Mac 上面的「邮件」APP 老是自动退出,这就有点难受了,我没法及时收到邮件呀。</p>
<p>目前我的解决方案是,通过一个定时脚本,每个小时运行一次,检查一下「邮件」APP 是否在运行,如果不是,就打开运行。</p>
<p>下面是脚本内容。<</summary>
<category term="Mac" scheme="https://powersee.github.io/tags/Mac/"/>
</entry>
<entry>
<title>记一次清理 /var/lib/docker/</title>
<link href="https://powersee.github.io/2024/04/clean-var-lib-docker/"/>
<id>https://powersee.github.io/2024/04/clean-var-lib-docker/</id>
<published>2024-04-27T03:24:44.000Z</published>
<updated>2024-04-27T03:25:16.495Z</updated>
<content type="html"><![CDATA[<p>最近发现服务器的可用空间又变零了,使用 ncdu 扫描一下全盘,发现还是 docker 占用的空间最多。</p><p>于是得来清理一下。</p><p>使用 docker 的内置命令</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">$ docker system df </span><br><span class="line">TYPE TOTAL ACTIVE SIZE RECLAIMABLE</span><br><span class="line">Images 7 7 1.49GB 0B (0%)</span><br><span class="line">Containers 7 6 14.61MB 0B (0%)</span><br><span class="line">Local Volumes 2 2 219.1MB 0B (0%)</span><br><span class="line">Build Cache 63 0 1.089GB 1.089GB</span><br></pre></td></tr></table></figure><p>我这里找到了 1GB 多的构建缓存,我打算把它清除掉。</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">docker builder prune</span><br></pre></td></tr></table></figure><p>清除完成后,再来看一下。</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">$ docker system df </span><br><span class="line">TYPE TOTAL ACTIVE SIZE RECLAIMABLE</span><br><span class="line">Images 7 7 1.49GB 0B (0%)</span><br><span class="line">Containers 7 6 14.61MB 0B (0%)</span><br><span class="line">Local Volumes 2 2 219.1MB 0B (0%)</span><br><span class="line">Build Cache 1 0 0B 0B</span><br></pre></td></tr></table></figure>]]></content>
<summary type="html"><p>最近发现服务器的可用空间又变零了,使用 ncdu 扫描一下全盘,发现还是 docker 占用的空间最多。</p>
<p>于是得来清理一下。</p>
<p>使用 docker 的内置命令</p>
<figure class="highlight plaintext"><tab</summary>
<category term="Linux" scheme="https://powersee.github.io/tags/Linux/"/>
</entry>
<entry>
<title>使用 AppleScript 控制键盘按键</title>
<link href="https://powersee.github.io/2024/04/mac-applescript-keyboard-control/"/>
<id>https://powersee.github.io/2024/04/mac-applescript-keyboard-control/</id>
<published>2024-04-26T13:39:37.000Z</published>
<updated>2024-04-26T13:43:18.341Z</updated>
<content type="html"><![CDATA[<p>macOS 有一个自带的 APP 叫「脚本编辑器」,我想使用它,来实现每三秒就按一下方向键右→</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">repeat</span><br><span class="line">tell application "System Events"</span><br><span class="line">key code 124</span><br><span class="line">end tell</span><br><span class="line">delay 3</span><br><span class="line">end repeat</span><br></pre></td></tr></table></figure><p><img src="/img/2024/applescript-key.webp" alt="applescript-key"></p><p>此时如果点击右上角的三角形图标 ▶,应该会报错。</p><blockquote><p>“System Events”遇到一个错误:“脚本编辑器”不允许发送按键。</p></blockquote><p>需要给它控制电脑的权限才行。在辅助功能里面,找到「脚本编辑器」然后打开,找不到可以像我这样直接搜索。</p><p><img src="/img/2024/crontrol-computer.webp" alt="crontrol-computer"></p><p>之后再来运行脚本,就可以实现目的了,每 3 秒就会按一下 右键。</p><p>后面再加入随机时间和通知</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">repeat</span><br><span class="line"> tell application "System Events"</span><br><span class="line"> key code 124</span><br><span class="line"> end tell</span><br><span class="line"> set randomDelay to (random number from 6 to 20)</span><br><span class="line"> display notification "随机延迟时间为:" & randomDelay & " 秒"</span><br><span class="line"> delay randomDelay</span><br><span class="line">end repeat</span><br></pre></td></tr></table></figure>]]></content>
<summary type="html"><p>macOS 有一个自带的 APP 叫「脚本编辑器」,我想使用它,来实现每三秒就按一下方向键右→</p>
<figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="lin</summary>
<category term="Mac" scheme="https://powersee.github.io/tags/Mac/"/>
</entry>
<entry>
<title>CopyQ 在 Mac 上意外退出的解决方法</title>
<link href="https://powersee.github.io/2024/04/mac-copyq-error/"/>
<id>https://powersee.github.io/2024/04/mac-copyq-error/</id>
<published>2024-04-01T06:03:10.000Z</published>
<updated>2024-04-01T06:03:42.866Z</updated>
<content type="html"><![CDATA[<p>CopyQ 是我目前正在使用的「剪贴板管理工具」,它是在 GitHub 上开源的软件:<a href="https://github.com/hluk/CopyQ">https://github.com/hluk/CopyQ</a></p><p>目前星星的数量有 7 千多。之前使用它的时候,官方还没有提供 Mac ARM 版,直接下载使用的是 Intel 版本。</p><p>所以我还去研究怎么自己编译,折腾一番之后,才使用上 Apple silicon 版本的 CopyQ。</p><p>刚才发现这软件打不开了,一运行就提示「意外退出」。</p><p><img src="/img/2024/CopyQ-error.webp" alt="CopyQ-error"></p><p>我想着去 <a href="https://github.com/hluk/CopyQ/releases">GitHub</a> 上下载新版本试试看,结果发现现在已经提供 M1 版本的了,于是下载试试看。</p><p>由于这软件没有签名,所以默认情况下是打不开的。需要使用终端执行</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">sudo xattr -d com.apple.quarantine /Applications/CopyQ.app</span><br></pre></td></tr></table></figure><p>之后再尝试打开,发现还是会提示「意外退出」,和我之前的一样。。。</p><p>翻一下 issues,找到了<a href="https://github.com/hluk/CopyQ/issues/2652">解决方法</a></p><p>只需要在终端执行</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">codesign --force --deep --sign - /Applications/CopyQ.app</span><br></pre></td></tr></table></figure><p>就可以再次打开了。</p>]]></content>
<summary type="html"><p>CopyQ 是我目前正在使用的「剪贴板管理工具」,它是在 GitHub 上开源的软件:<a href="https://github.com/hluk/CopyQ">https://github.com/hluk/CopyQ</a></p>
<p>目前星星的数量有 7 千多</summary>
<category term="Mac" scheme="https://powersee.github.io/tags/Mac/"/>
</entry>
<entry>
<title>Mac 使用终端命令打开和关闭应用</title>
<link href="https://powersee.github.io/2024/03/mac-terminal-open-and-close-app/"/>
<id>https://powersee.github.io/2024/03/mac-terminal-open-and-close-app/</id>
<published>2024-03-23T04:31:59.000Z</published>
<updated>2024-03-23T04:32:38.088Z</updated>
<content type="html"><![CDATA[<p>打开,需要应用的完整路径和后缀</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">open /Applications/OBS.app</span><br></pre></td></tr></table></figure><p>关闭,只需要应用名</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">killall OBS</span><br></pre></td></tr></table></figure><p>既然可以用命令,来打开和关闭应用程序,那么结合定时任务,就能实现一些自动化操作。</p>]]></content>
<summary type="html"><p>打开,需要应用的完整路径和后缀</p>
<figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">open /Applications/OBS.app</s</summary>
<category term="Mac" scheme="https://powersee.github.io/tags/Mac/"/>
</entry>
<entry>
<title>IINA 自定义倍速播放</title>
<link href="https://powersee.github.io/2024/03/iina-custom-speed/"/>
<id>https://powersee.github.io/2024/03/iina-custom-speed/</id>
<published>2024-03-21T04:54:59.000Z</published>
<updated>2024-03-21T04:55:52.992Z</updated>
<content type="html"><![CDATA[<p>IINA 是我在 Mac 上的常用视频播放器。</p><p>不过它默认的倍速比较奇葩。速度都是相乘的,比如乘 2,那么第一次就是速度变为 2,再按一次就是变为 4。</p><p><img src="/img/2024/IINA-default.webp" alt="IINA-default"></p><p>我想要的是像 potplayer 那样,按一下就增加 0.1 的速度。</p><p>于是我复制多一份配置出来,然后双击相关的命令,就可以看到快捷键被按下后,后台执行的具体命令。</p><p>例如这个「速度 乘 1.1 倍」</p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">multiply speed 1.1</span><br></pre></td></tr></table></figure><p>这种叫 mvp 命令,我第一次接触。那么试一下,把 multiply 改为 add 试试,果然可以。</p><p>于是我便手动添加两个快捷键。使用的是中括号这两颗按键 <code>[</code> <code>]</code>,如果改为使用 x 和 c 就和 potplayer 一样,看个人喜好了。</p><p><img src="/img/2024/IINA-custom.webp" alt="IINA-custom"></p><p>其中加速我们可以用 add,但减速用 sub 好像不行。后来看了下别人怎么配置,才意识到没必要,直接加一个负数就行。</p><p><img src="/img/2024/IINA-speed.webp" alt="IINA-speed"></p><figure class="highlight plaintext"><table><tr><td class="code"><pre><span class="line">add speed 0.1</span><br></pre></td></tr></table></figure><p>加速就简单 add 正数就行了。</p>]]></content>
<summary type="html"><p>IINA 是我在 Mac 上的常用视频播放器。</p>
<p>不过它默认的倍速比较奇葩。速度都是相乘的,比如乘 2,那么第一次就是速度变为 2,再按一次就是变为 4。</p>
<p><img src="/img/2024/IINA-default.webp" alt="II</summary>
<category term="Mac" scheme="https://powersee.github.io/tags/Mac/"/>
</entry>
<entry>
<title>Mac 端 QQ 设置直接登录</title>
<link href="https://powersee.github.io/2024/03/mac-qq-login/"/>
<id>https://powersee.github.io/2024/03/mac-qq-login/</id>
<published>2024-03-07T07:15:58.000Z</published>
<updated>2024-03-07T07:17:55.750Z</updated>
<content type="html"><![CDATA[<p>每次我在 Mac 上登录 QQ,都需要在手机上点击一下「允许登录」,有时甚至需要扫一下二维码才能登录。</p><p>这就很麻烦,如果只是第一次在新设备上登录,需要进行这样的验证,那我可以理解。问题是我都用这电脑登录好多次了。</p><p>解决方法</p><p>打开 QQ 后,点击 Mac 状态栏的左上角, 图标旁边的 QQ,选择 「设置」,来到「登录设置」。</p><p>将「下次登录无需在手机端确认」这个开关打开就行。</p><p><img src="/img/2024/mac-qq-login.webp" alt="mac-qq-login"></p>]]></content>
<summary type="html"><p>每次我在 Mac 上登录 QQ,都需要在手机上点击一下「允许登录」,有时甚至需要扫一下二维码才能登录。</p>
<p>这就很麻烦,如果只是第一次在新设备上登录,需要进行这样的验证,那我可以理解。问题是我都用这电脑登录好多次了。</p>
<p>解决方法</p>
<p>打开 Q</summary>
<category term="Mac" scheme="https://powersee.github.io/tags/Mac/"/>
</entry>
</feed>