Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(174)

Unified Diff: chrome/common/extensions/docs/server2/start_dev_server.py

Issue 10500004: Die build.py, Die: Part 2 (LocalFetcher, Handlebar support, build script) (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Added parens Created 8 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/common/extensions/docs/server2/start_dev_server.py
diff --git a/chrome/common/extensions/docs/server2/start_dev_server.py b/chrome/common/extensions/docs/server2/start_dev_server.py
new file mode 100755
index 0000000000000000000000000000000000000000..ffed88deb7bf62b36e5bca613b9e7a676e9728c4
--- /dev/null
+++ b/chrome/common/extensions/docs/server2/start_dev_server.py
@@ -0,0 +1,35 @@
+#!/usr/bin/env python
+# Copyright (c) 2012 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+import os
+import signal
+import shutil
+import subprocess
+import sys
+
+import build_server
+
+SERVER_PATH = sys.path[0]
+SRC_PATH = os.path.join(SERVER_PATH, os.pardir, os.pardir, os.pardir, os.pardir,
+ os.pardir)
+FILENAMES = ['app.yaml', 'echo_handler.py']
+
+def CleanUp(signal, frame):
+ for filename in FILENAMES:
+ os.remove(os.path.join(SRC_PATH, filename))
+
+if len(sys.argv) < 2:
+ print 'usage: start_dev_server.py <location of dev_appserver.py> [options]'
+ exit(0)
+
+signal.signal(signal.SIGINT, CleanUp)
+
+build_server.main()
+for filename in FILENAMES:
+ shutil.copy(os.path.join(SERVER_PATH, filename),
+ os.path.join(SRC_PATH, filename))
+args = sys.argv[1:]
+args.append(SRC_PATH)
+subprocess.call(args)

Powered by Google App Engine
This is Rietveld 408576698