Skip to content

Commit 8f9908f

Browse files
committed
chore: 更新README.md和metadata.json
- 更新README.md中的插件介绍和安装说明 - 更新metadata.json中的版本号为1.3
1 parent 9e16c9f commit 8f9908f

File tree

3 files changed

+33
-73
lines changed

3 files changed

+33
-73
lines changed

README.md

Lines changed: 32 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -1,89 +1,56 @@
1-
# Reboot to Windows / 重启到Windows
1+
# Reboot to Windows / 一键重启到Windows
22

3-
This is a small Gnome extension that adds the ability to reboot directly to the Windows when using grub.
3+
This is a small Gnome extension that adds the ability to reboot directly to the Windows when using grub. support Chinese and English.
44

5-
此Gnome扩展允许您从重启菜单中一键重启到Windows。
5+
此Gnome扩展允许您从重启菜单中一键重启到Windows。支持中文和英文。
66

7-
![Screenshot of the extension option in the Gnome 45.1 menu](images/screenshot.png)
8-
9-
10-
# 警告
11-
12-
**此插件不在Gnome扩展站点上提供!**
13-
14-
#### Q:为什么此插件不在Gnome扩展商店提供?
15-
16-
A:此插件不符合Gnome扩展开发规范,其调用了本地的脚本文件实现。
17-
18-
#### Q:为什么不按照开发规范开发此插件?
19-
20-
A:很抱歉,在过去的3天中,我尝试了所有我能尝试的方法来将脚本文件嵌入到`extension.js`文件中,但是最终都以失败告终。其中包括但不限于:大量的转义字符,缺乏subprocesses函数相关的文档。
21-
如果您有相关开发经验,能为此插件制作满足开发规范的版本,感激不尽。
22-
23-
#### Q:现在插件是如何实现的?
7+
> [!NOTE]
8+
>
9+
> This project has only been tested on Arch Linux, but should work with all Linux distributions that use grub.
10+
> If you encounter any issues while using it, please feel free to contact me. I am more than happy to help you troubleshoot.
11+
>
12+
> 此项目仅在Arch Linux上进行了测试,但应该适用于所有使用grub的Linux发行版。
13+
> 如果您在使用中遇到任何问题,请随时联系我。很乐意帮助您解决问题。
2414
25-
A:插件会在您执行安装脚本(`install.sh`)时在用户目录下生成一个shell程序,此后当您执行此插件时,该脚本会被调用。
26-
27-
#### Q:我安装了插件后没有出现该菜单?
28-
29-
A:Gnome可能默认关闭了所有扩展,请在你的程序库中找到`扩展`启用扩展功能,并启用reboot2win扩展。
30-
31-
32-
# Warning
33-
**This plugin is not available on the Gnome Extensions website!**
34-
35-
#### Q: Why is this plugin not available on the Gnome Extensions store?
36-
37-
A: This plugin does not comply with the Gnome Extensions development guidelines as it calls local script files.
15+
![Screenshot of the extension option in the Gnome 45.1 menu](images/screenshot.png)
3816

39-
#### Q: Why wasn't this plugin developed according to the guidelines?
4017

41-
A: I apologize, but over the past three days, I have tried every method I could think of to embed the script file into the extension.js file, but all attempts have failed. This includes, but is not limited to, extensive use of escape characters and a lack of documentation on subprocess functions. If you have relevant development experience and can create a version of this plugin that meets the development guidelines, I would greatly appreciate it.
18+
#### Q: I installed the plugin, but the menu is not appearing. What should I do? / 我安装了插件后没有出现该菜单?
4219

43-
#### Q: How is the plugin currently implemented?
20+
A:Gnome may have all extensions disabled by default. Please find "Extensions" in your application library, enable extension functionality, and enable the "reboot2win" extension.
4421

45-
A: When you run the installation script (install.sh), the plugin will generate a shell program in your user directory. Subsequently, when you execute the plugin, that script will be invoked.
22+
Gnome可能默认关闭了所有扩展,请在你的程序库中找到`扩展`启用扩展功能,并启用reboot2win扩展。
4623

47-
#### Q: I installed the plugin, but the menu is not appearing. What should I do?
24+
# Installation / 安装
4825

49-
A: Gnome may have all extensions disabled by default. Please find "Extensions" in your application library, enable extension functionality, and enable the "reboot2win" extension.
26+
> [!NOTE]
27+
>
28+
> 此插件已提交到Gnome官方扩展商店审核~
5029
51-
# 安装
30+
### Download / 下载插件
5231

53-
### 下载插件
32+
You can clone the project from GitHub.
5433
从GitHub克隆该存储库。
5534

5635
`$ git clone https://github.com/Coooolfan/Reboot2Windows`
5736

58-
### 构建插件
59-
要构建插件,请运行以下命令:
37+
### Build / 构建插件
6038

61-
`$ sh build.sh`
62-
63-
如果一切顺利,这将在项目文件夹中生成一个zip文件。
64-
65-
### 安装插件
66-
要安装插件,只需运行install.sh脚本,并使用以下命令:
67-
68-
`$ sh install.sh`
69-
70-
### Download the extension
39+
If you want to build the plugin, run the following command:
7140

72-
clone this repository from github.
73-
74-
`$ git clone https://github.com/Coooolfan/Reboot2Windows`
41+
要构建插件,请运行以下命令:
7542

76-
### Build the extension
43+
`$ sh build.sh`
7744

78-
To build the extension run the following command:
45+
If everything goes well, a zip file will be generated in the project folder.
7946

80-
`$ sh build.sh`
47+
如果一切顺利,这将在项目文件夹中生成一个zip文件。
8148

82-
If all goes well this will generate a zip file in the project folder.
49+
### Install / 安装插件
8350

84-
### Install the extension
51+
To install the plugin, simply run the install.sh script with the following command:
8552

86-
To install the extension just run the **install.sh** script with the following command:
53+
要安装插件,只需运行install.sh脚本,并使用以下命令:
8754

8855
`$ sh install.sh`
8956

@@ -97,3 +64,6 @@ Special thanks to the author of reboottouefi for open-sourcing the plugin at [re
9764

9865
I would also like to express my gratitude to the friends within the archlinuxcn community who have generously contributed their time, helping me troubleshoot various issues during the plugin development process.
9966

67+
# for Developer
68+
69+
<https://gjs.guide/extensions/#introduction>

install.sh

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,3 @@
11
#!/bin/bash
22

3-
# base64解码后的内容为/The decoded content of Base64 is:
4-
#
5-
# WINDOWS_TITLE=`grep -i 'windows' /boot/grub/grub.cfg|cut -d"'" -f2`
6-
# sudo grub-reboot "$WINDOWS_TITLE"
7-
# sudo reboot
8-
9-
echo "V0lORE9XU19USVRMRT1gZ3JlcCAtaSAnd2luZG93cycgL2Jvb3QvZ3J1Yi9ncnViLmNmZ3xjdXQgLWQiJyIgLWYyYApzdWRvIGdydWItcmVib290ICIkV0lORE9XU19USVRMRSIKc3VkbyByZWJvb3QK" | base64 --decode > ~/.reboot2win.sh
10-
11-
chmod +x ~/.reboot2win.sh
12-
133
gnome-extensions install [email protected]

src/metadata.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"license": "GPLv3",
55
"uuid": "[email protected]",
66
"url": "https://github.com/Coooolfan/Reboot2Windows",
7-
"version": "1.2",
7+
"version": "1.3",
88
"shell-version": [
99
"46",
1010
"47"

0 commit comments

Comments
 (0)