Migrate removed command `pub` to `dart pub` in docs & messages (#3506)

diff --git a/.github/ISSUE_TEMPLATE/1-PUB_SITE.md b/.github/ISSUE_TEMPLATE/1-PUB_SITE.md
index df33eee..3b90c7a 100644
--- a/.github/ISSUE_TEMPLATE/1-PUB_SITE.md
+++ b/.github/ISSUE_TEMPLATE/1-PUB_SITE.md
@@ -1,6 +1,6 @@
 ---
 name: There is a problem with pub.dev
-about: A `pub get` fails because of an outage at `pub.dev`, the site
+about: A `dart pub get` or `flutter pub get` fails because of an outage at `pub.dev`, the site
   cannot be loaded, or there is an issue with a particular package such as a
   request to have a published package removed.
 
diff --git a/README.md b/README.md
index 0d40e6c..83f7ec1 100644
--- a/README.md
+++ b/README.md
@@ -64,7 +64,7 @@
 the test description. This is used when tests can take a long time to run to
 avoid having the tests time out when running on the build bots. For example,
 `tests/get/hosted/get_transitive_test.dart` tests the resolution of transitive
-hosted dependencies when using `pub get`.
+hosted dependencies when using `dart pub get`/`flutter pub get`.
 
 ## Landing your patch
 
diff --git a/lib/src/command/login.dart b/lib/src/command/login.dart
index 96c04d8..8f428ab 100644
--- a/lib/src/command/login.dart
+++ b/lib/src/command/login.dart
@@ -40,7 +40,7 @@
             'Run `$topLevelProgram pub logout` to delete your credentials and try again.');
       }
       log.warning('You are already logged in as $userInfo\n'
-          'Run `pub logout` to log out and try again.');
+          'Run `$topLevelProgram pub logout` to log out and try again.');
     }
   }
 
diff --git a/lib/src/command/outdated.dart b/lib/src/command/outdated.dart
index 59131c4..6f22fd5 100644
--- a/lib/src/command/outdated.dart
+++ b/lib/src/command/outdated.dart
@@ -556,7 +556,7 @@
     }
   } else {
     log.message('\nNo pubspec.lock found. There are no Current versions.\n'
-        'Run `pub get` to create a pubspec.lock with versions matching your '
+        'Run `$topLevelProgram pub get` to create a pubspec.lock with versions matching your '
         'pubspec.yaml.');
   }
   if (notAtResolvable != 0) {
diff --git a/lib/src/validator/null_safety_mixed_mode.dart b/lib/src/validator/null_safety_mixed_mode.dart
index 31b755c..b17e0e5 100644
--- a/lib/src/validator/null_safety_mixed_mode.dart
+++ b/lib/src/validator/null_safety_mixed_mode.dart
@@ -6,6 +6,7 @@
 
 import 'package:path/path.dart' as p;
 
+import '../command_runner.dart';
 import '../null_safety_analysis.dart';
 import '../package_name.dart';
 import '../source/path.dart';
@@ -44,8 +45,8 @@
 We highly recommend that you wait until all of your dependencies have been
 migrated before publishing.
 
-Run `pub outdated --mode=null-safety` for more information about the state of
-dependencies.
+Run `$topLevelProgram pub outdated --mode=null-safety` for more information about the state
+of dependencies.
 
 See ${NullSafetyAnalysis.guideUrl}
 for more information about migrating.
diff --git a/test/testdata/goldens/outdated/outdated_test/no lockfile.txt b/test/testdata/goldens/outdated/outdated_test/no lockfile.txt
index 87a8997..70ce88f 100644
--- a/test/testdata/goldens/outdated/outdated_test/no lockfile.txt
+++ b/test/testdata/goldens/outdated/outdated_test/no lockfile.txt
@@ -49,7 +49,7 @@
 foo           -        1.2.3       1.2.3       1.2.3   
 
 No pubspec.lock found. There are no Current versions.
-Run `pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
+Run `dart pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
 
 1 dependency is constrained to a version that is older than a resolvable version.
 To update it, edit pubspec.yaml, or run `dart pub upgrade --major-versions`.
@@ -68,7 +68,7 @@
 foo           -        1.2.3       1.2.3       1.2.3   
 
 No pubspec.lock found. There are no Current versions.
-Run `pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
+Run `dart pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
 
 1 dependency is constrained to a version that is older than a resolvable version.
 To update it, edit pubspec.yaml, or run `dart pub upgrade --major-versions`.
@@ -87,7 +87,7 @@
 foo           -        1.2.3       1.2.3       1.2.3   
 
 No pubspec.lock found. There are no Current versions.
-Run `pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
+Run `dart pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
 
 1 dependency is constrained to a version that is older than a resolvable version.
 To update it, edit pubspec.yaml, or run `dart pub upgrade --major-versions`.
@@ -106,7 +106,7 @@
 foo           -        1.2.3       1.2.3       1.2.3   
 
 No pubspec.lock found. There are no Current versions.
-Run `pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
+Run `dart pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
 
 1 dependency is constrained to a version that is older than a resolvable version.
 To update it, edit pubspec.yaml, or run `dart pub upgrade --major-versions`.
@@ -125,7 +125,7 @@
 foo           -        1.2.3       1.2.3       1.2.3   
 
 No pubspec.lock found. There are no Current versions.
-Run `pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
+Run `dart pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
 
 1 dependency is constrained to a version that is older than a resolvable version.
 To update it, edit pubspec.yaml, or run `dart pub upgrade --major-versions`.
@@ -144,7 +144,7 @@
 foo           -        1.2.3       1.2.3       1.2.3   
 
 No pubspec.lock found. There are no Current versions.
-Run `pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
+Run `dart pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
 
 1 dependency is constrained to a version that is older than a resolvable version.
 To update it, edit pubspec.yaml, or run `dart pub upgrade --major-versions`.
@@ -164,7 +164,7 @@
 foo           -        ✗1.2.3      ✗1.2.3      ✗1.2.3  
 
 No pubspec.lock found. There are no Current versions.
-Run `pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
+Run `dart pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
 
 1 dependency is constrained to a version that is older than a resolvable version.
 To update it, edit pubspec.yaml, or run `dart pub upgrade --null-safety`.
@@ -184,7 +184,7 @@
 foo           -        ✗1.2.3      ✗1.2.3      ✗1.2.3  
 
 No pubspec.lock found. There are no Current versions.
-Run `pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
+Run `dart pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
 
 1 dependency is constrained to a version that is older than a resolvable version.
 To update it, edit pubspec.yaml, or run `dart pub upgrade --null-safety`.
@@ -204,7 +204,7 @@
 foo           -        ✗1.2.3      ✗1.2.3      ✗1.2.3  
 
 No pubspec.lock found. There are no Current versions.
-Run `pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
+Run `dart pub get` to create a pubspec.lock with versions matching your pubspec.yaml.
 
 1 dependency is constrained to a version that is older than a resolvable version.
 To update it, edit pubspec.yaml, or run `dart pub upgrade --null-safety`.