将 WSL 迁移到另一个驱动器
Original from https://blog.iany.me/2020/06/move-wsl-to-another-drive/.I thought the article is absolutely wonderful, so I reprinted it (and translated it into Chinese). This article just saved my system disk, thank the original author Ian Yang~
下面这个例子会手把手带领你安装一个 Ubuntu 虚拟机,并将它的存储位置迁移到 D:\WSL\Ubuntu.
第一步 安装 Ubuntu 虚拟机这一步是可选的,因为您也许已经安装过虚拟机了。
在 Microsoft Store 中安装 Ubuntu。启动它以初始化默认实例。根据提示创建Ubuntu中使用的用户。
第二步 将虚拟机迁移到指定位置使用如下命令导出实例并导入目标目录:
1234567cd D:\mkdir WSLcd WSLwsl --export Ubuntu ubuntu.tarwsl ...
关于 prettier + pnpm 的最佳实践
在半年前就发现我很多项目里的 prettier 对 vue 内的 pug 不起效果了,我一直以为是我的问题,例如 VSCode 的扩展配置有问题啦、依赖安装不对啦之类的。
在我浪费了一个小时的人生去查找 GitHub 上的各种 issues 后,我发现这居然是个 prettier 的兼容性 bug:
[Bug?] Symlink’d plugins in node_modules are not auto detected. #8056
简单概括一下内容:使用 pnpm 时,prettier 的插件寻址机制未按预期那样起作用。
我正是在大约半年前由 yarn 转向了 pnpm,因此遇到了这个 bug。
关于这个 bug,官方摆烂了,因为这个 issue 最初是在 2020 年被提出的,至今没有进行修复。
最后还是万能的网友提出了解决方案:使用 js 配置文件显式的指定插件路径。
比如这样:
12345// .prettierrc.cjsmodule.exports = { plugins: [require.resolve('@prettier/plugin- ...
Netlify CMS Test
This article is published with netlify-cms
inlinebold italic code
block
quote
list
list
list
ordering list
list 2
12// code blockconsole.log('hello, world')
screenshot
将组织仓库绑定到 Vercel 个人账户
警告
这应该属于恶性 bug,请不要滥用,避免风险。
https://vercel.com/new/import-flow?s=https://github.com/OWNER/REPO
直接访问这个链接,可以导入任意类型的仓库到个人账户名下部署,带持续集成的那种……
这里的仓库是有一定限制的,源仓库需要安装过由你授权的 Vercel App,简单来说你得是 owner。
ASCII 字符画在线生成器
表演一个杂技:
ORIGINALMAINORIGINALMAINORIGINALMAINORIGINALM
AINORIGINALMAINORIGINALMAINORIGINALMAINORIGIN
ALMAINORIGINALMAINORIGINALMAINORIGINALMAINORI
GINALMAINORIGINALMAINORIGINALMAINORIGINALMAIN
ORIGINALMAINORIGINALMAINORIGINALMAINORIGINALM
AINORIGINALMAINORIGINALMAINORIGINALMAINORIGIN
ALMAINORIGINALMAINORIGINALMAINORIGINALMAINORI
GINALMAINORIGINALMAINORIGINALMAINORIGINALMAIN
ORIGINALMAINORIGINALMAINORIGINALMAINORIGINALM
AINORIGINALMAINORIGINALMAINORIGINALMAINORIGIN
ALMAINORIGINALMAINORIGINALMAINOR ...
沃里杰诺•梅因 表情包!
沃里杰诺•梅因是我笔下的原创角色,在网友的怂恿下,以梅因为主题描改了一些表情包。
常用缩写
WIPWork In Progress 开发中(work in progress, do not merge yet)
PTALPlease Take A Look 帮我看下(请别人 review 自己的 PR)
LGTMLooks Good To Me 看起来不错, 没有问题(别人 review 完 PR 之后)
RFCRequest For Comments 请求评论
i.e. I think this is a good idea, lets discuss
AFAIK / AFAICTAs Far As I Know / Can Tell 据我所知
IMHOIn My Humble Opinion 以我的拙见(多用于邮件和网络)
FYIFor your information 供你参考
CCCarbon Copy 抄送(邮件)
AFKAway From the Keyboard 稍后回来
ACKACKnowledgement 同意
i.e. agreed/accepted change
NACK / NAKNegative ACKnowledgement 不同意
i.e. di ...
zwc365 代理
昨天其实对于这篇博客来说是几分钟前(草提到的 FastGit 虽然各方面都很好,但是仍然有一些缺点,例如在遇到私密 repo 的时候会直接裂开,就在我推这个博客的源码到 GitHub 的时候发现的(
不过还好,依旧可以继续尝试 https://pd.zwc365.com/
官网https://pd.zwc365.com/
使用让 zwc365 全局代理 git 对 GitHub 的请求。
通过修改配置文件
1234[http] followRedirects = true[url "https://pd.zwc365.com/seturl/https://github.com/"] insteadOf = https://github.com/
或者使用命令行
12git cnofig --global http.followRedirects truegit config --global url."https://pd.zwc365.com/seturl/https://github.com/".insteadOf "http ...
使用 FastGit 加速 GitHub
由于最近在开各种会议,加上中美关系紧张,校园网基本连不上 GitHub 了。气得我浑身发抖手脚冰凉,这日子还能不能好了。
万幸找到了一个代理叫 FastGit,至少能够 pull 和 push……
FastGit 官网https://fastgit.org/
使用让 FastGit 全局代理 git 对 GitHub 的请求。
通过修改配置文件
1234[http] followRedirects = true[url "https://hub.fastgit.org/"] insteadOf = https://github.com/
或者使用命令行
12git cnofig --global http.followRedirects truegit config --global url."https://hub.fastgit.org/".insteadOf "https://github.com/"
其他代理
https://doc.fastgit.org/zh-cn/node.html
源站
代理
...