Skip to content

Commit

Permalink
Remove billing warning (#3)
Browse files Browse the repository at this point in the history
  • Loading branch information
danerwilliams committed Aug 17, 2023
1 parent 9159fb3 commit 9d4e1f5
Showing 1 changed file with 0 additions and 37 deletions.
37 changes: 0 additions & 37 deletions apps/cli/src/actions/submit/submit_action.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
import { API_ROUTES } from '@withgraphite/graphite-cli-routes';
import chalk from 'chalk';
import { requestWithArgs } from '../../lib/api/request';
import { TContext } from '../../lib/context';
import { TScopeSpec } from '../../lib/engine/scope_spec';
import { ExitFailedError, KilledError } from '../../lib/errors';
Expand Down Expand Up @@ -144,8 +142,6 @@ export async function submitAction(
);
}

await displayRepoMessage(context);

if (!context.interactive) {
return;
}
Expand All @@ -156,39 +152,6 @@ export async function submitAction(
}
}

export async function displayRepoMessage(context: TContext): Promise<void> {
try {
cliAuthPrecondition(context);
const response = await requestWithArgs(
context.userConfig,
API_ROUTES.getRepoMessage,
{},
{
org: context.repoConfig.getRepoOwner(),
repo: context.repoConfig.getRepoName(),
}
);

if (response._response.status !== 200 || !response.message) {
return;
}

switch (response.message.status) {
case 'info':
context.splog.info(response.message.text);
break;
case 'warning':
context.splog.warn(response.message.text);
break;
case 'error':
context.splog.error(response.message.text);
break;
}
} catch (e) {
// silence any error - this shouldn't crash any part of the CLI
}
}

async function selectBranches(
context: TContext,
branchNames: string[]
Expand Down

0 comments on commit 9d4e1f5

Please sign in to comment.