@@ -58,11 +58,11 @@ final maxAssetContentLength = 256 * 1024;
5858final _defaultMaxVersionsPerPackage = 1000 ;
5959
6060final Logger _logger = Logger ('pub.cloud_repository' );
61- final _validGithubUserOrRepoRegExp =
61+ final _validGitHubUserOrRepoRegExp =
6262 RegExp (r'^[a-z0-9\-\._]+$' , caseSensitive: false );
63- final _validGithubVersionPattern =
63+ final _validGitHubVersionPattern =
6464 RegExp (r'^[a-z0-9\-._]+$' , caseSensitive: false );
65- final _validGithubEnvironment =
65+ final _validGitHubEnvironment =
6666 RegExp (r'^[a-z0-9\-\._]+$' , caseSensitive: false );
6767
6868/// Sets the package backend service.
@@ -538,8 +538,8 @@ class PackageBackend {
538538 InvalidInputException .check (parts.length == 2 ,
539539 'The `repository` field must follow the `<owner>/<repository>` pattern.' );
540540 InvalidInputException .check (
541- _validGithubUserOrRepoRegExp .hasMatch (parts[0 ]) &&
542- _validGithubUserOrRepoRegExp .hasMatch (parts[1 ]),
541+ _validGitHubUserOrRepoRegExp .hasMatch (parts[0 ]) &&
542+ _validGitHubUserOrRepoRegExp .hasMatch (parts[1 ]),
543543 'The `repository` field has invalid characters.' );
544544 }
545545
@@ -549,7 +549,7 @@ class PackageBackend {
549549 InvalidInputException .check (
550550 tagPatternParts
551551 .where ((e) => e.isNotEmpty)
552- .every (_validGithubVersionPattern .hasMatch),
552+ .every (_validGitHubVersionPattern .hasMatch),
553553 'The `tagPattern` field has invalid characters.' );
554554
555555 InvalidInputException .check (
@@ -558,7 +558,7 @@ class PackageBackend {
558558
559559 if (environment.isNotEmpty) {
560560 InvalidInputException .check (
561- _validGithubEnvironment .hasMatch (environment),
561+ _validGitHubEnvironment .hasMatch (environment),
562562 'The `environment` field has invalid characters.' );
563563 }
564564 }
@@ -1280,8 +1280,8 @@ class PackageBackend {
12801280 await packageBackend.isPackageAdmin (package, agent.user.userId)) {
12811281 return ;
12821282 }
1283- if (agent is AuthenticatedGithubAction ) {
1284- await _checkGithubActionAllowed (agent, package, newVersion);
1283+ if (agent is AuthenticatedGitHubAction ) {
1284+ await _checkGitHubActionAllowed (agent, package, newVersion);
12851285 return ;
12861286 }
12871287 if (agent is AuthenticatedGcpServiceAccount ) {
@@ -1295,7 +1295,7 @@ class PackageBackend {
12951295 agent.displayId, package.name! );
12961296 }
12971297
1298- Future <void > _checkGithubActionAllowed ( AuthenticatedGithubAction agent,
1298+ Future <void > _checkGitHubActionAllowed ( AuthenticatedGitHubAction agent,
12991299 Package package, String newVersion) async {
13001300 final githubConfig = package.automatedPublishing? .githubConfig;
13011301 final githubLock = package.automatedPublishing? .githubLock;
@@ -1648,15 +1648,15 @@ class PackageBackend {
16481648 Package package, AuthenticatedAgent agent) {
16491649 final current = package.automatedPublishing;
16501650 if (current == null ) {
1651- if (agent is AuthenticatedGithubAction ||
1651+ if (agent is AuthenticatedGitHubAction ||
16521652 agent is AuthenticatedGcpServiceAccount ) {
16531653 // This should be unreachable
16541654 throw AssertionError ('Authentication should never have been possible' );
16551655 }
16561656 return ;
16571657 }
1658- if (agent is AuthenticatedGithubAction && current.githubLock == null ) {
1659- current.githubLock = GithubPublishingLock (
1658+ if (agent is AuthenticatedGitHubAction && current.githubLock == null ) {
1659+ current.githubLock = GitHubPublishingLock (
16601660 repositoryOwnerId: agent.payload.repositoryOwnerId,
16611661 repositoryId: agent.payload.repositoryId,
16621662 );
0 commit comments