7.4.2-ol-7-r7 release

This commit is contained in:
Bitnami Bot
2019-11-07 04:43:47 +00:00
parent 861d103406
commit 47c5576ca9
15 changed files with 903 additions and 4 deletions

View File

@@ -0,0 +1,22 @@
#!/bin/bash
#
# Library for managing files
# Functions
########################
# Ensure a line exists in the file by replacing a matching line.
# Arguments:
# $1 - filename
# $2 - line
# $3 - match
# Returns:
# None
#########################
file_contains_line() {
local filename="${1:?filename is required}"
local line="${2:?line is required}"
local match="${3:?match is required}"
sed --in-place "s/^$match\$/$line/" "$filename"
}