File: 10restore-metadata

package info (click to toggle)
etckeeper 0.48
  • links: PTS
  • area: main
  • in suites: squeeze
  • size: 380 kB
  • ctags: 32
  • sloc: sh: 916; makefile: 44; python: 41
file content (14 lines) | stat: -rwxr-xr-x 487 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/bin/sh
set -e

# Note that metastore doesn't check that the .metastore file only changes
# perms of files in the current directory. It's ok to trust the .metastore
# file won't do anything shady, because, as documented, etckeeper-init
# should only be run on repositories you trust.
if [ -e .metadata ]; then
	if which metastore >/dev/null; then
		metastore --apply --mtime
	else
		echo "etckeeper warning: legacy .metastore file is present but metastore is not installed" >&2
	fi
fi