mirror of
https://github.com/m-lamonaca/script-launcher.git
synced 2025-05-15 09:44:46 +00:00
Update README & install scripts
This commit is contained in:
parent
dc40ced033
commit
6a01577912
4 changed files with 53 additions and 29 deletions
52
README.md
52
README.md
|
@ -1,3 +1,53 @@
|
|||
# Script Launcher
|
||||
|
||||
Find executable scripts in a directory and allow to select which one to execute
|
||||
Find executable scripts in a directory and allow to select which one to execute.
|
||||
|
||||
## Installation
|
||||
|
||||
### As .NET CLI Tool
|
||||
|
||||
To be installed as a tool, you need the [.NET CLI][CLI] which is included in the [.NET SDK][SDK]
|
||||
|
||||
Install manually using the following commands or by using the provided installation scripts.
|
||||
|
||||
```sh
|
||||
dotnet pack ./src -o ./nupkg
|
||||
dotnet tool install -g ScriptLauncher --add-source ./nupkg --ignore-failed-sources
|
||||
```
|
||||
|
||||
### As a Standalone Executable
|
||||
|
||||
You will need the identifier of the .NET Runtime ([RID]) and the Target Framework Moniker ([TFM]) for your OS and Runtime.
|
||||
|
||||
```sh
|
||||
# self contained: will not need the .NET runtime to function, bigger resulting size
|
||||
dotnet publish -c Release --self-contained -p:PublishSingleFile=true -p:PublishTrimmed=true -f <TFM> -r <RID> -o <output-directory> ./src
|
||||
|
||||
# no self contained: will need the .NET runtime to be installed to function, smallest size
|
||||
dotnet publish -c Release --no-self-contained -p:PublishSingleFile=true -r <RID> -o <output-directory> ./src
|
||||
```
|
||||
|
||||
_**NOTE**_: The option `-p:PublishTrimmed=true` may produce some *warnings*. If so simply skip that option and the resulting executable will be larger
|
||||
|
||||
## Usage
|
||||
|
||||
```sh
|
||||
Usage: script-launcher [--extensions <String>] [--depth <Int32>] [--elevated] [--group] [--brief] [--help] [--version] directory
|
||||
|
||||
Arguments:
|
||||
0: directory Starting directory (Default: .)
|
||||
|
||||
Options:
|
||||
-x, --extensions <String> Comma separated list of script extensions
|
||||
-d, --depth <Int32> Search depth (Default: 1)
|
||||
-e, --elevated Run with elevated privileges
|
||||
-g, --group Group scripts by folder
|
||||
-b, --brief Show brief information
|
||||
-h, --help Show help message
|
||||
--version Show version
|
||||
```
|
||||
|
||||
[CLI]: https://docs.microsoft.com/en-us/dotnet/core/tools/ ".NET CLI Docs"
|
||||
[SDK]: https://dotnet.microsoft.com/en-us/download ".NET SDK Downloads"
|
||||
[RID]: https://docs.microsoft.com/en-us/dotnet/core/rid-catalog "Runtime IDs Catalog"
|
||||
[TFM]: https://docs.microsoft.com/en-us/dotnet/standard/frameworks "Target Framework Moniker Docs"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue