File: shell.md

package info (click to toggle)
glib2.0 2.84.4-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 66,112 kB
  • sloc: ansic: 538,924; python: 9,661; sh: 1,612; xml: 1,482; perl: 1,222; cpp: 535; makefile: 321; javascript: 11
file content (15 lines) | stat: -rw-r--r-- 541 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
Title: Shell Utilities
SPDX-License-Identifier: LGPL-2.1-or-later
SPDX-FileCopyrightText: 2014 Matthias Clasen

# Shell Utilities

GLib provides the functions [func@GLib.shell_quote] and
[func@GLib.shell_unquote] to handle shell-like quoting in strings. The function
[func@GLib.shell_parse_argv] parses a string similar to the way a POSIX shell
(`/bin/sh`) would.

Note that string handling in shells has many obscure and historical
corner-cases which these functions do not necessarily reproduce. They
are good enough in practice, though.