Skip to content

Commit

Permalink
Provide selection for swapkeys in bootloader (#32)
Browse files Browse the repository at this point in the history
  • Loading branch information
clsty committed Jul 2, 2024
1 parent 1403b1b commit 0a8f583
Show file tree
Hide file tree
Showing 8 changed files with 21 additions and 21 deletions.
10 changes: 4 additions & 6 deletions anotherpac/stored/etc/motd-zh_CN
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,10 @@
 欢迎使用 arCNiso 
 

 1  重要   左 Ctrl 键   大写锁定键  默认互换;要取消请输入 resetkeymap。
 1  联网  无线网:请使用 NetworkManager 相关工具,如 nmtui(在其“启用连接”中扫描并连接 WiFi)。WWAN 调制解调器(Mobile Broadband):请使用 mmcli。支持 DHCP 的有线网:应当自动可用

 2  联网  无线网:请使用 NetworkManager 相关工具,如 nmtui(在其“启用连接”中扫描并连接 WiFi)。WWAN 调制解调器(Mobile Broadband):请使用 mmcli。支持 DHCP 的有线网:应当自动可用
 2  获取帮助  首次使用 arCNiso 可阅读本项目自述文档的“使用指南”部分,为此可输入 README;若要安装 Arch Linux,可输入 arcnguide 访问安装指南与提示

 3  获取帮助  首次使用 arCNiso 可阅读本项目自述文档的“使用指南”部分,为此可输入 README;若要安装 Arch Linux,可输入 arcnguide 访问安装指南与提示
 3  若空间不足  默认根分区大小为 1 GiB,可使用 modifyrootspace 实时修改根分区大小(会占用相应大小的内存);或自行挂载外部存储以转移数据

 4  若空间不足  默认根分区大小为 1 GiB,可使用 modifyrootspace 实时修改根分区大小(会占用相应大小的内存);或自行挂载外部存储以转移数据。

 5  平板电脑  可使用蓝牙管理器连接蓝牙键盘,或者使用屏幕键盘 Onboard(启动器位于屏幕右下角)。
 4  平板电脑  可使用蓝牙管理器连接蓝牙键盘,或者使用屏幕键盘 Onboard(启动器位于屏幕右下角)。
9 changes: 9 additions & 0 deletions anotherpac/stored/usr/local/arCNiso/prepare.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,12 @@
# 此脚本在开机启动时用 systemd 自动运行。
locale-gen
runuser -l archer -c 'tilix-dconf load'

function resetkeymap(){
rm -f \
/home/archer/.xmodmap \
/root/.xmodmap \
/etc/X11/xorg.conf.d/10-keyboard.conf \
/etc/vconsole.conf
}
cat /proc/cmdline | grep -q 'swapctrlcaps=true' || resetkeymap
10 changes: 0 additions & 10 deletions anotherpac/stored/usr/local/bin/resetkeymap

This file was deleted.

2 changes: 1 addition & 1 deletion docs/src/content/docs/design/feature.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ sidebar:
# 硬件与外设

## 全局键位
tty 与图形界面中,均交换了左 `Ctrl` 与大写锁定键,并提供了 `resetkeymap` 命令供复原
Bootloader 界面可以选择交换左 `Ctrl` 与大写锁定键。
## 蓝牙
配置了蓝牙所需的软件包、内核模块与服务。
## 屏幕键盘
Expand Down
1 change: 0 additions & 1 deletion docs/src/content/docs/design/howhard.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@ arCNiso 本质上仍然是 archiso。
- 命令 eviltutor 可供学习 Vim 式编辑器的基本操作;
- 命令 paru 与 parui 会自动先更新 pacman 数据库并安装 base-devel;
- 命令 modifyrootspace 可修改根分区容量大小;
- 命令 resetkeymap 将重置键位映射;
- ……


Expand Down
4 changes: 2 additions & 2 deletions efiboot/loader/entries/01-archiso-x86_64-linux.conf
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
title Arch Linux install medium (x86_64, UEFI)
title arCNiso (x86_64, UEFI)
sort-key 01
linux /%INSTALL_DIR%/boot/x86_64/vmlinuz-linux
initrd /%INSTALL_DIR%/boot/x86_64/initramfs-linux.img
options archisobasedir=%INSTALL_DIR% archisosearchuuid=%ARCHISO_UUID% usbcore.autosuspend=-1 btusb.enable_autosuspend=N bluetooth.disable_ertm=Y cow_spacesize=1G
options archisobasedir=%INSTALL_DIR% archisosearchuuid=%ARCHISO_UUID% usbcore.autosuspend=-1 btusb.enable_autosuspend=N bluetooth.disable_ertm=Y cow_spacesize=1G swapctrlcaps=false
5 changes: 5 additions & 0 deletions efiboot/loader/entries/04-archiso-x86_64-linux-swapctrl.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
title arCNiso, Ctrl and Caps keys swapped (x86_64, UEFI)
sort-key 04
linux /%INSTALL_DIR%/boot/x86_64/vmlinuz-linux
initrd /%INSTALL_DIR%/boot/x86_64/initramfs-linux.img
options archisobasedir=%INSTALL_DIR% archisosearchuuid=%ARCHISO_UUID% usbcore.autosuspend=-1 btusb.enable_autosuspend=N bluetooth.disable_ertm=Y cow_spacesize=1G swapctrlcaps=true
1 change: 0 additions & 1 deletion profiledef.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ file_permissions=(
["/usr/local/bin/arcnadd-cn"]="0:0:755"
["/usr/local/bin/arcnot"]="0:0:755"
["/usr/local/bin/tilix-dconf"]="0:0:755"
["/usr/local/bin/resetkeymap"]="0:0:755"
["/usr/local/bin/aaa"]="0:0:755"
["/usr/local/bin/emacsnw"]="0:0:755"
["/usr/local/bin/emacstutor"]="0:0:755"
Expand Down

0 comments on commit 0a8f583

Please sign in to comment.