17 lines
		
	
	
	
		
			595 B
		
	
	
	
		
			Bash
		
	
	
	
	
	
			
		
		
	
	
			17 lines
		
	
	
	
		
			595 B
		
	
	
	
		
			Bash
		
	
	
	
	
	
| #!/bin/sh -e
 | |
| 
 | |
| if [ "$1" = upgrade ]; then
 | |
| 	# remove the obsolete udev file(s)
 | |
| 	[ -f /etc/udev/rules.d/025_nut-usbups.rules ] && rm -f /etc/udev/rules.d/025_nut-usbups.rules
 | |
| 	[ -f /etc/udev/rules.d/52_nut-usbups.rules ] && rm -f /etc/udev/rules.d/52_nut-usbups.rules
 | |
| 	[ -f /etc/udev/rules.d/52-nut-usbups.rules ] && rm -f /etc/udev/rules.d/52-nut-usbups.rules
 | |
| 
 | |
| 	# migrate /etc/default/nut to /etc/nut/nut.conf (part #1)
 | |
| 	# we need to do this before default gets trashed
 | |
| 	if [ -f /etc/default/nut ] ; then
 | |
| 		# backup /etc/default/nut
 | |
| 		cp /etc/default/nut /etc/default/nut.bak
 | |
| 	fi
 | |
| fi
 | |
| 
 | |
| #DEBHELPER#
 |