Blame po/insert-header.sin

Packit d37888
# Sed script that inserts the file called HEADER before the header entry.
Packit d37888
#
Packit d37888
# At each occurrence of a line starting with "msgid ", we execute the following
Packit d37888
# commands. At the first occurrence, insert the file. At the following
Packit d37888
# occurrences, do nothing. The distinction between the first and the following
Packit d37888
# occurrences is achieved by looking at the hold space.
Packit d37888
/^msgid /{
Packit d37888
x
Packit d37888
# Test if the hold space is empty.
Packit d37888
s/m/m/
Packit d37888
ta
Packit d37888
# Yes it was empty. First occurrence. Read the file.
Packit d37888
r HEADER
Packit d37888
# Output the file's contents by reading the next line. But don't lose the
Packit d37888
# current line while doing this.
Packit d37888
g
Packit d37888
N
Packit d37888
bb
Packit d37888
:a
Packit d37888
# The hold space was nonempty. Following occurrences. Do nothing.
Packit d37888
x
Packit d37888
:b
Packit d37888
}