shipthis
Version:
ShipThis manages building and uploading your Godot games to the App Store and Google Play.
81 lines (78 loc) • 2.42 kB
JavaScript
import { jsxs, jsx } from 'react/jsx-runtime';
import { render } from 'ink';
import { B as BaseAuthenticatedCommand } from '../../baseGameCommand-8VL7xe-O.js';
import 'node:fs';
import 'node:path';
import 'chalk';
import '@oclif/core';
import 'axios';
import 'crypto-js';
import 'uuid';
import '../../baseCommand-CTn3KGH3.js';
import 'luxon';
import 'node:crypto';
import 'node:readline';
import 'node:url';
import 'readline-sync';
import 'isomorphic-git';
import '@tanstack/react-query';
import 'react';
import 'fast-glob';
import 'yazl';
import 'socket.io-client';
import 'fullscreen-ink';
import 'ink-spinner';
import 'string-length';
import 'strip-ansi';
import { S as StatusTable } from '../../StatusTable-DzRWcMr4.js';
import 'open';
import '@inkjs/ui';
import 'marked';
import 'marked-terminal';
import { N as NextSteps } from '../../NextSteps-DbJHmscQ.js';
import 'qrcode';
import { C as Command } from '../../Command-Cj6F5B5a.js';
import 'fs';
import 'path';
import '@expo/apple-utils/build/index.js';
import 'deepmerge';
import 'ini';
import '../../Title-BCQtayg6.js';
class AppleStatus extends BaseAuthenticatedCommand {
static args = {};
static description = "Shows the status of the Apple authentication and integration.";
static examples = ["<%= config.bin %> <%= command.id %>"];
static flags = {};
async run() {
const checkAuth = async () => {
try {
const authState = await this.refreshAppleAuthState();
const { session: session2 } = authState;
return {
isAuthenticatedOnApple: true,
session: session2
};
} catch {
return {
isAuthenticatedOnApple: false,
session: null
};
}
};
const { isAuthenticatedOnApple, session } = await checkAuth();
const statuses = {
"Apple Full Name": session?.user?.fullName || "Please authenticate",
"Apple Provider Name": session?.provider?.name || "Please authenticate",
"Authenticated on Apple Developer Portal": isAuthenticatedOnApple
};
const steps = [];
if (!isAuthenticatedOnApple) steps.push("shipthis apple login");
render(
/* @__PURE__ */ jsxs(Command, { command: this, children: [
/* @__PURE__ */ jsx(StatusTable, { marginBottom: 1, statuses, title: "Apple Status" }),
/* @__PURE__ */ jsx(NextSteps, { steps })
] })
);
}
}
export { AppleStatus as default };