File: pkgos_insert_include

package info (click to toggle)
openstack-pkg-tools 123
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 912 kB
  • sloc: sh: 3,992; makefile: 31
file content (14 lines) | stat: -rwxr-xr-x 385 bytes parent folder | download | duplicates (9)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/bin/sh

set -e

# Example call: pkgos_insert_include pkgos_func keystone.config
INC=/usr/share/openstack-pkg-tools/${1}
DST=debian/${2}
SRC="debian/${2}.in"

awk '{if ($1 == "#PKGOS-INCLUDE#") {
print "### Start of included " G " library"
while ((getline line < F) > 0) print line
print "### End of included " G " library"
} else print}' F=${INC} G=$(basename $INC) ${SRC} > ${DST}