1
0
mirror of https://github.com/casey/just synced 2024-07-03 08:18:53 +00:00

Differentiate between shell and nushell example (#1427)

This commit is contained in:
Dialga 2022-12-18 13:50:35 +13:00 committed by GitHub
parent d530fea378
commit c7acaa82cb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 4 deletions

View File

@ -1699,7 +1699,7 @@ saving the recipe body to a file and running it. This lets you write recipes in
different languages:
```just
polyglot: python js perl sh ruby
polyglot: python js perl sh ruby nu
python:
#!/usr/bin/env python3
@ -1720,8 +1720,8 @@ sh:
nu:
#!/usr/bin/env nu
let hello = 'Yo'
echo $"($hello) from a shell script!"
let hello = 'Hola'
echo $"($hello) from a nushell script!"
ruby:
#!/usr/bin/env ruby
@ -1735,6 +1735,7 @@ Greetings from JavaScript!
Larry Wall says Hi!
Yo from a shell script!
Hello from ruby!
Hola from a nushell script!
```
On Unix-like operating systems, including Linux and MacOS, shebang recipes are

View File

@ -1704,7 +1704,7 @@ sh:
nu:
#!/usr/bin/env nu
let hello = 'Yo'
echo $"($hello) from a shell script!"
echo $"($hello) from a nushell script!"
ruby:
#!/usr/bin/env ruby