Changeset 274 in MondoRescue for trunk/mondo/mondo/common/libmondo-tools.c
- Timestamp:
- Jan 3, 2006, 4:15:54 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/mondo/mondo/common/libmondo-tools.c
r197 r274 172 172 "for i in `find /root /home -type d -name Desktop -maxdepth 2`; do \ 173 173 file=$i/.directory; if [ -f \"$file\" ] ; then mv -f $file $file.old ; \ 174 cat $file.old |awk '{if (index($0, \"rootimagesmindi\")) { while (length($0)>2) { getline;} ; } \175 else { print $0;};}' > $file ; fi ; done");174 awk '{if (index($0, \"rootimagesmindi\")) { while (length($0)>2) { getline;} ; } \ 175 else { print $0;};}'$file.old > $file ; fi ; done"); 176 176 run_program_and_log_output(tmp, 5); 177 177 paranoid_free(tmp); … … 870 870 #ifndef __FreeBSD__ 871 871 if (run_program_and_log_output 872 (" cat /proc/devices | grep ramdisk", FALSE)) {872 ("grep ramdisk /proc/devices", FALSE)) { 873 873 if (!ask_me_yes_or_no 874 874 ("Your kernel has no ramdisk support. That's mind-numbingly stupid but I'll allow it if you're planning to use a failsafe kernel. Are you?")) … … 1096 1096 log_msg(4, "Done. Great. Seeting command to something"); 1097 1097 asprintf(&command, 1098 " cat /etc/fstab | grep -v \":\"| grep -vx \"#.*\" | grep -w \"/boot\" | tr -s ' ' '\t' | cut -f1 | head -n1");1098 "grep -v \":\" /etc/fstab | grep -vx \"#.*\" | grep -w \"/boot\" | tr -s ' ' '\t' | cut -f1 | head -n1"); 1099 1099 log_msg(4, "Cool. Command = '%s'", command); 1100 1100 asprintf(&tmp, call_program_and_get_last_line_of_output(command));
Note:
See TracChangeset
for help on using the changeset viewer.