Comment 8 for bug 1873545

Revision history for this message
Balint Reczey (rbalint) wrote :

Maintainer scripts must not change files installed/owned by other package.

The fix should be done in u-r-u.

--- update-motd-3.6.orig/debian/show-motd.postinst
+++ update-motd-3.6/debian/show-motd.postinst
@@ -0,0 +1,43 @@
+
+#!/bin/sh
...
+case "$1" in
+
+ configure)
+ # if it's WSL and we have 91-release-upgrade, disable it
+ if [ -e "/proc/sys/fs/binfmt_misc/WSLInterop" ] && [ -e "/etc/update-motd.d/91-release-upgrade" ]; then
+ [ -x "/etc/update-motd.d/91-release-upgrade" ] && chmod -x "/etc/update-motd.d/91-release-upgrade"
+ fi