Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions packages/app/src/cli/api/graphql/admin/generated/types.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -214,10 +214,6 @@ export type MetaobjectAdminAccess =
| 'MERCHANT_READ'
/** The merchant has read and write access. No other apps have access. */
| 'MERCHANT_READ_WRITE'
/** The merchant and other apps have no access. */
| 'PRIVATE'
/** The merchant and other apps have read-only access. */
| 'PUBLIC_READ'
/** The merchant and other apps have read and write access. */
| 'PUBLIC_READ_WRITE';

Expand Down
15 changes: 7 additions & 8 deletions packages/cli-kit/src/public/node/os.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,12 @@ export async function username(platform: typeof process.platform = process.platf

type PlatformArch = Exclude<typeof process.arch, 'x64' | 'ia32'> | 'amd64' | '386'
type PlatformStrings = Exclude<typeof process.platform, 'win32'> | 'windows'

const ARCH_MAP: Record<string, PlatformArch> = {
x64: 'amd64',
ia32: '386',
}

/**
* Returns the platform and architecture.
* @returns Returns the current platform and architecture.
Expand All @@ -57,14 +63,7 @@ export function platformAndArch(
platform: PlatformStrings
arch: PlatformArch
} {
let archString: PlatformArch
if (arch === 'x64') {
archString = 'amd64'
} else if (arch === 'ia32') {
archString = '386'
} else {
archString = arch
}
const archString = (ARCH_MAP[arch] ?? arch) as PlatformArch
const platformString = (platform.match(/^win.+/) ? 'windows' : platform) as PlatformStrings
return {platform: platformString, arch: archString}
}
Expand Down
Loading