commit b0d378370d06cf065bddeac5333643371f450e25
Author: Sérgio M. Basto <sergio(a)serjux.com>
Date: Mon Dec 24 00:52:08 2018 +0000
Update to 0.10.8
.gitignore | 1 +
mythtv-status-update-motd.patch | 33 +++++++++++++++++++++++----------
mythtv-status.spec | 7 +++++--
sources | 2 +-
4 files changed, 30 insertions(+), 13 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 63634c9..3493bd3 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,2 @@
mythtv-status-0.10.4.tar.gz
+/mythtv-status-0.10.8.tar.gz
diff --git a/mythtv-status-update-motd.patch b/mythtv-status-update-motd.patch
index 13e2a21..003c615 100644
--- a/mythtv-status-update-motd.patch
+++ b/mythtv-status-update-motd.patch
@@ -1,7 +1,13 @@
---- mythtv-status-0.10.4/bin/mythtv-update-motd.orig 2013-10-28 10:39:56.000000000 +0100
-+++ mythtv-status-0.10.4/bin/mythtv-update-motd 2016-03-07 22:10:12.000000000 +0100
-@@ -1,17 +1,28 @@
- #!/bin/bash
+--- mythtv-status-0.10.8/bin/mythtv-update-motd.orig 2018-12-23 15:52:58.351068982 +0000
++++ mythtv-status-0.10.8/bin/mythtv-update-motd 2018-12-24 00:29:02.533842709 +0000
+@@ -3,12 +3,12 @@
+ # Run mythtv-status to update the MOTD.
+
+ NAME=mythtv-update-motd
+-WORKFILE=/var/run/motd
+-TEMPFILE=/var/run/motd.mythtv-status
++WORKFILE=/etc/motd
++TEMPFILE=/etc/motd.mythtv-status
-. /etc/default/mythtv-status
+. /etc/sysconfig/mythtv-status
@@ -11,8 +17,11 @@
then
exit
fi
+@@ -18,7 +18,16 @@ fi
--[ ! -f /var/run/motd.orig ] && cp /var/run/motd /var/run/motd.orig
+ # Just incase someone has removed their motd file.
+ [ -f $WORKFILE ] || touch $WORKFILE
+-[ -f /var/run/motd.orig ] || cp $WORKFILE /var/run/motd.orig
+# Check if stub exists. If not, assume motd is OK to use as stub
+if [ ! -f /etc/motd.stub ]; then
+ if [ -f /etc/motd ]; then
@@ -24,14 +33,18 @@
+
+# Update motd:
+ # If the tempfile is less than 15 minutes old, object, otherwise
+ # we'll assume that something went wrong and remove it.
+@@ -31,9 +40,9 @@ if [ -f $TEMPFILE ]; then
+ fi
+ fi
+
+-[ ! -f /var/run/motd.orig ] && cp /var/run/motd /var/run/motd.orig
+-
-cp /var/run/motd.orig /var/run/motd.new
+# Insert stub
+cp /etc/motd.stub /tmp/motd.new
+# Add mythtv status to end of stub
ret=0
--mythtv-status $ARGS -h $HOST >> /var/run/motd.new 2> /dev/null || ret=$?
-+mythtv-status $ARGS -h $HOST >> /tmp/motd.new || ret=$?
+ mythtv-status $ARGS -h $HOST >> $TEMPFILE 2> /dev/null || ret=$?
if [ $ret -eq 0 -o $ret -eq 1 ]; then
-- [ -f /var/run/motd.new ] && mv /var/run/motd.new /var/run/motd
-+ [ -f /tmp/motd.new ] && mv /tmp/motd.new /etc/motd
- fi
diff --git a/mythtv-status.spec b/mythtv-status.spec
index 84a5dcb..a5e6128 100644
--- a/mythtv-status.spec
+++ b/mythtv-status.spec
@@ -1,6 +1,6 @@
Name: mythtv-status
-Version: 0.10.4
-Release: 9%{?dist}
+Version: 0.10.8
+Release: 1%{?dist}
Summary: Get the current status of your MythTV system at the command line
Summary(sv): Hämta ett MythTV-systems status på kommandoraden
License: GPLv3
@@ -78,6 +78,9 @@ chmod 755
%{buildroot}%{_sysconfdir}/cron.hourly/mythtv-update-motd.cron
%config(noreplace) %{_sysconfdir}/sysconfig/%{name}
%changelog
+* Sun Dec 23 2018 Sérgio Basto <sergio(a)serjux.com> - 0.10.8-1
+- Update to 0.10.8
+
* Fri Jul 27 2018 RPM Fusion Release Engineering <leigh123linux(a)gmail.com> -
0.10.4-9
- Rebuilt for
https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
diff --git a/sources b/sources
index 1a14b2c..0fc438e 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-e53666a10a050e47dd371d0083d81b99 mythtv-status-0.10.4.tar.gz
+3ae4b0c58f041e55a3155a28773214ae mythtv-status-0.10.8.tar.gz