diff options
author | Li Jin <dragon-fly@qq.com> | 2025-01-06 17:36:41 +0800 |
---|---|---|
committer | Li Jin <dragon-fly@qq.com> | 2025-01-06 17:36:41 +0800 |
commit | df5ffc278636d4405e57505d115c052c3652110a (patch) | |
tree | 214b3932d5bfe82f46164d0818144dd5fc6920df | |
parent | ba511abf3c5eed23f4aef0fde0a3e6e0e8f3f41f (diff) | |
download | yuescript-df5ffc278636d4405e57505d115c052c3652110a.tar.gz yuescript-df5ffc278636d4405e57505d115c052c3652110a.tar.bz2 yuescript-df5ffc278636d4405e57505d115c052c3652110a.zip |
Updated readme.
-rw-r--r-- | README.md | 22 |
1 files changed, 11 insertions, 11 deletions
@@ -4,11 +4,11 @@ | |||
4 | 4 | ||
5 | [](https://github.com/pigpigyyy/Yuescript/actions/workflows/ubuntu.yml) [](https://github.com/pigpigyyy/Yuescript/actions/workflows/windows.yml) [](https://github.com/pigpigyyy/Yuescript/actions/workflows/macos.yml) [](https://discord.gg/cRJ2VAm2NV) | 5 | [](https://github.com/pigpigyyy/Yuescript/actions/workflows/ubuntu.yml) [](https://github.com/pigpigyyy/Yuescript/actions/workflows/windows.yml) [](https://github.com/pigpigyyy/Yuescript/actions/workflows/macos.yml) [](https://discord.gg/cRJ2VAm2NV) |
6 | 6 | ||
7 | Yuescript is a Moonscript dialect. It is derived from [Moonscript language](https://github.com/leafo/moonscript) 0.5.0 and continuously adopting new features to be more up to date. | 7 | YueScript is a MoonScript dialect. It is derived from [MoonScript language](https://github.com/leafo/moonscript) 0.5.0 and continuously adopting new features to be more up to date. |
8 | 8 | ||
9 | Moonscript is a language that compiles to Lua. Since original Moonscript has been used to write web framework [lapis](https://github.com/leafo/lapis) and run a few business web sites like [itch.io](https://itch.io) and [streak.club](https://streak.club) with some large code bases. The original language is getting too hard to adopt new features for those may break the stablility for existing applications. | 9 | MoonScript is a language that compiles to Lua. Since original MoonScript has been used to write web framework [lapis](https://github.com/leafo/lapis) and run a few business web sites like [itch.io](https://itch.io) and [streak.club](https://streak.club) with some large code bases. The original language is getting too hard to adopt new features for those may break the stablility for existing applications. |
10 | 10 | ||
11 | So Yuescript is a new code base for pushing the language to go forward and being a playground to try introducing new language syntax or programing paradigms to make Moonscript language more expressive and productive. | 11 | So YueScript is a new code base for pushing the language to go forward and being a playground to try introducing new language syntax or programing paradigms to make MoonScript language more expressive and productive. |
12 | 12 | ||
13 | Yue (月) is the name of moon in Chinese and it's pronounced as [jyɛ]. | 13 | Yue (月) is the name of moon in Chinese and it's pronounced as [jyɛ]. |
14 | 14 | ||
@@ -18,7 +18,7 @@ Yue (月) is the name of moon in Chinese and it's pronounced as [jyɛ]. | |||
18 | 18 | ||
19 | * No other dependencies needed except modified [parserlib](https://github.com/axilmar/parserlib) library from Achilleas Margaritis with some performance enhancement. **lpeg** library is no longer needed. | 19 | * No other dependencies needed except modified [parserlib](https://github.com/axilmar/parserlib) library from Achilleas Margaritis with some performance enhancement. **lpeg** library is no longer needed. |
20 | * Written in C++17. | 20 | * Written in C++17. |
21 | * Support most of the features from Moonscript language. Generate Lua codes in the same way like the original compiler. | 21 | * Support most of the features from MoonScript language. Generate Lua codes in the same way like the original compiler. |
22 | * Reserve line numbers from source file in the compiled Lua codes to help debugging. | 22 | * Reserve line numbers from source file in the compiled Lua codes to help debugging. |
23 | * More features like macro, existential operator, pipe operator, Javascript-like export syntax and etc. | 23 | * More features like macro, existential operator, pipe operator, Javascript-like export syntax and etc. |
24 | * See other details in the [changelog](./CHANGELOG.md). Find document [here](http://yuescript.org). | 24 | * See other details in the [changelog](./CHANGELOG.md). Find document [here](http://yuescript.org). |
@@ -43,7 +43,7 @@ Yue (月) is the name of moon in Chinese and it's pronounced as [jyɛ]. | |||
43 | > luarocks install yuescript | 43 | > luarocks install yuescript |
44 | ``` | 44 | ``` |
45 | 45 | ||
46 |   Then require the Yuescript module in Lua: | 46 |   Then require the YueScript module in Lua: |
47 | 47 | ||
48 | ```Lua | 48 | ```Lua |
49 | require("yue")("main") -- require `main.yue` | 49 | require("yue")("main") -- require `main.yue` |
@@ -69,17 +69,17 @@ f! | |||
69 | > make install | 69 | > make install |
70 | ``` | 70 | ``` |
71 | 71 | ||
72 |   Build Yuescript tool without macro feature: | 72 |   Build YueScript tool without macro feature: |
73 | ```sh | 73 | ```sh |
74 | > make install NO_MACRO=true | 74 | > make install NO_MACRO=true |
75 | ``` | 75 | ``` |
76 | 76 | ||
77 |   Build Yuescript tool without built-in Lua binary: | 77 |   Build YueScript tool without built-in Lua binary: |
78 | ```sh | 78 | ```sh |
79 | > make install NO_LUA=true | 79 | > make install NO_LUA=true |
80 | ``` | 80 | ``` |
81 | 81 | ||
82 |   Use Yuescript tool with: | 82 |   Use YueScript tool with: |
83 | 83 | ||
84 | ```sh | 84 | ```sh |
85 | > yue -h | 85 | > yue -h |
@@ -110,18 +110,18 @@ Usage: yue [options|files|directories] ... | |||
110 | in a single line to start/stop multi-line mode | 110 | in a single line to start/stop multi-line mode |
111 | ``` | 111 | ``` |
112 |   Use cases: | 112 |   Use cases: |
113 |   Recursively compile every Yuescript file with extension `.yue` under current path: `yue .` | 113 |   Recursively compile every YueScript file with extension `.yue` under current path: `yue .` |
114 |   Compile and save results to a target path: `yue -t /target/path/ .` | 114 |   Compile and save results to a target path: `yue -t /target/path/ .` |
115 |   Compile and reserve debug info: `yue -l .` | 115 |   Compile and reserve debug info: `yue -l .` |
116 |   Compile and generate minified codes: `yue -m .` | 116 |   Compile and generate minified codes: `yue -m .` |
117 |   Execute raw codes: `yue -e 'print 123'` | 117 |   Execute raw codes: `yue -e 'print 123'` |
118 |   Execute a Yuescript file: `yue -e main.yue` | 118 |   Execute a YueScript file: `yue -e main.yue` |
119 | 119 | ||
120 | 120 | ||
121 | 121 | ||
122 | ## Editor Support | 122 | ## Editor Support |
123 | 123 | ||
124 | * [Vim](https://github.com/pigpigyyy/Yuescript-vim) | 124 | * [Vim](https://github.com/pigpigyyy/YueScript-vim) |
125 | * [ZeroBraneStudio](https://github.com/pkulchenko/ZeroBraneStudio/issues/1134) (Syntax highlighting) | 125 | * [ZeroBraneStudio](https://github.com/pkulchenko/ZeroBraneStudio/issues/1134) (Syntax highlighting) |
126 | * [Visual Studio Code](https://github.com/pigpigyyy/yuescript-vscode) | 126 | * [Visual Studio Code](https://github.com/pigpigyyy/yuescript-vscode) |
127 | 127 | ||