Reland: Update link branches to main (#146882)

Reland https://github.com/flutter/flutter/pull/146558, reverted in https://github.com/flutter/flutter/pull/146880 due to an outdated test result

## Original description

- Update CS and googlesource.com link branches
- Update GitHub /blob/ and /tree/ links

Tested links manually and fixes a few broken or deprecated links

Added a test that validates that `master` isn't used, except for specified repos.

Part of https://github.com/flutter/flutter/issues/121564
This commit is contained in:
Pierre-Louis
2024-04-17 15:16:33 +02:00
committed by GitHub
parent f5815f923a
commit 4a65a76279
42 changed files with 120 additions and 55 deletions

View File

@@ -23,4 +23,4 @@ known, it can be explicitly provided to attach via the command-line, e.g.
## Source
See the [source](https://github.com/flutter/flutter/blob/master/packages/flutter_tools/lib/src/commands/attach.dart) for the attach command.
See the [source](https://github.com/flutter/flutter/blob/main/packages/flutter_tools/lib/src/commands/attach.dart) for the attach command.

View File

@@ -300,7 +300,7 @@ The following subset of the app domain is available in `flutter run --machine`.
## Source
See the [source](https://github.com/flutter/flutter/blob/master/packages/flutter_tools/lib/src/commands/daemon.dart) for the daemon protocol and implementation.
See the [source](https://github.com/flutter/flutter/blob/main/packages/flutter_tools/lib/src/commands/daemon.dart) for the daemon protocol and implementation.
## Changelog

View File

@@ -728,7 +728,7 @@ void _handlePosixException(Exception e, String? message, int errorCode, String?
// From:
// https://github.com/torvalds/linux/blob/master/include/uapi/asm-generic/errno.h
// https://github.com/torvalds/linux/blob/master/include/uapi/asm-generic/errno-base.h
// https://github.com/apple/darwin-xnu/blob/master/bsd/dev/dtrace/scripts/errno.d
// https://github.com/apple/darwin-xnu/blob/main/bsd/dev/dtrace/scripts/errno.d
const int eperm = 1;
const int enospc = 28;
const int eacces = 13;
@@ -762,7 +762,7 @@ void _handlePosixException(Exception e, String? message, int errorCode, String?
}
void _handleMacOSException(Exception e, String? message, int errorCode, String? posixPermissionSuggestion) {
// https://github.com/apple/darwin-xnu/blob/master/bsd/dev/dtrace/scripts/errno.d
// https://github.com/apple/darwin-xnu/blob/main/bsd/dev/dtrace/scripts/errno.d
const int ebadarch = 86;
if (errorCode == ebadarch) {
final StringBuffer errorBuffer = StringBuffer();

View File

@@ -229,7 +229,7 @@ class AnsiTerminal implements Terminal {
// Assume unicode emojis are supported when not on Windows.
// If we are on Windows, unicode emojis are supported in Windows Terminal,
// which sets the WT_SESSION environment variable. See:
// https://github.com/microsoft/terminal/blob/master/doc/user-docs/index.md#tips-and-tricks
// https://learn.microsoft.com/en-us/windows/terminal/tips-and-tricks
@override
bool get supportsEmoji => !_platform.isWindows
|| _platform.environment.containsKey('WT_SESSION');

View File

@@ -221,7 +221,7 @@ class UpgradeCommandRunner {
'We do not recommend using this channel for normal use as it more likely to contain serious regressions.\n'
'\n'
'For information on contributing to Flutter, see our contributing guide:\n'
' https://github.com/flutter/flutter/blob/master/CONTRIBUTING.md\n'
' https://github.com/flutter/flutter/blob/main/CONTRIBUTING.md\n'
'\n'
'For the most up to date stable version of flutter, consider using the "beta" channel instead. '
'The Flutter "beta" channel enjoys all the same automated testing as the "stable" channel, '

View File

@@ -47,7 +47,7 @@ bool _inUnitTest() {
/// for language declarations other than library, part, or import.
///
/// The specification for the language version tag is defined at:
/// https://github.com/dart-lang/language/blob/master/accepted/future-releases/language-versioning/feature-specification.md#individual-library-language-version-override
/// https://github.com/dart-lang/language/blob/main/accepted/2.8/language-versioning/feature-specification.md#individual-library-language-version-override
LanguageVersion determineLanguageVersion(File file, Package? package, String flutterRoot) {
int blockCommentDepth = 0;
// If reading the file fails, default to a null-safe version. The

View File

@@ -2,7 +2,7 @@
This document is Flutter-specific. For information on the standard Dart DAP implementation, [see this document](https://github.com/dart-lang/sdk/blob/main/pkg/dds/tool/dap/README.md).
Flutter includes support for debugging using [the Debug Adapter Protocol](https://microsoft.github.io/debug-adapter-protocol/) as an alternative to using the [VM Service](https://github.com/dart-lang/sdk/blob/master/runtime/vm/service/service.md) directly, simplifying the integration for new editors.
Flutter includes support for debugging using [the Debug Adapter Protocol](https://microsoft.github.io/debug-adapter-protocol/) as an alternative to using the [VM Service](https://github.com/dart-lang/sdk/blob/main/runtime/vm/service/service.md) directly, simplifying the integration for new editors.
The debug adapters are started with the `flutter debug-adapter` command and are intended to be consumed by DAP-compliant tools such as Flutter-specific extensions for editors, or configured by users whose editors include generic configurable DAP clients.

View File

@@ -190,7 +190,7 @@ void main() {
'for normal use as it more likely to contain serious regressions.\n'
'\n'
'For information on contributing to Flutter, see our contributing guide:\n'
' https://github.com/flutter/flutter/blob/master/CONTRIBUTING.md\n'
' https://github.com/flutter/flutter/blob/main/CONTRIBUTING.md\n'
'\n'
'For the most up to date stable version of flutter, consider using the "beta" channel '
'instead. The Flutter "beta" channel enjoys all the same automated testing as the '

View File

@@ -75,7 +75,7 @@ const String _kSamplePluginPubspec = '''
name: path_provider_linux
description: linux implementation of the path_provider plugin
// version: 2.0.1
// homepage: https://github.com/flutter/plugins/tree/master/packages/path_provider/path_provider_linux
// homepage: https://github.com/flutter/plugins/tree/main/packages/path_provider/path_provider_linux
flutter:
plugin:

View File

@@ -6,7 +6,7 @@
// by Flutter Web users.
// This should be somewhat kept in sync with the different index.html files present
// in `flutter/dev/integration_tests/web/web`.
// @see https://github.com/flutter/flutter/tree/master/dev/integration_tests/web/web
// @see https://github.com/flutter/flutter/tree/main/dev/integration_tests/web/web
/// index_with_flutterjs_entrypoint_loaded.html
String indexHtmlFlutterJsCallback = _generateFlutterJsIndexHtml('''