[svnbook commit] r3197 - trunk/src/nb

sunny256 noreply at red-bean.com
Mon Jul 14 22:55:43 CDT 2008


Author: sunny256
Date: Mon Jul 14 22:55:43 2008
New Revision: 3197

Log:
Some Linux variants (Ubuntu, at least) symlinks /bin/dash instead of 
/bin/bash to /bin/sh, which breaks the Makefile. The shell command 
"read" needs a variable name in such cases.

* src/nb/Makefile
  (bookdiff, sync): Replace "echo -n" commands with "read -p" and add a 
    dummy variable.


Modified:
   trunk/src/nb/Makefile

Modified: trunk/src/nb/Makefile
==============================================================================
--- trunk/src/nb/Makefile	(original)
+++ trunk/src/nb/Makefile	Mon Jul 14 22:55:43 2008
@@ -59,8 +59,7 @@
 
 bookdiff:
 	@mkdir $(BDTMP) || { \
-		echo -n "\"$(BDTMP)\" already exists. Press ENTER to delete it, or CTRL-C to abort..." >&2; \
-		read; \
+		read -p "\"$(BDTMP)\" already exists. Press ENTER to delete it, or CTRL-C to abort..." dummyvariable; \
 		rm -rf $(BDTMP); \
 		mkdir $(BDTMP); \
 	}
@@ -79,8 +78,7 @@
 	@echo
 	@echo The temporary files are still in $(BDTMP)/ for you to play with.
 	@echo
-	@echo -n Press Enter to launch vimdiff or CTRL-C to exit...
-	@read
+	@read -p "Press Enter to launch vimdiff or CTRL-C to exit..." dummyvariable
 	vimdiff $(BDTMP)/norw.txt $(BDTMP)/eng.txt
 
 engdir:
@@ -96,8 +94,7 @@
 	@echo ======= START svn status =======
 	@svn status -q
 	@echo ======== END svn status ========
-	@echo -n Press Enter to continue or CTRL-C to abort...
-	@read
+	@read -p "Press Enter to continue or CTRL-C to abort..." dummyvariable
 	@if [ "$(HEAD)" = "" ]; then \
 		svnversion . | tr -d M >HEADREV; \
 	else \




More information about the svnbook-dev mailing list