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

Unified Diff: pkg/code_transformers/lib/src/dart_sdk.dart

Issue 174053004: Revert "Adding package:code_transformers for unifying common transformers code" (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 | « pkg/code_transformers/lib/resolver.dart ('k') | pkg/code_transformers/lib/src/resolver.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/code_transformers/lib/src/dart_sdk.dart
diff --git a/pkg/code_transformers/lib/src/dart_sdk.dart b/pkg/code_transformers/lib/src/dart_sdk.dart
deleted file mode 100644
index fe31d890ce0d1ed5d50f93a99719c88d714488f6..0000000000000000000000000000000000000000
--- a/pkg/code_transformers/lib/src/dart_sdk.dart
+++ /dev/null
@@ -1,30 +0,0 @@
-// Copyright (c) 2014, 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.
-
-library code_transformers.src.dart_sdk;
-
-import 'dart:convert' as convert;
-import 'dart:io' show Directory, Platform, Process;
-import 'package:path/path.dart' as path;
-
-
-/// Attempts to provide the current Dart SDK directory.
-///
-/// Note that this may not be correct when executing outside of `pub`.
-String get dartSdkDirectory {
- if (path.split(Platform.executable).length == 1) {
- // TODO(blois): make this cross-platform.
- // HACK: A single part, hope it's on the path.
- var result = Process.runSync('which', ['dart'],
- stdoutEncoding: convert.UTF8);
- return path.dirname(path.dirname(result.stdout));
- }
- var sdkDir = path.dirname(path.absolute(Platform.executable));
- // If there's a sub-dir named dart-sdk then we're most likely executing from
- // a dart enlistment build directory.
- if (new Directory(path.join(sdkDir, 'dart-sdk')).existsSync()) {
- return path.join(sdkDir, 'dart-sdk');
- }
- return sdkDir;
-}
« no previous file with comments | « pkg/code_transformers/lib/resolver.dart ('k') | pkg/code_transformers/lib/src/resolver.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698