Skip to content
This repository
Browse code

Update Makefile to actually work on the server

  • Loading branch information...
commit 366d33ead07feb4a16fb802616baa6b762cf7bce 1 parent 547e409
Eddie Monge authored November 09, 2011

Showing 1 changed file with 8 additions and 10 deletions. Show diff stats Hide diff stats

  1. 18  Makefile
18  Makefile
@@ -111,15 +111,13 @@ docs: init css js
111 111
 	# ... Update the JavaScript and CSS paths
112 112
 	@@find tmp/${NAME} -type f \
113 113
 		\( -name '*.html' -o -name '*.php' \) \
114  
-		-exec sed -i '' 's|js/"|${NAME}.min.js"|g' {} \; \
115  
-		-exec sed -i '' 's|css/themes/default/|${NAME}.min.css|g' {} \; \
116  
-		-exec sed -i '' 's|js/jquery.js"|jquery.js"|g' {} \;	
117  
-	# ... And then move it the finished directory
118  
-	@@mv tmp/${NAME} ${OUTPUT}/demos
119  
-	# Last, zip up the the whole folder
120  
-	@@zip -rq tmp/${NAME}.zip ${OUTPUT}
121  
-	@@mv tmp/${NAME}.zip ${OUTPUT}/${NAME}.docs.zip
122  
-	# Remove the temporary files
  114
+		-exec perl -pi -e \
  115
+		's|js/"|${NAME}.min.js"|g;s|css/themes/default/|${NAME}.min.css|g;s|js/jquery.js"|jquery.js"|g' {} \;
  116
+	# ... Move and zip up the the whole folder
  117
+	@@mv tmp/${NAME} ${OUTPUT}/${NAME}
  118
+	@@zip -rq ${OUTPUT}/${NAME}.docs.zip ${OUTPUT}/${NAME}
  119
+	@@mv ${OUTPUT}/${NAME} ${OUTPUT}/demos
  120
+	# Finish by removing the temporary files
123 121
 	@@rm -rf tmp
124 122
 	# -------------------------------------------------
125 123
 
@@ -182,7 +180,7 @@ nightlies: init js css zip docs
182 180
 	# Time to put these on the CDN
183 181
 	@@mkdir -p tmp/nightlies
184 182
 	@@mv ${OUTPUT} tmp/nightlies/$$(date "+%Y%m%d")
185  
-	@@scp -r nightlies/* jqadmin@code.origin.jquery.com:/var/www/html/code.jquery.com/mobile/nightlies/
  183
+	@@scp -r tmp/nightlies/* jqadmin@code.origin.jquery.com:/var/www/html/code.jquery.com/mobile/nightlies/
186 184
 	# Do some cleanup to wrap it up
187 185
 	@@rm -rf tmp
188 186
 	# -------------------------------------------------

0 notes on commit 366d33e

Please sign in to comment.
Something went wrong with that request. Please try again.