1515from .terraform_parser import parse_terraform_plan
1616
1717try :
18- from revenueholdings_license . integration import rh_check
18+ from revenueholdings_license import require_license
1919 _HAS_RH_LICENSE = True
2020except ImportError :
2121 _HAS_RH_LICENSE = False
@@ -32,7 +32,7 @@ def main(ctx, no_gate) -> None:
3232 ctx .ensure_object (dict )
3333 ctx .obj ["no_gate" ] = no_gate
3434 if _HAS_RH_LICENSE and not no_gate :
35- rh_check ("deploydiff" )
35+ require_license ("deploydiff" )
3636
3737
3838@main .command ()
@@ -76,8 +76,8 @@ def preview(terraform_file, cloudformation_file, pulumi_file, verbose, exit_on_d
7676def cost (terraform_file , cloudformation_file , pulumi_file , pricing_file , threshold ) -> None :
7777 """Estimate monthly cost impact of infrastructure changes. (Pro feature)"""
7878 if _HAS_RH_LICENSE :
79- from revenueholdings_license . license import Tier , require_tier
80- require_tier (Tier . PRO , "deploydiff cost" )
79+ from revenueholdings_license import require_tier
80+ require_tier ("pro" , "deploydiff cost" )
8181 plan = _load_plan (terraform_file , cloudformation_file , pulumi_file )
8282 if plan is None :
8383 console .print ("[red]Error: Provide one of --tf, --cfn, or --pulumi[/red]" )
@@ -102,8 +102,8 @@ def cost(terraform_file, cloudformation_file, pulumi_file, pricing_file, thresho
102102def rollback (terraform_file , cloudformation_file , pulumi_file ) -> None :
103103 """Generate rollback commands for infrastructure changes. (Pro feature)"""
104104 if _HAS_RH_LICENSE :
105- from revenueholdings_license . license import Tier , require_tier
106- require_tier (Tier . PRO , "deploydiff rollback" )
105+ from revenueholdings_license import require_tier
106+ require_tier ("pro" , "deploydiff rollback" )
107107 plan = _load_plan (terraform_file , cloudformation_file , pulumi_file )
108108 if plan is None :
109109 console .print ("[red]Error: Provide one of --tf, --cfn, or --pulumi[/red]" )
@@ -182,6 +182,6 @@ def mcp() -> None:
182182 """Start an MCP server exposing all CLI commands as AI-callable tools.
183183
184184 Uses stdio transport compatible with Claude Code, Cursor, Codex, and
185- any MCP-compatible agent. Run this from your MCP client configuration.
185+ any MCP-compatible agent. Run this from your MCP client configuration.
186186 """
187187 run_for_app (main )
0 commit comments