hongy19’s blog
Regular expression
“$” are different in basic regular expression and extend regular expression, see https://stackoverflow.com/questions/38114132/why-does-dollar-not-match-literal-dollar-when-extended-regex-ere-option-is-use.
https://www.gnu.org/software/findutils/manual/html_node/find_html/posix_002degrep-regular-expression-syntax.html#posix_002degrep-regular-expression-syntax
- posix-egrep’ regular expression syntax:
- The characters ‘^’ and ‘$’ always represent the beginning and end of a string respectively, except within square brackets. Within brackets, ‘^’ can be used to invert the membership of the character class being specified.
- ‘posix-basic’ regular expression syntax:
-
The character ‘^’ only represents the beginning of a string when it appears:
-
At the beginning of a regular expression
…
-
-
Stack
- basic concept (from link)
- ghc only knows about packages that are installed. Installed packages live in package databases
- ghc-pkg is package tool from ghc and ghc know two database
- database is a directory, usually called package.conf.d, that contains a file for each package, together with a binary cache of the package data in the file package.cache
- global package database, which comes with your GHC installation, e.g. /usr/lib/ghc-6.12.1/package.conf.d.
- user package database private to each user, e.g. $XDG_DATA_HOME/ghc/arch-os-version/package.conf.
- While we assume in general that LTS snapshots never change, there’s nothing that technically prohibits that from happening. Instead, the complete version of that field is
resolver: size: 496662
…
url: https://raw.githubusercontent.com/commercialhaskell/stackage-snapshots/master/lts/13/9.yaml
sha256: 83de9017d911cf7795f19353dba4d04bd24cd40622b7567ff61fc3f7223aa3ea
Windows
- 解决Windows10英文版中文字体难看、时大时小、中文比英文小等问题
- HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\FontLink\SystemLink
- 把 MSYH.TTC,Microsoft YaHei UI,128,96 MSYH.TTC,Microsoft YaHei UI放在Segoe UI,Tahoma,Microsoft Sans Serif的前面。
- seelink1, link2, link3
- chrome installation
- chrome的proxy setting用的是windows system proxy setting,而公司的新电脑上system proxy是不可以更改的。在这种情况下,安装完chrome后是无法sync and install extension。可以用google-chrome –proxy-server=“socks://localhost:8080"的方式用命令行来设置chrome proxy,后就可以sync and install extension。
- 公司电脑的政策是只有whitelist里的extension是可以安装的,可以用SwitchyOmega切换proxy
- WSL
- Windows 10 21H2里的wsl (Arch)默认还是wsl1,需要在setting ->Apps & feature -> Optional features -> more windows features里安装"windows subsystem for linux” (for WSL1) and “virtual machine platform” (for WSL2)
- Arch by default is WSL1,可以先把老的ext4.vhdx改名,再把wsl1 convert to wsl2,然后再把old hvdx的文件名改回ext4.vhdx及可。
- backup for new laptop
- onedrive, outlook,edge, chrome都是cloud based的,不用特殊备份
- netid里的老证书也可以从网上下载,不用备份
- backup chrome SwitchyOmega配置, .wslconfig in $user$ folder
- WSL(arch)需要把相关文件拷贝到onedrive里,安装完成后再copy出来。
- 其它非onedriver folder backup: log