summaryrefslogtreecommitdiffstats
path: root/web/input/doc
diff options
context:
space:
mode:
authorHolger Weiss <holger@zedat.fu-berlin.de>2014-01-12 22:28:55 (GMT)
committerHolger Weiss <holger@zedat.fu-berlin.de>2014-01-12 22:28:55 (GMT)
commitaa96b7897b40bf1171f08d77e229ec57b2c4119a (patch)
treed6be2cd9ab395ad031968c46d341881f8f3005e1 /web/input/doc
parentc394fa1575c28380e56d4f1e9883d88dfa7266cf (diff)
downloadsite-aa96b7897b40bf1171f08d77e229ec57b2c4119a.tar.gz
Documentation: Denote command lines with "$"
Add a prompt sign to all command lines in code blocks.
Diffstat (limited to 'web/input/doc')
-rw-r--r--web/input/doc/extra-opts.md8
-rw-r--r--web/input/doc/faq/build-perl-module.md2
-rw-r--r--web/input/doc/faq/compilation.md8
-rw-r--r--web/input/doc/faq/git.md26
-rw-r--r--web/input/doc/faq/gnulib.md32
-rw-r--r--web/input/doc/faq/installation.md2
-rw-r--r--web/input/doc/faq/libtap.md8
-rw-r--r--web/input/doc/faq/nagiosmib.md2
-rw-r--r--web/input/doc/faq/ownership.md2
-rw-r--r--web/input/doc/faq/root-plugins.md2
10 files changed, 46 insertions, 46 deletions
diff --git a/web/input/doc/extra-opts.md b/web/input/doc/extra-opts.md
index 91a205b..06fc5b7 100644
--- a/web/input/doc/extra-opts.md
+++ b/web/input/doc/extra-opts.md
@@ -21,22 +21,22 @@ Some examples:
21 21
22* Read `special_opts` section of default config file: 22* Read `special_opts` section of default config file:
23 23
24 ./check_stuff --extra-opts=special_opts 24 $ ./check_stuff --extra-opts=special_opts
25 25
26* Read `special_opts` section of `/etc/myconfig.ini`: 26* Read `special_opts` section of `/etc/myconfig.ini`:
27 27
28 ./check_stuff --extra-opts=special_opts@/etc/myconfig.ini 28 $ ./check_stuff --extra-opts=special_opts@/etc/myconfig.ini
29 29
30* Read `check_stuff` section of `/etc/myconfig.ini`: 30* Read `check_stuff` section of `/etc/myconfig.ini`:
31 31
32 ./check_stuff --extra-opts=@/etc/myconfig.ini 32 $ ./check_stuff --extra-opts=@/etc/myconfig.ini
33 33
34* Read `check_stuff` section of default config file and use additional 34* Read `check_stuff` section of default config file and use additional
35 arguments along with the other specified arguments (*extra-opts* arguments 35 arguments along with the other specified arguments (*extra-opts* arguments
36 are always processed first no matter where `--extra-opts` appears on the 36 are always processed first no matter where `--extra-opts` appears on the
37 command line): 37 command line):
38 38
39 ./check_stuff --extra-opts -jk --some-other-opt 39 $ ./check_stuff --extra-opts -jk --some-other-opt
40 40
41The default nagios plugins file is used if no explicit filename is given. The 41The default nagios plugins file is used if no explicit filename is given. The
42current standard locations checked are: 42current standard locations checked are:
diff --git a/web/input/doc/faq/build-perl-module.md b/web/input/doc/faq/build-perl-module.md
index 0ec97ac..8c6f2ac 100644
--- a/web/input/doc/faq/build-perl-module.md
+++ b/web/input/doc/faq/build-perl-module.md
@@ -6,7 +6,7 @@ parent: FAQ
6 6
7This is currently an optional setting at configure time. You need to run: 7This is currently an optional setting at configure time. You need to run:
8 8
9 ./configure --enable-perl-modules 9 $ ./configure --enable-perl-modules
10 10
11Then, `make`, `make` `install`, `make` `test`, and `make` `clean` will include 11Then, `make`, `make` `install`, `make` `test`, and `make` `clean` will include
12the Perl modules that are in the `perlmods/` directory as expected. They are 12the Perl modules that are in the `perlmods/` directory as expected. They are
diff --git a/web/input/doc/faq/compilation.md b/web/input/doc/faq/compilation.md
index b58566a..ac5fff7 100644
--- a/web/input/doc/faq/compilation.md
+++ b/web/input/doc/faq/compilation.md
@@ -6,10 +6,10 @@ parent: FAQ
6 6
7To compile version `1.x` of the plugins, you run: 7To compile version `1.x` of the plugins, you run:
8 8
9 gzip -dc nagios-plugins-1.x.tar.gz | tar -xf - 9 $ gzip -dc nagios-plugins-1.x.tar.gz | tar -xf -
10 cd nagios-plugins-1.x 10 $ cd nagios-plugins-1.x
11 ./configure 11 $ ./configure
12 make 12 $ make
13 13
14You can then [install the plugins][installation]. 14You can then [install the plugins][installation].
15 15
diff --git a/web/input/doc/faq/git.md b/web/input/doc/faq/git.md
index 5503166..390b87a 100644
--- a/web/input/doc/faq/git.md
+++ b/web/input/doc/faq/git.md
@@ -43,12 +43,12 @@ repository, and until you want to distribute your change or merge changes from
43someone else, everything that follows can happen offline. If you have push 43someone else, everything that follows can happen offline. If you have push
44access to the Nagios Plugins repository, run the command: 44access to the Nagios Plugins repository, run the command:
45 45
46 git clone git@github.com:nagios-plugins/nagios-plugins.git 46 $ git clone git@github.com:nagios-plugins/nagios-plugins.git
47 47
48If you just want a local copy or wish to clone it to your workstation, you can 48If you just want a local copy or wish to clone it to your workstation, you can
49run this command instead: 49run this command instead:
50 50
51 git clone git://github.com/nagios-plugins/nagios-plugins.git 51 $ git clone git://github.com/nagios-plugins/nagios-plugins.git
52 52
53This will create a directory called `nagios-plugins` with all the `master` 53This will create a directory called `nagios-plugins` with all the `master`
54code and history (this is roughly equivalent to CVS/SVN `HEAD`). Change 54code and history (this is roughly equivalent to CVS/SVN `HEAD`). Change
@@ -58,7 +58,7 @@ directory to `nagios-plugins`.
58 58
59You can edit the files in the working area. To check the status, use: 59You can edit the files in the working area. To check the status, use:
60 60
61 git status 61 $ git status
62 62
63This will show a list of changes in the working directory. Newly made changes 63This will show a list of changes in the working directory. Newly made changes
64appear in red, while changes added to the index are shown in green. You can 64appear in red, while changes added to the index are shown in green. You can
@@ -74,7 +74,7 @@ will add the changes to the index. You can select only partial diffs with
74difference between HEAD and the index) with **git diff --staged**, and then 74difference between HEAD and the index) with **git diff --staged**, and then
75commit them with: 75commit them with:
76 76
77 git commit 77 $ git commit
78 78
79Add a comment (you *have* read the [Development Guidelines][guidelines], 79Add a comment (you *have* read the [Development Guidelines][guidelines],
80right? :-)). This commit will be local (affecting only your own repository), 80right? :-)). This commit will be local (affecting only your own repository),
@@ -83,7 +83,7 @@ you (in the latter case you will most likely still push to a publicly
83accessible clone of your local repository). If the change is from a 83accessible clone of your local repository). If the change is from a
84contributor, set the author at commit time: 84contributor, set the author at commit time:
85 85
86 git commit --author="Jane Doe <jane@example.com>" 86 $ git commit --author="Jane Doe <jane@example.com>"
87 87
88If you realize that you forgot something in your commit and haven’t pushed it 88If you realize that you forgot something in your commit and haven’t pushed it
89yet to a remote repository, you can amend your last commit with **git commit 89yet to a remote repository, you can amend your last commit with **git commit
@@ -97,18 +97,18 @@ You can revert local modifications with the following steps. First, if you
97have already staged the changes you will have to unstage them. As indicated 97have already staged the changes you will have to unstage them. As indicated
98in the **git status** message you can do so with the following command: 98in the **git status** message you can do so with the following command:
99 99
100 git reset HEAD <file> 100 $ git reset HEAD <file>
101 101
102Then you can revert unstaged changes with: 102Then you can revert unstaged changes with:
103 103
104 git checkout <file> 104 $ git checkout <file>
105 105
106If you have already committed changes locally and need to undo your commit(s), 106If you have already committed changes locally and need to undo your commit(s),
107you can use **git reset**. First find the commit names with **git log** and 107you can use **git reset**. First find the commit names with **git log** and
108then do either one of these: To keep local modifications (you can commit them 108then do either one of these: To keep local modifications (you can commit them
109again, stash them, etc.) 109again, stash them, etc.)
110 110
111 git reset --soft <commit> 111 $ git reset --soft <commit>
112 112
113Note that for the purpose of “re-doing” the last commit, **git commit 113Note that for the purpose of “re-doing” the last commit, **git commit
114--amend** will be much easier than a reset/commit with the same end result. 114--amend** will be much easier than a reset/commit with the same end result.
@@ -116,7 +116,7 @@ To discard local modifications (if you lose important changes with this
116command you may be able to recover them with **git reflog** and **git checkout 116command you may be able to recover them with **git reflog** and **git checkout
117<commit\>**): 117<commit\>**):
118 118
119 git reset --hard <file> 119 $ git reset --hard <file>
120 120
121Do not reset changes that have already been pushed to remote repositories as 121Do not reset changes that have already been pushed to remote repositories as
122this will cause non-linear updates. If you do so, all developers using those 122this will cause non-linear updates. If you do so, all developers using those
@@ -131,14 +131,14 @@ If you do, either commit them or put them aside (hint: **git stash**). If you
131cloned from the main Git repository, this command will do a fetch and then 131cloned from the main Git repository, this command will do a fetch and then
132merge any new changes: 132merge any new changes:
133 133
134 git pull 134 $ git pull
135 135
136You can also merge changes from any other fork of the repository. This 136You can also merge changes from any other fork of the repository. This
137usually happens if someone asks you to pull from his own repo for some fix or 137usually happens if someone asks you to pull from his own repo for some fix or
138enhancements. Together with **--no-commit**, you will have a chance to review 138enhancements. Together with **--no-commit**, you will have a chance to review
139the changes and make any relevant correction before the merge. Example: 139the changes and make any relevant correction before the merge. Example:
140 140
141 git pull --no-commit git://example.com/path/to/repo.git master 141 $ git pull --no-commit git://example.com/path/to/repo.git master
142 142
143## Merging Back to the Main Repository 143## Merging Back to the Main Repository
144 144
@@ -146,7 +146,7 @@ Once you’re done with your commits, and after pulling from the main
146repository, you can push your changes back to it. If you cloned using the 146repository, you can push your changes back to it. If you cloned using the
147*push* URL, this command will push the master branch: 147*push* URL, this command will push the master branch:
148 148
149 git push 149 $ git push
150 150
151It you’re trying to push something that would generate merge conflicts, the 151It you’re trying to push something that would generate merge conflicts, the
152push will be rejected. You will have to do a pull first, fix any conflicts 152push will be rejected. You will have to do a pull first, fix any conflicts
@@ -154,7 +154,7 @@ locally, and then push again. If your commits are local (you haven’t pulled
154them from someone else or published them somewhere) you can rebase to avoid a 154them from someone else or published them somewhere) you can rebase to avoid a
155merge: 155merge:
156 156
157 git pull --rebase 157 $ git pull --rebase
158 158
159Like a merge, this may generate conflicts and let you fix them, but instead of 159Like a merge, this may generate conflicts and let you fix them, but instead of
160creating a merge commit on top of the others, it will undo your commits, 160creating a merge commit on top of the others, it will undo your commits,
diff --git a/web/input/doc/faq/gnulib.md b/web/input/doc/faq/gnulib.md
index 328dfeb..5b7299b 100644
--- a/web/input/doc/faq/gnulib.md
+++ b/web/input/doc/faq/gnulib.md
@@ -8,27 +8,27 @@ parent: FAQ
8not available on all (Unix-like) operating systems. In order to sync with the 8not available on all (Unix-like) operating systems. In order to sync with the
9latest Gnulib code, do something like: 9latest Gnulib code, do something like:
10 10
11 git clone git://git.savannah.gnu.org/gnulib.git 11 $ git clone git://git.savannah.gnu.org/gnulib.git
12 cd gnulib 12 $ cd gnulib
13 GNULIB_HEAD=$(git rev-parse --short HEAD) 13 $ GNULIB_HEAD=$(git rev-parse --short HEAD)
14 cd .. 14 $ cd ..
15 git clone git@github.com:nagios-plugins/nagios-plugins.git 15 $ git clone git@github.com:nagios-plugins/nagios-plugins.git
16 cd nagios-plugins 16 $ cd nagios-plugins
17 ../gnulib/gnulib-tool --update 17 $ ../gnulib/gnulib-tool --update
18 find gl -name '*~' -o -name '.gitignore' | xargs rm 18 $ find gl -name '*~' -o -name '.gitignore' | xargs rm
19 git status 19 $ git status
20 git add gl 20 $ git add gl
21 git commit -m "Sync with latest Gnulib code ($GNULIB_HEAD)" 21 $ git commit -m "Sync with latest Gnulib code ($GNULIB_HEAD)"
22 22
23In order to make a given function available via Gnulib (on systems which don't 23In order to make a given function available via Gnulib (on systems which don't
24provide that function), the [corresponding module][modules] must be imported 24provide that function), the [corresponding module][modules] must be imported
25using `gnulib-tool`, e.g. (in order to add the `strcase` module): 25using `gnulib-tool`, e.g. (in order to add the `strcase` module):
26 26
27 ../gnulib/gnulib-tool --no-vc-files --import strcase 27 $ ../gnulib/gnulib-tool --no-vc-files --import strcase
28 find gl -name '*~' | xargs rm 28 $ find gl -name '*~' | xargs rm
29 git status 29 $ git status
30 git add gl 30 $ git add gl
31 git commit -m 'Add Gnulib module "strcase"' 31 $ git commit -m 'Add Gnulib module "strcase"'
32 32
33[gnulib]: http://www.gnu.org/software/gnulib/ "Gnulib" 33[gnulib]: http://www.gnu.org/software/gnulib/ "Gnulib"
34[modules]: http://www.gnu.org/software/gnulib/MODULES.html "Gnulib Modules" 34[modules]: http://www.gnu.org/software/gnulib/MODULES.html "Gnulib Modules"
diff --git a/web/input/doc/faq/installation.md b/web/input/doc/faq/installation.md
index f426f35..6f3694a 100644
--- a/web/input/doc/faq/installation.md
+++ b/web/input/doc/faq/installation.md
@@ -7,7 +7,7 @@ parent: FAQ
7After [compiling][compilation] the plugins, you can run the following command 7After [compiling][compilation] the plugins, you can run the following command
8to install them: 8to install them:
9 9
10 make install 10 $ make install
11 11
12[compilation]: doc/faq/compilation.html "Compilation" 12[compilation]: doc/faq/compilation.html "Compilation"
13 13
diff --git a/web/input/doc/faq/libtap.md b/web/input/doc/faq/libtap.md
index 29cd357..c592030 100644
--- a/web/input/doc/faq/libtap.md
+++ b/web/input/doc/faq/libtap.md
@@ -10,10 +10,10 @@ tests are in `lib/tests/test_*.c`.
10The latest libtap version is currently 1.01. However, there is a bug with the 10The latest libtap version is currently 1.01. However, there is a bug with the
11thread implementation. To workaround, run: 11thread implementation. To workaround, run:
12 12
13 CPPFLAGS="-UHAVE_LIBPTHREAD" ./configure 13 $ CPPFLAGS="-UHAVE_LIBPTHREAD" ./configure
14 make 14 $ make
15 make check 15 $ make check
16 make install 16 $ make install
17 17
18Now when you run the Nagios Plugins `./configure` script, it should find the 18Now when you run the Nagios Plugins `./configure` script, it should find the
19libtap library and compile the tests and run them when you run `make` `test`. 19libtap library and compile the tests and run them when you run `make` `test`.
diff --git a/web/input/doc/faq/nagiosmib.md b/web/input/doc/faq/nagiosmib.md
index b2f34ae..13fcb9d 100644
--- a/web/input/doc/faq/nagiosmib.md
+++ b/web/input/doc/faq/nagiosmib.md
@@ -14,7 +14,7 @@ To develop, the requirements are:
14 14
15On Debian, you'd run: 15On Debian, you'd run:
16 16
17 apt-get install smistrip smitools 17 $ apt-get install smistrip smitools
18 18
19If you get errors like: 19If you get errors like:
20 20
diff --git a/web/input/doc/faq/ownership.md b/web/input/doc/faq/ownership.md
index 58bc311..7fb8ca8 100644
--- a/web/input/doc/faq/ownership.md
+++ b/web/input/doc/faq/ownership.md
@@ -15,7 +15,7 @@ also installed with the install user's owner and group permissions.
15 15
16If you run: 16If you run:
17 17
18 make install-root 18 $ make install-root
19 19
20This will set permissions to root, assuming you are either root or using 20This will set permissions to root, assuming you are either root or using
21fakeroot. If not, the setuid bit is still set, but the plugin may not work 21fakeroot. If not, the setuid bit is still set, but the plugin may not work
diff --git a/web/input/doc/faq/root-plugins.md b/web/input/doc/faq/root-plugins.md
index b5db74d..43994de 100644
--- a/web/input/doc/faq/root-plugins.md
+++ b/web/input/doc/faq/root-plugins.md
@@ -15,7 +15,7 @@ message will appear:
15 15
16To install, run as root: 16To install, run as root:
17 17
18 make install-root 18 $ make install-root
19 19
20Even if you are not root, the plugins will still be installed. This is for 20Even if you are not root, the plugins will still be installed. This is for
21packagers which can then alter the permissions of the plugins before 21packagers which can then alter the permissions of the plugins before