On Sunday 11 August 2013 05:37 PM, Eddy Petrișor wrote:
> The fix in the repo still has the original problem, because if the
> /etc/laptop-mode/conf.d or /etc/laptop-mode/conf.d/board-specific
> directories exists, but contains no .conf files, the script will
> generate the ugly warning initially reported since the shell does not
> expand the wildcard.

I am not able to determine why the current fix will fail. Please see
below testcase.


rrs@zan:/etc/laptop-mode$ ls conf.d/
ac97-powersave.conf         configuration-file-control.conf 
exec-commands.conf         nmi-watchdog.conf            
start-stop-programs.conf  wireless-iwl-power.conf
auto-hibernate.conf         cpufreq.conf                    
hal-polling.conf           pcie-aspm.conf               
terminal-blanking.conf    wireless-power.conf
battery-level-polling.conf  dpms-standby.conf               
intel-hda-powersave.conf   runtime-pm.conf              
usb-autosuspend.conf
bluetooth.conf              eee-superhe.conf                
intel-sata-powermgmt.conf  sched-mc-power-savings.conf   video-out.conf
board-specific/             ethernet.conf                   
lcd-brightness.conf        sched-smt-power-savings.conf 
wireless-ipw-power.conf

rrs@zan:/etc/laptop-mode$ ls conf.d/board-specific/

rrs@zan:/etc/laptop-mode$ for x in conf.d/*.conf; do test -r $x &&  echo
$x; done
conf.d/ac97-powersave.conf
conf.d/auto-hibernate.conf
conf.d/battery-level-polling.conf
conf.d/bluetooth.conf
conf.d/configuration-file-control.conf
conf.d/cpufreq.conf
conf.d/dpms-standby.conf
conf.d/eee-superhe.conf
conf.d/ethernet.conf
conf.d/exec-commands.conf
conf.d/hal-polling.conf
conf.d/intel-hda-powersave.conf
conf.d/intel-sata-powermgmt.conf
conf.d/lcd-brightness.conf
conf.d/nmi-watchdog.conf
conf.d/pcie-aspm.conf
conf.d/runtime-pm.conf
conf.d/sched-mc-power-savings.conf
conf.d/sched-smt-power-savings.conf
conf.d/start-stop-programs.conf
conf.d/terminal-blanking.conf
conf.d/usb-autosuspend.conf
conf.d/video-out.conf
conf.d/wireless-ipw-power.conf
conf.d/wireless-iwl-power.conf
conf.d/wireless-power.conf

rrs@zan:/etc/laptop-mode$ for x in conf.d/board-specific/*.conf; do test
-r $x && echo $x; done
rrs@zan:/etc/laptop-mode$


-- 
Ritesh Raj Sarraf
RESEARCHUT - http://www.researchut.com
"Necessity is the mother of invention."


Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to