Update README.md

This commit is contained in:
Stone_Red
2023-03-19 01:07:09 +01:00
committed by GitHub
parent ae580599cb
commit 6a8414c0a9
+30 -10
View File
@@ -4,15 +4,17 @@
## What is it?
ClipCMD is a windows app that allows you to create macros and run them by copying them to the clipboard.
You write a macro anywhere, copy it to your clipboard and it will be automatically replaced by the specified macro text.
ClipCMD is a Windows app that allows you to create macros and run them by copying them to the clipboard.\
You write a macro anywhere, copy it to your clipboard, and it will be automatically replaced by the output of the specified macro script.\
ClipCMD uses [PowerShell](https://learn.microsoft.com/en-us/powershell/scripting) as scripting language.
### Example
> Prefix: `_`\
> Suffix: `_`\
> Macro name: `email`\
> Macro text: `[email protected]`
> Macro script: `Write-Output [email protected]`\
> Macro script (alternative): `"[email protected]"`
> Input: `_email_`\
> Output: `[email protected]`
@@ -20,13 +22,31 @@ You write a macro anywhere, copy it to your clipboard and it will be automatical
## Usage
1. Download one of the [releases](https://github.com/Stone-Red-Code/ClipCMD/releases)
1. Start `ClipCMD.exe`
1. Start `setup.exe`
1. (Optional) Set the prefix and suffix for your commands
1. Specify some commands in the built in text field
- Format: `[macroName]>[macroText]`
- Each line is a new macro
1. There are some built in macros like `time` and `date` which will output the current local time and date
1. Write `[suffix][macroName][preffix]` somewhere, and then select it and press ``CTRL+C``
1. Specify some commands in the built-in text field
- Format:
```
[<command name(s) (separated by comma)>]
<scriptText>
<scriptText>
<scriptText>
...
[<command name(s) (separated by comma)>]
<scriptText>
<scriptText>
<scriptText>
...
```
- Strings between square brackets define macros.
- You can define macro aliases by separating them by a comma `[quit, exit, q]`
- Lines between a macro definition and the next macro (or the end of the file) is PowerShell code.
- Everything you write to the output stream replaces the input macro.
- You can pass parameters to the scripts by separating the parameters by space after the macro: `_combine hi nope_`
- You can access the parameters by accessing the `$args` array.
1. There is one prebuilt macro named `list`. This lists all of your macros.
1. Write `[suffix][macroName][preffix]` somewhere, and then select it and press `CTRL+C`
## Preview
<img width="589" alt="Screenshot 2022-05-03 221232" src="https://user-images.githubusercontent.com/56473591/166560142-9e89c57f-1af0-4340-9317-dacf0064d6c8.png">
<img width="591" alt="image" src="https://user-images.githubusercontent.com/56473591/226146460-d9d2e8fc-3754-44c7-bc43-2e32f1d07847.png">