forked from mkhan45/RustScript
-
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add build script and windows installer
- Loading branch information
1 parent
48eda52
commit 916663d
Showing
14 changed files
with
71 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,4 +3,5 @@ | |
.project | ||
.settings/org.eclipse.jdt.core.prefs | ||
*.jar | ||
.all-contributorsrc | ||
.all-contributorsrc | ||
dist/bin/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
@echo off | ||
REM Build the RustScript CLI | ||
echo Have you updated the VERSION constant in Cli.java? | ||
set /p version=Version: | ||
@echo on | ||
rmdir dist\bin /S /Q | ||
mkdir dist\bin | ||
javac *.java core/*.java core/formatting/*.java | ||
jar -cvmf manifest.txt dist\bin\rsc.jar *.class core/*.class core/formatting/*.class | ||
cd dist\bin | ||
echo Building native binary... | ||
jpackage --name rsc --input . --main-jar rsc.jar --main-class Cli --type msi --vendor "William Rågstad" --description "The RustScript CLI tool" --app-version %version% --icon ../icon.ico --file-associations ../assoc.properties --win-console | ||
copy ..\README.md . | ||
|
||
@echo off | ||
cd ..\.. | ||
echo. | ||
echo Done! | ||
pause |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
# RustScript CLI (rsc) | ||
Hello and welcome! | ||
Thanks for installing the RustScript CLI toolchain. | ||
|
||
## Usage | ||
|
||
Install the CLI tool to path as shown in a chapter below. Then run: | ||
|
||
```shell | ||
rsc | ||
``` | ||
|
||
This should work from anywhere. | ||
|
||
[Read more](https://github.com/WilliamRagstad/RustScript). | ||
|
||
## Pre-packaged | ||
The `.msi` installer alreay adds file associations for RustScript files, hence you can double click them | ||
to execute them directly in explorer! | ||
|
||
## Install to PATH | ||
Only follow these installation steps if you have installed RustScript in `C:\Program Files\rsc`! | ||
|
||
* Search for `env` in windows and open edit environment variables | ||
* Click on the environment variables button | ||
* Scroll down in the upper (or lower) variable list until you find PATH | ||
* Click edit | ||
* Make sure the current PATH ends with a `;` | ||
* Paste in `C:\Program Files\rsc;` | ||
* OK | ||
* Done! | ||
|
||
You should now be able to open up a new console window and type in the command `rsc` to access | ||
the RustScript CLI from anywhere! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
extension=rs | ||
mime-type=application/rustscript | ||
icon=../file.ico | ||
description=RustScript Executable Script File |
Binary file not shown.
Binary file not shown.
Binary file not shown.