🐛 新增英文和缩起

This commit is contained in:
Tw93
2022-12-03 18:03:18 +08:00
parent 8a682ef828
commit e96086caa8
2 changed files with 111 additions and 11 deletions

View File

@@ -26,6 +26,8 @@
## Download
<details>
<summary>A lot of surprise sense of app, click to see ❤️.</summary>
<table>
<tr>
<td>WeRead
@@ -92,9 +94,30 @@
<td><img src=https://cdn.fliggy.com/upic/02SZQl.png width=600/></td>
</tr>
</table>
</details>
Note: it cannot be installed to C:\Program File under Windows, and it will crash directly. It is recommended to install to other non-administrator directories, such as D:\Program Files (x86).
## Command line packing
<kbd>
<img src="https://cdn.fliggy.com/upic/cOC1lF.gif" width="100%">
</kbd>
<br/><br/>
**Pake provides a command line tool that makes it quicker and easier to customize the packages you need with one click, as detailed in [documentation](./bin/README_EN.md).**
```bash
// Install with npm
npm install -g pake-cli
// Command usage
pake url [options]
// Play casually,first time due to the installation environment will be a little slow
pake https://weekly.tw93.fun --name Weekly --transparent
```
## Shortcuts
| Mac | Windows/Linux | Function |
@@ -132,16 +155,8 @@ npm run build:windows
// Pack Linux application
npm run build:linux
// One-click packaging of all Linux/Mac projects
chmod +x build.sh && ./build.sh
// One-click packaging of all Windows projects
.\build.bat
```
// Package all your projects in one click
chmod +x build.sh && ./build.sh
## New pack
1. Modify the `tauri.conf.json` in the `src-tauri` directory to include 4 fields `url, productName, icon, identifier`, icon can be selected from the `icons` directory or downloaded from [macOSicons](https://macosicons.com/#/) to match the product.
@@ -165,9 +180,9 @@ Refer to the communication code in `pake.js` with `postMessage`, write the event
## Support
- I have two cats, one is called TangYuan, and one is called Coke, If you think Pake makes your life better, you can give my cats <a href="https://miaoyan.app/cats.html?name=Pake" target="_blank">feed canned food 🥩🍤</a>.
- If you like Pake, you can star it in Github. We are more welcome to [recommend Pake](https://twitter.com/intent/tweet?url=https://github.com/tw93/Pake&text=Pake%20-%20A%20simple%20Rust%20packaged%20web%20pages%20to%20generate%20Mac%20App%20tool,%20compared%20to%20traditional%20Electron%20package,%20the%20size%20of%20nearly%2040%20times%20smaller,%20generally%20about%202M,%20the%20underlying%20use%20of%20Tauri,%20performance%20experience%20than%20the%20JS%20framework%20is%20much%20lighter~) to your like-minded friends.
- You can follow my [Twitter](https://twitter.com/HiTw93) to get the latest news of Pake, or join [Telegram](https://t.me/miaoyan) chat group.
- I have two cats, one is called TangYuan, and one is called Coke, If you think Pake makes your life better, you can give my cats <a href="https://miaoyan.app/cats.html?name=Pake" target="_blank">feed canned food 🥩🍤</a>.
- If you like Pake, you can star it in Github. We are more welcome to [recommend Pake](https://twitter.com/intent/tweet?url=https://github.com/tw93/Pake&text=Pake%20-%20A%20simple%20Rust%20packaged%20web%20pages%20to%20generate%20Mac%20App%20tool,%20compared%20to%20traditional%20Electron%20package,%20the%20size%20of%20nearly%2040%20times%20smaller,%20generally%20about%202M,%20the%20underlying%20use%20of%20Tauri,%20performance%20experience%20than%20the%20JS%20framework%20is%20much%20lighter~) to your like-minded friends.
- You can follow my [Twitter](https://twitter.com/HiTw93) to get the latest news of Pake, or join [Telegram](https://t.me/miaoyan) chat group.
## Finally

85
bin/README_EN.md vendored Normal file
View File

@@ -0,0 +1,85 @@
## Install
```bash
npm install -g pake-cli
```
If the installation fails and you are prompted that you do not have permission, please use `sudo` to run.
## Usage
```bash
pake url [options]
```
After the packaging, the application defaults to the current working directory. Since the environment needs to be configured for the first packaging, it will take some time. Please wait patiently.
Note: The Rust environment is required for packaging. If you do not have Rust, you will be prompted to confirm the installation. If the installation fails or times out, you can [install](https://www.rust-lang.org/tools/install) it yourself.
Note: Currently only Macos are supported, and other platforms will be supported later.
### url
The url🔗 is the webpage link you need to package, Must be provided.
### [options]
Some specific options are provided. When packaging, corresponding parameters can be passed to achieve customized effects.
#### [name]
The application name, if not specified when entering, will prompt you to enter.
```shell
--name <value>
```
#### [icon]
应用 icon支持本地/远程文件,默认为 Pake 自带图标。
- MacOS must be `.icns`
```shell
--icon <path>
```
#### [height]
The height of the packaged application window. The default is `800px`.
```shell
--height <number>
```
#### [width]
The width of the packaged application window. The default is `1280px`.
```shell
--width <number>
```
#### [transparent]
Whether to enable the immersive header. The default is `false`.
```shell
--transparent
```
#### [resize]
Whether the size can be dragged. The default value is `true`.
```shell
--no-resizable
```
#### [fullscreen]
Whether to open the full screen after opening the application. The default is `false`.
```shell
--fullscreen <value>
```