source: trunk/locker/sbin/rpmlist.sh @ 2843

Last change on this file since 2843 was 2823, checked in by andersk, 7 years ago
rpm-master.sh, rpmlist.sh: Improve shell hygiene
  • Property svn:executable set to *
File size: 287 bytes
RevLine 
[1640]1#!/bin/sh
[2823]2set -eu
[1639]3
[2274]4export LC_ALL=C
5
[1639]6copyTo='/mit/scripts/cron_scripts/rpm-sync/'
[2823]7packages=$(mktemp --tmpdir rpmlist.XXXXXX)
8rpm -qa --queryformat '%{NAME}.%{ARCH}\n' | sort | uniq > "$packages"
[1639]9
[2823]10host=$(hostname)
[1639]11extension='.rpmlist'
12file="$copyTo/$host$extension"
[2823]13mv "$packages" "$file"
Note: See TracBrowser for help on using the repository browser.