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

Unified Diff: pkg/docgen/lib/docgen.dart

Issue 175743003: pkg/docgen: fix compile and serve (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 10 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/docgen/lib/docgen.dart
diff --git a/pkg/docgen/lib/docgen.dart b/pkg/docgen/lib/docgen.dart
index a7923e4d70292bc62f6192062c35e7a6f921174b..c4aa90598bdf50fd298f2ffcd0ea556457a55aa2 100644
--- a/pkg/docgen/lib/docgen.dart
+++ b/pkg/docgen/lib/docgen.dart
@@ -729,14 +729,13 @@ class _Viewer {
/// directory, to run as a webpage.
var processResult = Process.runSync(_Generator._pubScript,
['upgrade'], runInShell: true,
- workingDirectory: path.join(viewerCodePath, 'client'));
+ workingDirectory: viewerCodePath);
print('process output: ${processResult.stdout}');
print('process stderr: ${processResult.stderr}');
var dir = new Directory(_Generator._outputDirectory == null? 'docs' :
_Generator._outputDirectory);
- _webDocsDir = new Directory(path.join(viewerCodePath, 'client',
- 'web', 'docs'));
+ _webDocsDir = new Directory(path.join(viewerCodePath, 'web', 'docs'));
if (dir.existsSync()) {
// Move the docs folder to dartdoc-viewer/client/web/docs
dir.renameSync(_webDocsDir.path);
@@ -754,11 +753,10 @@ class _Viewer {
// Compile the code to JavaScript so we can run on any browser.
print('Compile app to JavaScript for viewing.');
var processResult = Process.runSync(_Generator._dartBinary,
- ['deploy.dart'], workingDirectory : path.join(viewerCodePath,
- 'client'), runInShell: true);
+ ['deploy.dart'], workingDirectory: viewerCodePath, runInShell: true);
print('process output: ${processResult.stdout}');
print('process stderr: ${processResult.stderr}');
- var outputDir = path.join(viewerCodePath, 'client', 'out', 'web');
+ var outputDir = path.join(viewerCodePath, 'out', 'web');
print('Docs are available at $outputDir');
}
}
@@ -772,8 +770,7 @@ class _Viewer {
'http://localhost:${httpServer.port}');
httpServer.listen((HttpRequest request) {
var response = request.response;
- var basePath = path.join(viewerCodePath, 'client', 'out',
- 'web');
+ var basePath = path.join(viewerCodePath, 'out', 'web');
var requestPath = path.join(basePath, request.uri.path.substring(1));
bool found = true;
var file = new File(requestPath);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698