Skip to content

Commit 838ad83

Browse files
authored
Explicitly show "Currently not on an official channel." (flutter#84992)
1 parent cb4fba2 commit 838ad83

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

packages/flutter_tools/lib/src/commands/channel.dart

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,11 @@ class ChannelCommand extends FlutterCommand {
113113
}
114114
}
115115
}
116+
117+
if (currentChannel == 'unknown') {
118+
globals.printStatus('');
119+
globals.printStatus('Currently not on an official channel.');
120+
}
116121
}
117122

118123
Future<void> _switchChannel(String branchName) async {

packages/flutter_tools/test/general.shard/channel_test.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ void main() {
159159
.where((String line) => line?.isNotEmpty == true)
160160
.skip(1); // remove `Flutter channels:` line
161161

162-
expect(rows, <String>['dev', 'beta', 'stable']);
162+
expect(rows, <String>['dev', 'beta', 'stable', 'Currently not on an official channel.']);
163163
}, overrides: <Type, Generator>{
164164
ProcessManager: () => fakeProcessManager,
165165
FileSystem: () => MemoryFileSystem.test(),

0 commit comments

Comments
 (0)