File: check_installation_duplicates.bash

package info (click to toggle)
gnuradio 3.10.12.0-6
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 42,128 kB
  • sloc: cpp: 191,537; python: 92,041; ansic: 2,292; xml: 999; fortran: 927; sh: 507; makefile: 50
file content (15 lines) | stat: -rwxr-xr-x 487 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#!/bin/bash
# Checks whether any files got installed twice
# Argument: path of install_manifest.txt from a cmake build
infile="$1" 
sort "${infile}" > /tmp/sorted \
  && sort -u "${infile}" > /tmp/sorted_unique \
  && differences="$(comm -3 /tmp/sorted /tmp/sorted_unique)" \
  || exit 12

if [[ -n "${differences}" ]]; then
  printf '%s\n' "${differences}" | while read -r line ; do
    printf '::error file=%s"::duplicately installed file "%s"\n' "${line}" "${line}"
  done
exit 42
fi