mirror of
https://github.com/nsnail/spectre.console.git
synced 2025-07-05 03:58:16 +08:00
Update emoji support
* Add constants for emojis * Move emoji shortcode rendering to Markup * Add documentation * Add example * Add tests
This commit is contained in:

committed by
Patrik Svensson

parent
090b30f731
commit
eeb3f967b6
@ -4,6 +4,7 @@
|
||||
|
||||
$Output = Join-Path $PSScriptRoot "Temp"
|
||||
$Source = Join-Path $PSScriptRoot "/../../src/Spectre.Console"
|
||||
$Docs = Join-Path $PSScriptRoot "/../../docs/src/Data"
|
||||
|
||||
if(!(Test-Path $Output -PathType Container)) {
|
||||
New-Item -ItemType Directory -Path $Output | Out-Null
|
||||
@ -11,7 +12,7 @@ if(!(Test-Path $Output -PathType Container)) {
|
||||
|
||||
# Generate the files
|
||||
Push-Location Generator
|
||||
&dotnet run -- emoji "$Output"
|
||||
&dotnet run -- emoji "$Output" --input $Output
|
||||
if(!$?) {
|
||||
Pop-Location
|
||||
Throw "An error occured when generating code."
|
||||
@ -19,4 +20,5 @@ if(!$?) {
|
||||
Pop-Location
|
||||
|
||||
# Copy the files to the correct location
|
||||
Copy-Item (Join-Path "$Output" "Emoji.Generated.cs") -Destination "$Source/Emoji.Generated.cs"
|
||||
Copy-Item (Join-Path "$Output" "Emoji.Generated.cs") -Destination "$Source/Emoji.Generated.cs"
|
||||
Copy-Item (Join-Path "$Output" "emojis.json") -Destination "$Docs/emojis.json"
|
Reference in New Issue
Block a user