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
9eada88b
Unverified
Commit
9eada88b
authored
Jan 18, 2019
by
Liam Appelbe
Committed by
GitHub
Jan 18, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Experimental flags in flutter (#26715)
* exp flags in flutter * Fix test failures
parent
4fe79442
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
4 deletions
+23
-4
run.dart
packages/flutter_tools/lib/src/commands/run.dart
+5
-1
flutter_command.dart
packages/flutter_tools/lib/src/runner/flutter_command.dart
+18
-3
No files found.
packages/flutter_tools/lib/src/commands/run.dart
View file @
9eada88b
...
...
@@ -145,7 +145,11 @@ class RunCommand extends RunCommandBase {
'intended for use in generating automated flutter benchmarks.'
,
)
..
addOption
(
FlutterOptions
.
kExtraFrontEndOptions
,
hide:
true
)
..
addOption
(
FlutterOptions
.
kExtraGenSnapshotOptions
,
hide:
true
);
..
addOption
(
FlutterOptions
.
kExtraGenSnapshotOptions
,
hide:
true
)
..
addMultiOption
(
FlutterOptions
.
kEnableExperiment
,
splitCommas:
true
,
hide:
true
,
);
}
@override
...
...
packages/flutter_tools/lib/src/runner/flutter_command.dart
View file @
9eada88b
...
...
@@ -63,6 +63,7 @@ class FlutterCommandResult {
class
FlutterOptions
{
static
const
String
kExtraFrontEndOptions
=
'extra-front-end-options'
;
static
const
String
kExtraGenSnapshotOptions
=
'extra-gen-snapshot-options'
;
static
const
String
kEnableExperiment
=
'enable-experiment'
;
static
const
String
kFileSystemRoot
=
'filesystem-root'
;
static
const
String
kFileSystemScheme
=
'filesystem-scheme'
;
}
...
...
@@ -389,6 +390,22 @@ abstract class FlutterCommand extends Command<void> {
'--patch-number (
${argResults['patch-number']}
) must be an int.'
,
null
);
}
String
extraFrontEndOptions
=
argParser
.
options
.
containsKey
(
FlutterOptions
.
kExtraFrontEndOptions
)
?
argResults
[
FlutterOptions
.
kExtraFrontEndOptions
]
:
null
;
if
(
argParser
.
options
.
containsKey
(
FlutterOptions
.
kEnableExperiment
)
&&
argResults
[
FlutterOptions
.
kEnableExperiment
]
!=
null
)
{
for
(
String
expFlag
in
argResults
[
FlutterOptions
.
kEnableExperiment
])
{
final
String
flag
=
'--enable-experiment='
+
expFlag
;
if
(
extraFrontEndOptions
!=
null
)
{
extraFrontEndOptions
+=
','
+
flag
;
}
else
{
extraFrontEndOptions
=
flag
;
}
}
}
return
BuildInfo
(
getBuildMode
(),
argParser
.
options
.
containsKey
(
'flavor'
)
?
argResults
[
'flavor'
]
...
...
@@ -410,9 +427,7 @@ abstract class FlutterCommand extends Command<void> {
baselineDir:
argParser
.
options
.
containsKey
(
'baseline-dir'
)
?
argResults
[
'baseline-dir'
]
:
null
,
extraFrontEndOptions:
argParser
.
options
.
containsKey
(
FlutterOptions
.
kExtraFrontEndOptions
)
?
argResults
[
FlutterOptions
.
kExtraFrontEndOptions
]
:
null
,
extraFrontEndOptions:
extraFrontEndOptions
,
extraGenSnapshotOptions:
argParser
.
options
.
containsKey
(
FlutterOptions
.
kExtraGenSnapshotOptions
)
?
argResults
[
FlutterOptions
.
kExtraGenSnapshotOptions
]
:
null
,
...
...
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