1CDIST-TYPE__BLOCK(7)                 cdist                CDIST-TYPE__BLOCK(7)
2
3
4

NAME

6       cdist-type__block - Manage blocks of text in files
7

DESCRIPTION

9       Manage  a  block  of text in an existing file.  The block is identified
10       using the prefix and suffix parameters.  Everything between prefix  and
11       suffix is considered to be a managed block of text.
12

REQUIRED PARAMETERS

14       text   the  text to manage.  If text is '-' (dash), take what was writ‐
15              ten to stdin as the text.
16

OPTIONAL PARAMETERS

18       file   the file in which to manage the text  block.   Defaults  to  ob‐
19              ject_id.
20
21       prefix the    prefix   to   add   before   the   text.    Defaults   to
22              #cdist:__block/$__object_id
23
24       suffix the   suffix   to   add   after   the   text.     Defaults    to
25              #/cdist:__block/$__object_id
26
27       state  'present' or 'absent', defaults to 'present'
28

MESSAGES

30       add    block was added
31
32       update block was updated/changed
33
34       remove block was removed
35

EXAMPLES

37          # text from argument
38          __block /path/to/file \
39             --prefix '#start' \
40             --suffix '#end' \
41             --text 'some\nblock of\ntext'
42
43          # text from stdin
44          __block some-id \
45             --file /path/to/file \
46             --text - << DONE
47          here some block
48          of text
49          DONE
50

AUTHORS

52       Steven Armstrong <steven-cdist--@--armstrong.cc>
53

COPYING

55       Copyright  (C)  2013  Steven  Armstrong. You can redistribute it and/or
56       modify it under the terms of the GNU General  Public  License  as  pub‐
57       lished  by  the  Free  Software Foundation, either version 3 of the Li‐
58       cense, or (at your option) any later version.
59
61       ungleich GmbH 2020
62
63
64
65
666.9.6                            Apr 20, 2021             CDIST-TYPE__BLOCK(7)
Impressum