mirror of
https://github.com/flokoe/bash-hackers-wiki.git
synced 2024-11-25 07:43:42 +01:00
Fix tags
This commit is contained in:
parent
4a717b40fb
commit
02ecdc79fb
@ -1,6 +1,13 @@
|
|||||||
# Calculating with dc
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- arithmetic
|
||||||
|
- calculate
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting arithmetic calculate)
|
# Calculating with dc
|
||||||
|
|
||||||
## Introduction
|
## Introduction
|
||||||
|
|
||||||
|
@ -1,6 +1,14 @@
|
|||||||
# Collapsing Functions
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- example
|
||||||
|
- function
|
||||||
|
- collapse
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting example function collapse)
|
# Collapsing Functions
|
||||||
|
|
||||||
## What is a \"Collapsing Function\"?
|
## What is a \"Collapsing Function\"?
|
||||||
|
|
||||||
|
@ -1,6 +1,15 @@
|
|||||||
# Config files for your script
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- config
|
||||||
|
- files
|
||||||
|
- include
|
||||||
|
- configuration
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting config files include configuration)
|
# Config files for your script
|
||||||
|
|
||||||
## General
|
## General
|
||||||
|
|
||||||
|
@ -1,6 +1,17 @@
|
|||||||
# Editing files via scripts with ed
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- arguments
|
||||||
|
- file
|
||||||
|
- editor
|
||||||
|
- edit
|
||||||
|
- ed
|
||||||
|
- sed
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting arguments file editor edit ed sed)
|
# Editing files via scripts with ed
|
||||||
|
|
||||||
## Why ed?
|
## Why ed?
|
||||||
|
|
||||||
|
@ -1,6 +1,17 @@
|
|||||||
# Small getopts tutorial
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- arguments
|
||||||
|
- positional
|
||||||
|
- parameters
|
||||||
|
- options
|
||||||
|
- getopt
|
||||||
|
- getopts
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting arguments positional parameters options getopt getopts)
|
# Small getopts tutorial
|
||||||
|
|
||||||
## Description
|
## Description
|
||||||
|
|
||||||
|
@ -1,6 +1,14 @@
|
|||||||
# Lock your script (against parallel execution)
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- mutex
|
||||||
|
- locking
|
||||||
|
- run-control
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting mutex locking run-control)
|
# Lock your script (against parallel execution)
|
||||||
|
|
||||||
## Why lock?
|
## Why lock?
|
||||||
|
|
||||||
|
@ -1,6 +1,16 @@
|
|||||||
# pax - the POSIX archiver
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- POSIX
|
||||||
|
- archive
|
||||||
|
- tar
|
||||||
|
- packing
|
||||||
|
- zip
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting POSIX archive tar packing zip)
|
# pax - the POSIX archiver
|
||||||
|
|
||||||
pax can do a lot of fancy stuff, feel free to contribute more awesome
|
pax can do a lot of fancy stuff, feel free to contribute more awesome
|
||||||
pax tricks!
|
pax tricks!
|
||||||
|
@ -1,6 +1,16 @@
|
|||||||
# Illustrated Redirection Tutorial
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- tutorial
|
||||||
|
- redirection
|
||||||
|
- redirect
|
||||||
|
- file
|
||||||
|
- descriptor
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting tutorial redirection redirect file descriptor)
|
# Illustrated Redirection Tutorial
|
||||||
|
|
||||||
This tutorial is not a complete guide to redirection, it will not cover
|
This tutorial is not a complete guide to redirection, it will not cover
|
||||||
here docs, here strings, name pipes etc\... I just hope it\'ll help you
|
here docs, here strings, name pipes etc\... I just hope it\'ll help you
|
||||||
|
@ -1,6 +1,15 @@
|
|||||||
# List of shell options
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- options
|
||||||
|
- runtime
|
||||||
|
- variable
|
||||||
|
- behaviour
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting options runtime variable behaviour)
|
# List of shell options
|
||||||
|
|
||||||
This information was taken from a Bash version \"`4.1`\", every now and
|
This information was taken from a Bash version \"`4.1`\", every now and
|
||||||
then new options are added, so likely, this list isn't complete.
|
then new options are added, so likely, this list isn't complete.
|
||||||
|
@ -1,6 +1,16 @@
|
|||||||
# Bash's behaviour
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- startup
|
||||||
|
- files
|
||||||
|
- dotfiles
|
||||||
|
- modes
|
||||||
|
- POSIX
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting startup files dotfiles modes POSIX)
|
# Bash's behaviour
|
||||||
|
|
||||||
FIXME incomplete
|
FIXME incomplete
|
||||||
|
|
||||||
|
@ -1,6 +1,14 @@
|
|||||||
# The basics of shell scripting
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- basics
|
||||||
|
- learning
|
||||||
|
- tutorial
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting basics learning tutorial)
|
# The basics of shell scripting
|
||||||
|
|
||||||
## Script files
|
## Script files
|
||||||
|
|
||||||
|
@ -1,6 +1,14 @@
|
|||||||
# Debugging a script
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- bug
|
||||||
|
- debug
|
||||||
|
- debugging
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting bug debug debugging)
|
# Debugging a script
|
||||||
|
|
||||||
These few lines are not intended as a full-fledged debugging tutorial,
|
These few lines are not intended as a full-fledged debugging tutorial,
|
||||||
but as hints and comments about debugging a Bash script.
|
but as hints and comments about debugging a Bash script.
|
||||||
|
@ -1,6 +1,14 @@
|
|||||||
# Beginner Mistakes
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- pitfalls
|
||||||
|
- traps
|
||||||
|
- beginners
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting pitfalls traps beginners)
|
# Beginner Mistakes
|
||||||
|
|
||||||
Here are some typical traps:
|
Here are some typical traps:
|
||||||
|
|
||||||
|
@ -1,6 +1,14 @@
|
|||||||
# Portability talk
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- portability
|
||||||
|
- POSIX
|
||||||
|
- portable
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting portability POSIX portable)
|
# Portability talk
|
||||||
|
|
||||||
The script programming language of BASH is based on the Bourne Shell
|
The script programming language of BASH is based on the Bourne Shell
|
||||||
syntax, with some extensions and derivations.
|
syntax, with some extensions and derivations.
|
||||||
|
@ -1,6 +1,14 @@
|
|||||||
# Obsolete and deprecated syntax
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- obsolete
|
||||||
|
- deprecated
|
||||||
|
- outdated
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting obsolete deprecated outdated)
|
# Obsolete and deprecated syntax
|
||||||
|
|
||||||
This (incomplete) page describes some syntax and commands considered
|
This (incomplete) page describes some syntax and commands considered
|
||||||
obsolete by some measure. A thorough discussion of the rationale is
|
obsolete by some measure. A thorough discussion of the rationale is
|
||||||
|
@ -1,6 +1,15 @@
|
|||||||
# Handling positional parameters
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- arguments
|
||||||
|
- positional
|
||||||
|
- parameters
|
||||||
|
- options
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting arguments positional parameters options)
|
# Handling positional parameters
|
||||||
|
|
||||||
## Intro
|
## Intro
|
||||||
|
|
||||||
|
@ -1,6 +1,15 @@
|
|||||||
# Bash and the process tree
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- processes
|
||||||
|
- pipes
|
||||||
|
- variables
|
||||||
|
- environment
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting processes pipes variables environment)
|
# Bash and the process tree
|
||||||
|
|
||||||
## The process tree
|
## The process tree
|
||||||
|
|
||||||
|
@ -1,6 +1,16 @@
|
|||||||
# Terminal codes (ANSI/VT100) introduction
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- colors
|
||||||
|
- cursor
|
||||||
|
- control
|
||||||
|
- vt100
|
||||||
|
- ansi
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting colors cursor control vt100 ansi)
|
# Terminal codes (ANSI/VT100) introduction
|
||||||
|
|
||||||
Terminal (control) codes are used to issue specific commands to your
|
Terminal (control) codes are used to issue specific commands to your
|
||||||
terminal. This can be related to switching colors or positioning the
|
terminal. This can be related to switching colors or positioning the
|
||||||
|
@ -1,6 +1,16 @@
|
|||||||
# Arithmetic expressions
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- math
|
||||||
|
- arithmetic
|
||||||
|
- C
|
||||||
|
- calculation
|
||||||
|
- integer
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting math arithmetic C calculation integer)
|
# Arithmetic expressions
|
||||||
|
|
||||||
Arithmetic expressions are used in several situations:
|
Arithmetic expressions are used in several situations:
|
||||||
|
|
||||||
|
@ -1,6 +1,14 @@
|
|||||||
# Basic grammar rules of Bash
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- grammar
|
||||||
|
- syntax
|
||||||
|
- language
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting grammar syntax language)
|
# Basic grammar rules of Bash
|
||||||
|
|
||||||
Bash builds its features on top of a few basic **grammar rules**. The
|
Bash builds its features on top of a few basic **grammar rules**. The
|
||||||
code you see everywhere, the code you use, is based on those rules.
|
code you see everywhere, the code you use, is based on those rules.
|
||||||
|
@ -1,6 +1,16 @@
|
|||||||
# Brace expansion
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- expansion
|
||||||
|
- substitution
|
||||||
|
- text
|
||||||
|
- list
|
||||||
|
- brace
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting expansion substitution text list brace)
|
# Brace expansion
|
||||||
|
|
||||||
{string1,string2,...,stringN}
|
{string1,string2,...,stringN}
|
||||||
{<START>..<END>}
|
{<START>..<END>}
|
||||||
|
@ -1,6 +1,22 @@
|
|||||||
# Command substitution
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- expansion
|
||||||
|
- substitution
|
||||||
|
- text
|
||||||
|
- variable
|
||||||
|
- output
|
||||||
|
- execute
|
||||||
|
- stdout
|
||||||
|
- save
|
||||||
|
- result
|
||||||
|
- return
|
||||||
|
- value
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting expansion substitution text variable output execute stdout save result return value)
|
# Command substitution
|
||||||
|
|
||||||
$( <COMMANDS> )
|
$( <COMMANDS> )
|
||||||
|
|
||||||
|
@ -1,6 +1,18 @@
|
|||||||
# Expansions and substitutions
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- expansion
|
||||||
|
- substitution
|
||||||
|
- text
|
||||||
|
- variable
|
||||||
|
- filename
|
||||||
|
- macro
|
||||||
|
- wildcard
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting expansion substitution text variable filename macro wildcard)
|
# Expansions and substitutions
|
||||||
|
|
||||||
Before executing your commands, Bash checks whether there are any syntax
|
Before executing your commands, Bash checks whether there are any syntax
|
||||||
elements in the command line that should be interpreted rather than
|
elements in the command line that should be interpreted rather than
|
||||||
|
@ -1,6 +1,18 @@
|
|||||||
# Process substitution
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- expansion
|
||||||
|
- substitution
|
||||||
|
- text
|
||||||
|
- stdin
|
||||||
|
- stdout
|
||||||
|
- save
|
||||||
|
- capture
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting expansion substitution text stdin stdout save capture)
|
# Process substitution
|
||||||
|
|
||||||
Process substitution is a form of redirection where the input or output
|
Process substitution is a form of redirection where the input or output
|
||||||
of a process (some sequence of commands) appear as a temporary file.
|
of a process (some sequence of commands) appear as a temporary file.
|
||||||
|
@ -1,6 +1,17 @@
|
|||||||
# Tilde expansion
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- expansion
|
||||||
|
- substitution
|
||||||
|
- tilde
|
||||||
|
- home
|
||||||
|
- homedir
|
||||||
|
- shortcut
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting expansion substitution tilde home homedir shortcut)
|
# Tilde expansion
|
||||||
|
|
||||||
~
|
~
|
||||||
~/...
|
~/...
|
||||||
|
@ -1,9 +1,19 @@
|
|||||||
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- syntax
|
||||||
|
- language
|
||||||
|
- behaviour
|
||||||
|
- executing
|
||||||
|
- execution
|
||||||
|
---
|
||||||
|
|
||||||
FIXME work in progress\...
|
FIXME work in progress\...
|
||||||
|
|
||||||
# Parsing and execution
|
# Parsing and execution
|
||||||
|
|
||||||
![](keywords>bash shell scripting syntax language behaviour executing execution)
|
|
||||||
|
|
||||||
Nearly everything in [Bash grammar](../../syntax/basicgrammar.md) can be broken
|
Nearly everything in [Bash grammar](../../syntax/basicgrammar.md) can be broken
|
||||||
down to a \"simple command\". The only thing Bash has to expand,
|
down to a \"simple command\". The only thing Bash has to expand,
|
||||||
evaluate and execute is the simple command.
|
evaluate and execute is the simple command.
|
||||||
|
@ -1,6 +1,17 @@
|
|||||||
# Patterns and pattern matching
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- glob
|
||||||
|
- globbing
|
||||||
|
- wildcards
|
||||||
|
- filename
|
||||||
|
- pattern
|
||||||
|
- matching
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting glob globbing wildcards filename pattern matching)
|
# Patterns and pattern matching
|
||||||
|
|
||||||
A pattern is a **string description**. Bash uses them in various ways:
|
A pattern is a **string description**. Bash uses them in various ways:
|
||||||
|
|
||||||
|
@ -1,6 +1,24 @@
|
|||||||
# Parameter expansion
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- expansion
|
||||||
|
- substitution
|
||||||
|
- text
|
||||||
|
- variable
|
||||||
|
- parameter
|
||||||
|
- mangle
|
||||||
|
- substitute
|
||||||
|
- change
|
||||||
|
- check
|
||||||
|
- defined
|
||||||
|
- "null"
|
||||||
|
- array
|
||||||
|
- arrays
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting expansion substitution text variable parameter mangle substitute change check defined null array arrays)
|
# Parameter expansion
|
||||||
|
|
||||||
## Introduction
|
## Introduction
|
||||||
|
|
||||||
|
@ -1,6 +1,20 @@
|
|||||||
# Quotes and escaping
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- quoting
|
||||||
|
- quotes
|
||||||
|
- escape
|
||||||
|
- backslash
|
||||||
|
- marks
|
||||||
|
- singlequotes
|
||||||
|
- doublequotes
|
||||||
|
- single
|
||||||
|
- double
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting quoting quotes escape backslash marks singlequotes doublequotes single double)
|
# Quotes and escaping
|
||||||
|
|
||||||
Quoting and escaping are important, as they influence the way Bash acts
|
Quoting and escaping are important, as they influence the way Bash acts
|
||||||
upon your input. There are three recognized types:
|
upon your input. There are three recognized types:
|
||||||
|
@ -1,6 +1,16 @@
|
|||||||
# Words\...
|
---
|
||||||
|
tags:
|
||||||
|
- bash
|
||||||
|
- shell
|
||||||
|
- scripting
|
||||||
|
- token
|
||||||
|
- words
|
||||||
|
- split
|
||||||
|
- splitting
|
||||||
|
- recognition
|
||||||
|
---
|
||||||
|
|
||||||
![](keywords>bash shell scripting token words split splitting recognition)
|
# Words\...
|
||||||
|
|
||||||
FIXME This article needs a review, it covers two topics (command line
|
FIXME This article needs a review, it covers two topics (command line
|
||||||
splitting and word splitting) and mixes both a bit too much. But in
|
splitting and word splitting) and mixes both a bit too much. But in
|
||||||
|
Loading…
Reference in New Issue
Block a user