]> git.ipfire.org Git - thirdparty/systemd.git/blame - src/shared/logs-show.h
core: hook up MountFlags= to the transient unit logic
[thirdparty/systemd.git] / src / shared / logs-show.h
CommitLineData
c2f1db8f 1#pragma once
86aa7ba4
LP
2
3/***
4 This file is part of systemd.
5
6 Copyright 2012 Lennart Poettering
7
8 systemd is free software; you can redistribute it and/or modify it
5430f7f2
LP
9 under the terms of the GNU Lesser General Public License as published by
10 the Free Software Foundation; either version 2.1 of the License, or
86aa7ba4
LP
11 (at your option) any later version.
12
13 systemd is distributed in the hope that it will be useful, but
14 WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5430f7f2 16 Lesser General Public License for more details.
86aa7ba4 17
5430f7f2 18 You should have received a copy of the GNU Lesser General Public License
86aa7ba4
LP
19 along with systemd; If not, see <http://www.gnu.org/licenses/>.
20***/
21
22#include <stdbool.h>
a8fbdf54
TA
23#include <stddef.h>
24#include <stdio.h>
1a6c43e9 25#include <sys/types.h>
86aa7ba4 26
3c756001 27#include "sd-journal.h"
81527be1 28
a8fbdf54 29#include "macro.h"
9bdbc2e2 30#include "output-mode.h"
a8fbdf54 31#include "time-util.h"
71d35b6b 32#include "util.h"
25277cd7 33
08ace05b
LP
34int output_journal(
35 FILE *f,
36 sd_journal *j,
37 OutputMode mode,
38 unsigned n_columns,
94e0bd7d
ZJS
39 OutputFlags flags,
40 bool *ellipsized);
86aa7ba4 41
b6741478 42int add_match_this_boot(sd_journal *j, const char *machine);
5ec76417 43
886a64fe
ZJS
44int add_matches_for_unit(
45 sd_journal *j,
46 const char *unit);
47
48int add_matches_for_user_unit(
49 sd_journal *j,
df50185b 50 const char *unit,
886a64fe 51 uid_t uid);
df50185b 52
886a64fe 53int show_journal_by_unit(
1a6c43e9
MT
54 FILE *f,
55 const char *unit,
56 OutputMode mode,
57 unsigned n_columns,
58 usec_t not_before,
59 unsigned how_many,
60 uid_t uid,
886a64fe 61 OutputFlags flags,
3c756001
LP
62 int journal_open_flags,
63 bool system_unit,
94e0bd7d 64 bool *ellipsized);
1a6c43e9 65
240a5fe8
LP
66void json_escape(
67 FILE *f,
68 const char* p,
69 size_t l,
70 OutputFlags flags);