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
ce7df25a
Unverified
Commit
ce7df25a
authored
Jun 16, 2021
by
Anurag Roy
Committed by
GitHub
Jun 16, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move flutterGit from `version.dart` (#79568)
parent
240891fe
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
6 deletions
+6
-6
globals_null_migrated.dart
packages/flutter_tools/lib/src/globals_null_migrated.dart
+3
-0
version.dart
packages/flutter_tools/lib/src/version.dart
+3
-6
No files found.
packages/flutter_tools/lib/src/globals_null_migrated.dart
View file @
ce7df25a
...
...
@@ -37,6 +37,9 @@ import 'project.dart';
import
'reporting/reporting.dart'
;
import
'version.dart'
;
/// The flutter GitHub repository.
String
get
flutterGit
=>
platform
.
environment
[
'FLUTTER_GIT_URL'
]
??
'https://github.com/flutter/flutter.git'
;
Artifacts
?
get
artifacts
=>
context
.
get
<
Artifacts
>();
BuildSystem
?
get
buildSystem
=>
context
.
get
<
BuildSystem
>();
Cache
get
cache
=>
context
.
get
<
Cache
>()!;
...
...
packages/flutter_tools/lib/src/version.dart
View file @
ce7df25a
...
...
@@ -14,9 +14,6 @@ import 'cache.dart';
import
'convert.dart'
;
import
'globals_null_migrated.dart'
as
globals
;
/// The flutter GitHub repository.
String
get
_flutterGit
=>
globals
.
platform
.
environment
[
'FLUTTER_GIT_URL'
]
??
'https://github.com/flutter/flutter.git'
;
const
String
_unknownFrameworkVersion
=
'0.0.0-unknown'
;
/// The names of each channel/branch in order of increasing stability.
...
...
@@ -274,7 +271,7 @@ class FlutterVersion {
'remote'
,
'add'
,
_versionCheckRemote
,
_
flutterGit
,
globals
.
flutterGit
,
]);
await
_run
(<
String
>[
'git'
,
'fetch'
,
_versionCheckRemote
,
branch
]);
return
_latestGitCommitDate
(
...
...
@@ -284,7 +281,7 @@ class FlutterVersion {
}
on
VersionCheckError
catch
(
error
)
{
if
(
globals
.
platform
.
environment
.
containsKey
(
'FLUTTER_GIT_URL'
))
{
globals
.
logger
.
printError
(
'Warning: the Flutter git upstream was overridden '
'by the environment variable FLUTTER_GIT_URL =
$
_flutterGit
'
);
'by the environment variable FLUTTER_GIT_URL =
$
{globals.flutterGit}
'
);
}
globals
.
logger
.
printError
(
error
.
toString
());
rethrow
;
...
...
@@ -632,7 +629,7 @@ class GitTagVersion {
if
(
channel
==
'dev'
||
channel
==
'beta'
||
channel
==
'stable'
)
{
globals
.
printTrace
(
'Skipping request to fetchTags - on well known channel
$channel
.'
);
}
else
{
_runGit
(
'git fetch
$
_flutterGit
--tags -f'
,
processUtils
,
workingDirectory
);
_runGit
(
'git fetch
$
{globals.flutterGit}
--tags -f'
,
processUtils
,
workingDirectory
);
}
}
final
List
<
String
>
tags
=
_runGit
(
...
...
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