Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Move etckeeper out of sbin, to avoid needing to work around broken ro…

…ot PATH settings in eg, crontab. Closes: #602438
  • Loading branch information...
commit d65203b1bf9c1889a47090113a98833f849ae94e 1 parent 619e220
Joey Hess joeyh authored
4 Makefile
View
@@ -5,7 +5,7 @@ include $(CONFFILE)
DESTDIR?=
prefix=/usr
-sbindir=${prefix}/sbin
+bindir=${prefix}/bin
etcdir=/etc
mandir=${prefix}/share/man
vardir=/var
@@ -21,7 +21,7 @@ install:
mkdir -p $(DESTDIR)$(etcdir)/etckeeper/ $(DESTDIR)$(vardir)/cache/etckeeper/
cp -dR *.d $(DESTDIR)$(etcdir)/etckeeper/
$(INSTALL_DATA) $(CONFFILE) $(DESTDIR)$(etcdir)/etckeeper/etckeeper.conf
- $(INSTALL_EXE) etckeeper $(DESTDIR)$(sbindir)/etckeeper
+ $(INSTALL_EXE) etckeeper $(DESTDIR)$(bindir)/etckeeper
$(INSTALL_DATA) etckeeper.8 $(DESTDIR)$(mandir)/man8/etckeeper.8
$(INSTALL_DATA) bash_completion $(DESTDIR)$(etcdir)/bash_completion.d/etckeeper
ifeq ($(HIGHLEVEL_PACKAGE_MANAGER),apt)
8 apt.conf
View
@@ -1,5 +1,5 @@
-DPkg::Pre-Invoke { "if [ -x /usr/sbin/etckeeper ]; then etckeeper pre-install; fi"; };
-DPkg::Post-Invoke { "if [ -x /usr/sbin/etckeeper ]; then etckeeper post-install; fi"; };
+DPkg::Pre-Invoke { "if [ -x /usr/bin/etckeeper ]; then etckeeper pre-install; fi"; };
+DPkg::Post-Invoke { "if [ -x /usr/bin/etckeeper ]; then etckeeper post-install; fi"; };
-RPM::Pre-Invoke { "if [ -x /usr/sbin/etckeeper ]; then etckeeper pre-install; fi"; };
-RPM::Post-Invoke { "if [ -x /usr/sbin/etckeeper ]; then etckeeper post-install; fi"; };
+RPM::Pre-Invoke { "if [ -x /usr/bin/etckeeper ]; then etckeeper pre-install; fi"; };
+RPM::Post-Invoke { "if [ -x /usr/bin/etckeeper ]; then etckeeper post-install; fi"; };
2  debian/changelog
View
@@ -2,6 +2,8 @@ etckeeper (0.51) UNRELEASED; urgency=low
* Updated Vietnamese translation of debconf templates. Closes: #601921
* Improve rpm version change detection.
+ * Move etckeeper out of sbin, to avoid needing to work around broken
+ root PATH settings in eg, crontab. Closes: #602438
-- Joey Hess <joeyh@debian.org> Sat, 30 Oct 2010 23:53:51 -0400
2  debian/cron.daily
View
@@ -1,6 +1,6 @@
#!/bin/sh
set -e
-if [ -x /usr/sbin/etckeeper ] && [ -e /etc/etckeeper/etckeeper.conf ]; then
+if [ -x /usr/bin/etckeeper ] && [ -e /etc/etckeeper/etckeeper.conf ]; then
. /etc/etckeeper/etckeeper.conf
if [ "$AVOID_DAILY_AUTOCOMMITS" != "1" ]; then
# avoid autocommit if an install run is in progress
4 debian/prerm
View
@@ -13,7 +13,7 @@ if [ "$1" = remove ]; then
if [ -d /etc/etckeeper/uninit.d ]; then
cp -a /etc/etckeeper/uninit.d /var/cache/etckeeper/stash
fi
- if [ -x /usr/sbin/etckeeper ]; then
- cp -a /usr/sbin/etckeeper /var/cache/etckeeper/stash
+ if [ -x /usr/bin/etckeeper ]; then
+ cp -a /usr/bin/etckeeper /var/cache/etckeeper/stash
fi
fi
4 etckeeper.spec
View
@@ -43,13 +43,13 @@ install -D debian/cron.daily $RPM_BUILD_ROOT/etc/cron.daily/etckeeper
rm -rf $RPM_BUILD_ROOT
%post
-%{_sbindir}/etckeeper init -d /etc/
+%{_bindir}/etckeeper init -d /etc/
mkdir -p %{_var}/cache/etckeeper
%files
%defattr(-,root,root,-)
%doc GPL INSTALL TODO README
-%{_sbindir}/*
+%{_bindir}/*
%{_mandir}/*
# this isn't very clever and its a manual process update.
# but it works
4 pacman-g2.hook
View
@@ -1,13 +1,13 @@
#!/bin/sh
pre_sysupgrade() {
- if [ -x /usr/sbin/etckeeper ]; then
+ if [ -x /usr/bin/etckeeper ]; then
etckeeper pre-install
fi
}
post_sysupgrade() {
- if [ -x /usr/sbin/etckeeper ]; then
+ if [ -x /usr/bin/etckeeper ]; then
etckeeper post-install
fi
}
4 yum-etckeeper.py
View
@@ -25,12 +25,12 @@
def pretrans_hook(conduit):
conduit.info(2, 'etckeeper: pre transaction commit')
- servicecmd = conduit.confString('main', 'servicecmd', '/usr/sbin/etckeeper')
+ servicecmd = conduit.confString('main', 'servicecmd', '/usr/bin/etckeeper')
command = '%s %s' % (servicecmd, " pre-install")
os.system(command)
def posttrans_hook(conduit):
conduit.info(2, 'etckeeper: post transaction commit')
- servicecmd = conduit.confString('main', 'servicecmd', '/usr/sbin/etckeeper')
+ servicecmd = conduit.confString('main', 'servicecmd', '/usr/bin/etckeeper')
command = '%s %s' % (servicecmd, "post-install")
os.system(command)
Please sign in to comment.
Something went wrong with that request. Please try again.