From 57782cede2f56374f6bca0576df47e45ed466202 Mon Sep 17 00:00:00 2001 From: "Mark D. Studebaker" Date: Tue, 15 Mar 2005 19:24:25 +0000 Subject: [PATCH] fix handling of alternate config file name git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2930 7894878c-1315-0410-8ee3-d5d059ff63e0 --- prog/pwm/pwmconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/prog/pwm/pwmconfig b/prog/pwm/pwmconfig index 717c38b7..48415f32 100755 --- a/prog/pwm/pwmconfig +++ b/prog/pwm/pwmconfig @@ -465,9 +465,9 @@ function TestMinStop { function SaveConfig { echo echo "Saving configuration to $FCCONFIG..." - egrep -v '(INTERVAL|FCTEMPS|FCFANS|MAXTEMP|MINTEMP|MINSTART|MINSTOP)' /etc/fancontrol >/tmp/fancontrol + egrep -v '(INTERVAL|FCTEMPS|FCFANS|MAXTEMP|MINTEMP|MINSTART|MINSTOP)' $FCCONFIG >/tmp/fancontrol echo -e "INTERVAL=$INTERVAL\nFCTEMPS=$FCTEMPS\nFCFANS=$FCFANS\nMINTEMP=$MINTEMP\nMAXTEMP=$MAXTEMP\nMINSTART=$MINSTART\nMINSTOP=$MINSTOP" >>/tmp/fancontrol - mv /tmp/fancontrol /etc/fancontrol + mv /tmp/fancontrol $FCCONFIG #check if file was written correctly echo 'Configuration saved' }