在 macOS 上部署 DeepSeek-R1
2025-01-28
DeepSeek 接连放大招,狠狠挤了一把 AI 泡沫,硅谷巨头纷纷股价暴跌。 在使用网页版的同时,作为小白也想体验一下本地部署的乐趣,遗憾的是没有高配电脑,只好在老掉牙的 MBP 上试试了,权当图一乐。 …
为邮件客户端添加 OAuth 2.0 代理
2024-10-15
强制使用 OAuth 2.0 认证的邮件提供商越来越多,而一些老客户端并不支持,比如 macOS Catalina 自带的邮件。 于是尝试换 Thunderbird,然而用起来有些……粗犷。 找到一个开源程序 email-oauth2-proxy,它可以建立一个代理,让不支持 OAuth 2.0 的客户端使用 IMAP/POP/SMTP 协议继续访问邮箱,但它的文档写得实在不像给人类看的。 …
下载官方旧版本 Chrome 并禁止更新
2024-07-30
已经忍 Chrome 很久了,但是如果换其他浏览器,想想那一堆扩展脚本密码书签就头疼。整天提醒更新,不知道更新了个什么玩意,反而把原来的功能改成依托答辩。 万万没想到,在三哥的英明领导下,狗鸽又拉了几坨大的: …
视频相关的命令和脚本
2023-11-22
FFmpeg 实用命令 剪切视频而不重新转码1 $ ffmpeg -ss 00:00:30.0 -to 00:00:40.0 -i input.mp4 -c copy output.mp4 -ss 和 -to 分别指定起始时间。 这种方式输出的视频有一定问题,最好还是转码(不要用 -c copy)。 codec not currently supported in container2 一些视频流和音频流无法放到同一容器中,例如 WMA 音频不能与 H.264 视频兼容,解决方式是将音频也转码: …
Homebrew 使用中的一些问题
2023-03-31
listxattr for destination failed: 2 遇到这个问题,首先要确定 CommandLineTools 是否安装了正确版本,查看 brew doctor 的提示。 如果安装正确,有可能是使用 OCLP 安装 Sequoia 导致,传递给 /usr/local/Homebrew/Library/Homebrew/cask/utils/copy-xattrs.swift 的参数不正确: /Library/Developer/CommandLineTools/usr/bin/swift-frontend, -frontend, -interpret, /usr/local/Homebrew/Library/Homebrew/cask/utils/copy-xattrs.swift, -target, x86_64-apple-macosx15, -enable-objc-interop, -stack-check, -sdk, /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk, -color-diagnostics, -new-driver-path, /Library/Developer/CommandLineTools/usr/bin/swift-driver, -empty-abi-descriptor, -resource-dir, /Library/Developer/CommandLineTools/usr/lib/swift, -module-name, main, -disable-clang-spi, -target-sdk-version, 15.5, -target-sdk-name, macosx15.5, -external-plugin-path, /Library/Developer/Developer/usr/lib/swift/host/plugins#/Library/Developer/Developer/usr/bin/swift-plugin-server, -external-plugin-path, /Library/Developer/Developer/usr/local/lib/swift/host/plugins#/Library/Developer/Developer/usr/bin/swift-plugin-server, -in-process-plugin-server-path, /Library/Developer/CommandLineTools/usr/lib/swift/host/libSwiftInProcPluginServer.dylib, -plugin-path, /Library/Developer/CommandLineTools/usr/lib/swift/host/plugins, -plugin-path, /Library/Developer/CommandLineTools/usr/local/lib/swift/host/plugins, --, /usr/local/Caskroom/visual-studio-code/1.104.1/Visual Studio Code.app, /Applications/Visual Studio Code.app copy-xattrs.swift 期望两个参数,即源目录和目标目录,但最终传递的打印出来很长(参数可能与系统或 CLT 版本有关)。 …
Transmission 屏蔽迅雷等吸血客户端
2022-04-26
一直跟你索取数据,你有求必应地给它了,等你跟它请求的时候,不好意思,没有,不信你看我进度,我可是 0% 啊!——这就是吸血。 然而 BT 协议非常宽松,大多数开源客户端并不屏蔽吸血客户端,有些客户端如 qBittorrent-Enhanced-Edition,可以通过 Peer/Client ID 识别它们并屏蔽。 …
Dnsmasq 去 DNS 污染和广告
2021-09-21
有时网站被墙,可能只是域名被劫持了,IP 还是通的。ISP 会拦截 53 端口数据,看到某些域名就 angry,直接返回一个假 IP。 例如对某域名进行两次 OpenDNS 查询: …
Y 站、K 站下载器 moebooru-crawler
2021-06-29
Shell 脚本,用来获取基于 moebooru 的网站上的原图链接,如 yande.re、konachan.com 等。 下载 $ curl -O "https://github.com/qianbinbin/moebooru-crawler/raw/master/moebooru-crawler.sh" $ # git clone git@github.com:qianbinbin/moebooru-crawler.git && cd moebooru-crawler $ chmod +x ./moebooru-crawler.sh 使用 Usage: moebooru-crawler URL [ -n NUM, --num=NUM ] -n NUM, --num=NUM print NUM links of images, or print all if NUM is '0' 示例 获取指定页面上的图片链接 $ ./moebooru-crawler.sh "https://yande.re/post?tags=coffee-kizoku+order%3Ascore" 将链接保存到文件 $ ./moebooru-crawler.sh "https://yande.re/post?tags=coffee-kizoku+order%3Ascore" >>links.txt 然后可以用 aria2c 之类的工具批量下载。 …