blob: 66bdb09f393dd69f2e198d2a04fdc2eb2bfbb192 [file] [log] [blame]
Andrew Geissler7e0e3c02022-02-25 20:34:39 +00001#!/bin/sh
2
3# SPDX-FileCopyrightText: Andrei Gherzan <andrei.gherzan@huawei.com>
4#
5# SPDX-License-Identifier: MIT
6
7_log() {
8 _level="$1"
9 _msg="$2"
10 echo "[$_level] $_msg"
11}
12
13error() {
14 _msg="$1"
15 _log "ERR" "$1"
16 exit 1
17}
18
19warn() {
20 _msg="$1"
21 _log "WRN" "$1"
22 exit 1
23}
24
25log() {
26 _msg="$1"
27 _log "LOG" "$1"
28}