February 22, 2020 / Kyle Sun / 0 Comments
Archlinux with en locale
Package: deepin.com.wechat2
#!/bin/bash
/usr/lib/gsd-xsettings &
/opt/deepinwine/apps/Deepin-WeChat/run.sh
Chinese font settings:
1. Create a reg file chn.reg
REGEDIT4
[HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\FontLink\SystemLink]
"Arial"="notosans.ttc"
"Arial CE,238"="notosans.ttc"
"Arial CYR,204"="notosans.ttc"
"Arial Greek,161"="notosans.ttc"
"Arial TUR,162"="notosans.ttc"
"Courier New"="notosans.ttc"
"Courier New CE,238"="notosans.ttc"
"Courier New CYR,204"="notosans.ttc"
"Courier New Greek,161"="notosans.ttc"
"Courier New TUR,162"="notosans.ttc"
"FixedSys"="notosans.ttc"
"Helv"="notosans.ttc"
"Helvetica"="notosans.ttc"
"Microsoft YaHei"="notosans.ttc"
"MS Sans Serif"="notosans.ttc"
"MS Shell Dlg"="notosans.ttc"
"MS Shell Dlg 2"="notosans.ttc"
"System"="notosans.ttc"
"Tahoma"="notosans.ttc"
"Times"="notosans.ttc"
"Times New Roman CE,238"="notosans.ttc"
"Times New Roman CYR,204"="notosans.ttc"
"Times New Roman Greek,161"="notosans.ttc"
"Times New Roman TUR,162"="notosans.ttc"
"Tms Rmn"="notosans.ttc"
"notosans"="notosans.ttc"
2. Import
WINEPREFIX=~/.deepinwine/Deepin-WeChat deepin-wine regedit
3. Adjust DPI
WINEPREFIX=~/.deepinwine/Deepin-WeChat deepin-wine winecfg
4. Setup Locale
LC_ALL=zh_CN.UTF-8
October 16, 2016 / Kyle Sun / 0 Comments
家里有一台台式机,用着很爽。最近有需要到处使用电脑的需求,手头有一台老旧的macbook air,想来可以试试远程桌面。
NoMachine 的设置很简单,并支持Win/MacOS/Linux和各类手机(未尝试),开箱almost可用,有一些小问题,特此记录一下:
- 我的PC是 linux,又是使用的大屏幕,自动转换分辨率并不支持。
- 我用colemak,PC上的键盘是在固件level改的,而mac的nomachine client无法forward这个设定。
好在 NoMachine 支持 callback custom script,在 session start /disconnect / close 等可以唤醒。设置在 /usr/NX/etc/node.cfg,用 xrandr 来改分辨率,setxkbmap 设置 keyboard layout。
#!/bin/bash
export XAUTHORITY=/home//.Xauthority
export DISPLAY=":0"
xrandr -d :0 --output HDMI-0 --dpi 144 --set audio off --mode 1920x1080 &> /tmp/f.log
setxkbmap us &>> /tmp/f.log
July 18, 2012 / Kyle Sun / 0 Comments
Never use –force unless you know what you are doing!
事情是这样的, 昨晚发现机器上没装php-gd extension, 然后装的时候发现系统很久没升级了, 于是就pacman -Syu了一把, glibc开始报错, /lib下有conflict:
error: failed to commit transaction (conflicting files)
glibc: /lib exists in filesystem
Errors occurred, no packages were upgraded.
一狠心就直接–force了一把, 结果:
> ls
-bash: ls: command not found
于是就尴尬了, 整个 /lib 就这么被踹了, 机器变砖鸟. 好在我不是一个人, 论坛上哭天喊地的一大群人(1,2,3).
还好linode有rescue模式, Lish也很好用, 于是根据 1,2 终于把系统复原, 期间挫折重重.
最重要的一点就是, 下次说啥也不随便 –force 了.
March 29, 2009 / Kyle Sun / 0 Comments
February 21, 2009 / Kyle Sun / 0 Comments
偶真是后知后觉啊,今天看log发现是Feb.7的时候就更新的….
解决办法如下,修改/etc/PolicyKit/PolicyKit.conf (尖括号之间的空格去掉)
< match user="$USER" >
< match action="org.freedesktop.hal.storage.*" >
< return result="yes" >
< /match >
< match action="hal-storage-mount-fixed-extra-options" >
< return result="yes" >
< /match >
< match action="hal-storage-mount-removable-extra-options" >
< return result="yes" >
< /match >
< /match >
ref:
http://www.linuxsir.org/bbs/thread344125.html
http://bbs.archlinux.org/viewtopic.php?id=65070