reworking content
All checks were successful
learn org at code.softwareshinobi.com/linux.softwareshinobi.com/pipeline/head This commit looks good
All checks were successful
learn org at code.softwareshinobi.com/linux.softwareshinobi.com/pipeline/head This commit looks good
This commit is contained in:
23
landing/docs/Bash-Scripts/002-bash-structure.md
Normal file
23
landing/docs/Bash-Scripts/002-bash-structure.md
Normal file
@@ -0,0 +1,23 @@
|
||||
# Bash Basics
|
||||
|
||||
To begin, create a new file with a `.sh` extension. We'll use `shinobi.sh` as our example.
|
||||
|
||||
You can create it instantly with `touch`:
|
||||
|
||||
```bash
|
||||
touch shinobi.sh
|
||||
```
|
||||
|
||||
Or, open it directly in your text editor:
|
||||
|
||||
```bash
|
||||
nano shinobi.sh
|
||||
```
|
||||
|
||||
For your script to execute, the very first line must specify the interpreter. This is called the Shebang. While `#!/bin/bash` instructs the operating system to use `/bin/bash`, its location can vary. For wider compatibility, use this:
|
||||
|
||||
```bash
|
||||
#!/usr/bin/env bash
|
||||
```
|
||||
|
||||
This tells the system to find `bash` within your `PATH` environment variable, ensuring your script runs consistently across different systems.
|
||||
Reference in New Issue
Block a user