Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abdullh.alsoleman
Front-End
Commits
5e7e7b6e
Commit
5e7e7b6e
authored
Jul 25, 2016
by
Devon Carew
Committed by
GitHub
Jul 25, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Revert "make the flutter run -t target option optional (#5029)" (#5032)
This reverts commit
32ad81c8
.
parent
32ad81c8
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
14 additions
and
22 deletions
+14
-22
build_aot.dart
packages/flutter_tools/lib/src/commands/build_aot.dart
+1
-1
build_apk.dart
packages/flutter_tools/lib/src/commands/build_apk.dart
+2
-2
build_flx.dart
packages/flutter_tools/lib/src/commands/build_flx.dart
+1
-1
build_ios.dart
packages/flutter_tools/lib/src/commands/build_ios.dart
+1
-1
drive.dart
packages/flutter_tools/lib/src/commands/drive.dart
+3
-3
listen.dart
packages/flutter_tools/lib/src/commands/listen.dart
+1
-1
refresh.dart
packages/flutter_tools/lib/src/commands/refresh.dart
+1
-1
run.dart
packages/flutter_tools/lib/src/commands/run.dart
+3
-2
flutter_command.dart
packages/flutter_tools/lib/src/runner/flutter_command.dart
+1
-10
No files found.
packages/flutter_tools/lib/src/commands/build_aot.dart
View file @
5e7e7b6e
...
...
@@ -56,7 +56,7 @@ class BuildAotCommand extends BuildSubCommand {
String
typeName
=
path
.
basename
(
tools
.
getEngineArtifactsDirectory
(
platform
,
getBuildMode
()).
path
);
Status
status
=
logger
.
startProgress
(
'Building AOT snapshot in
${getModeName(getBuildMode())}
mode (
$typeName
)...'
);
String
outputPath
=
await
buildAotSnapshot
(
findMainDartFile
(
targetFile
),
findMainDartFile
(
argResults
[
'target'
]
),
platform
,
getBuildMode
(),
outputPath:
argResults
[
'output-dir'
],
...
...
packages/flutter_tools/lib/src/commands/build_apk.dart
View file @
5e7e7b6e
...
...
@@ -208,7 +208,7 @@ class BuildApkCommand extends BuildSubCommand {
return
await
buildAndroidWithGradle
(
TargetPlatform
.
android_arm
,
getBuildMode
(),
target:
targetFile
target:
argResults
[
'target'
]
);
}
else
{
// TODO(devoncarew): This command should take an arg for the output type (arm / x64).
...
...
@@ -219,7 +219,7 @@ class BuildApkCommand extends BuildSubCommand {
manifest:
argResults
[
'manifest'
],
resources:
argResults
[
'resources'
],
outputFile:
argResults
[
'output-file'
],
target:
targetFile
,
target:
argResults
[
'target'
]
,
flxPath:
argResults
[
'flx'
],
aotPath:
argResults
[
'aot-path'
],
keystore:
(
argResults
[
'keystore'
]
??
''
).
isEmpty
?
null
:
new
ApkKeystoreInfo
(
...
...
packages/flutter_tools/lib/src/commands/build_flx.dart
View file @
5e7e7b6e
...
...
@@ -41,7 +41,7 @@ class BuildFlxCommand extends BuildSubCommand {
String
outputPath
=
argResults
[
'output-file'
];
return
await
build
(
mainPath:
targetFile
,
mainPath:
argResults
[
'target'
]
,
manifestPath:
argResults
[
'manifest'
],
outputPath:
outputPath
,
snapshotPath:
argResults
[
'snapshot'
],
...
...
packages/flutter_tools/lib/src/commands/build_ios.dart
View file @
5e7e7b6e
...
...
@@ -58,7 +58,7 @@ class BuildIOSCommand extends BuildSubCommand {
XcodeBuildResult
result
=
await
buildXcodeProject
(
app:
app
,
mode:
getBuildMode
(),
target:
targetFile
,
target:
argResults
[
'target'
]
,
buildForDevice:
!
forSimulator
,
codesign:
shouldCodesign
);
...
...
packages/flutter_tools/lib/src/commands/drive.dart
View file @
5e7e7b6e
...
...
@@ -160,7 +160,7 @@ class DriveCommand extends RunCommandBase {
}
String
_getTestFile
()
{
String
appFile
=
path
.
normalize
(
target
File
);
String
appFile
=
path
.
normalize
(
target
);
// This command extends `flutter start` and therefore CWD == package dir
String
packageDir
=
getCurrentDirectory
();
...
...
@@ -266,7 +266,7 @@ void restoreAppStarter() {
}
Future
<
int
>
startApp
(
DriveCommand
command
)
async
{
String
mainPath
=
findMainDartFile
(
command
.
target
File
);
String
mainPath
=
findMainDartFile
(
command
.
target
);
if
(
await
fs
.
type
(
mainPath
)
!=
FileSystemEntityType
.
FILE
)
{
printError
(
'Tried to run
$mainPath
, but that file does not exist.'
);
return
1
;
...
...
@@ -277,7 +277,7 @@ Future<int> startApp(DriveCommand command) async {
printTrace
(
'Building an APK.'
);
int
result
=
await
build_apk
.
buildApk
(
command
.
device
.
platform
,
target:
command
.
target
File
,
target:
command
.
target
,
buildMode:
command
.
getBuildMode
()
);
...
...
packages/flutter_tools/lib/src/commands/listen.dart
View file @
5e7e7b6e
...
...
@@ -62,7 +62,7 @@ class ListenCommand extends RunCommandBase {
result = await startApp(
deviceForCommand,
target: target
File
,
target: target,
install: firstTime,
stop: true,
debuggingOptions: new DebuggingOptions.enabled(getBuildMode()),
...
...
packages/flutter_tools/lib/src/commands/refresh.dart
View file @
5e7e7b6e
...
...
@@ -40,7 +40,7 @@ class RefreshCommand extends FlutterCommand {
Directory
tempDir
=
await
Directory
.
systemTemp
.
createTemp
(
'flutter_tools'
);
try
{
String
snapshotPath
=
path
.
join
(
tempDir
.
path
,
'snapshot_blob.bin'
);
int
result
=
await
createSnapshot
(
mainPath:
targetFile
,
snapshotPath:
snapshotPath
);
int
result
=
await
createSnapshot
(
mainPath:
argResults
[
'target'
]
,
snapshotPath:
snapshotPath
);
if
(
result
!=
0
)
{
printError
(
'Failed to run the Flutter compiler. Exit code:
$result
'
);
...
...
packages/flutter_tools/lib/src/commands/run.dart
View file @
5e7e7b6e
...
...
@@ -33,6 +33,7 @@ abstract class RunCommandBase extends FlutterCommand {
}
bool
get
traceStartup
=>
argResults
[
'trace-startup'
];
String
get
target
=>
argResults
[
'target'
];
String
get
route
=>
argResults
[
'route'
];
}
...
...
@@ -134,7 +135,7 @@ class RunCommand extends RunCommandBase {
if
(
argResults
[
'resident'
])
{
RunAndStayResident
runner
=
new
RunAndStayResident
(
deviceForCommand
,
target:
target
File
,
target:
target
,
debuggingOptions:
options
,
hotMode:
argResults
[
'hot'
]
);
...
...
@@ -149,7 +150,7 @@ class RunCommand extends RunCommandBase {
// using the `RunAndStayResident` class.
return
startApp
(
deviceForCommand
,
target:
target
File
,
target:
target
,
stop:
argResults
[
'full-restart'
],
install:
true
,
debuggingOptions:
options
,
...
...
packages/flutter_tools/lib/src/runner/flutter_command.dart
View file @
5e7e7b6e
...
...
@@ -53,15 +53,6 @@ abstract class FlutterCommand extends Command {
_usesTargetOption
=
true
;
}
String
get
targetFile
{
if
(
argResults
.
wasParsed
(
'target'
))
return
argResults
[
'target'
];
else
if
(
argResults
.
rest
.
isNotEmpty
)
return
argResults
.
rest
.
first
;
else
return
null
;
}
void
usesPubOption
()
{
argParser
.
addFlag
(
'pub'
,
defaultsTo:
true
,
...
...
@@ -193,7 +184,7 @@ abstract class FlutterCommand extends Command {
}
if
(
_usesTargetOption
)
{
String
targetPath
=
targetFile
;
String
targetPath
=
argResults
[
'target'
]
;
if
(!
FileSystemEntity
.
isFileSync
(
targetPath
))
{
printError
(
'Target file "
$targetPath
" not found.'
);
return
false
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment