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

Unified Diff: tools/dom/docs/bin/docs.dart

Issue 12035057: First half of the new HTML json docs. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Removed unneeded file. Created 7 years, 11 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 | « sdk/lib/html/html_common/metadata.dart ('k') | tools/dom/docs/docs.json » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/dom/docs/bin/docs.dart
diff --git a/tools/dom/docs/bin/docs.dart b/tools/dom/docs/bin/docs.dart
new file mode 100644
index 0000000000000000000000000000000000000000..697243268ca547d807d3c9141c9838742b445401
--- /dev/null
+++ b/tools/dom/docs/bin/docs.dart
@@ -0,0 +1,32 @@
+// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
+// for details. All rights reserved. Use of this source code is governed by a
+// BSD-style license that can be found in the LICENSE file.
+
+/**
+ * This program reads the HTML libraries from [LIB_PATH] and outputs their
+ * documentation to [JSON_PATH].
+ */
+
+import 'dart:io';
+import 'dart:async';
+
+import '../lib/docs.dart';
+
+final Path json_path = scriptDir.append('../docs.json').canonicalize();
+final Path lib_path = scriptDir.append('../../../../sdk/').canonicalize();
+
+main() {
+ print('Converting HTML docs from $lib_path to $json_path.');
+
+ var anyErrors = convert(lib_path, json_path);
+
+ print('Converted HTML docs ${anyErrors ? "with $anyErrors" : "without"}'
+ ' errors.');
+}
+
+/**
+ * Gets the full path to the directory containing the entrypoint of the current
+ * script.
+ */
+Path get scriptDir =>
+ new Path(new Options().script).directoryPath;
« no previous file with comments | « sdk/lib/html/html_common/metadata.dart ('k') | tools/dom/docs/docs.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698