validate method
Implementation
@override
Future<ValidationCheck> validate(ReleaseContext context) async {
final available = await _client.isShorebirdAvailable();
if (!available) {
return ValidationCheck(
name: name,
status: CheckStatus.failed,
message:
'Shorebird CLI is not installed or not available on PATH. Run "curl --proto \'=https\' --tlsv1.2 -sSf https://raw.githubusercontent.com/shorebirdtech/install/main/install.sh | sh" or visit https://shorebird.dev to install.',
);
}
final version = await _client.getShorebirdVersion();
return ValidationCheck(
name: name,
status: CheckStatus.passed,
message: version != null && version.isNotEmpty
? 'Shorebird CLI detected ($version)'
: 'Shorebird CLI detected',
);
}