import{a as e,n as t,r as n}from"./chunk-DR8-3Aex.js";import{n as r,t as i}from"./memoize-DNnuA2aU.js";import{homedir as a}from"os";import{join as o}from"path";var s=n({checkProtectedNamespace:()=>c}),c,l=t((()=>{c=()=>!1}));function u(){return o(S(),`teams`)}function d(e){let t=process.env.NODE_OPTIONS;return t?t.split(/\s+/).includes(e):!1}function f(e){if(!e)return!1;if(typeof e==`boolean`)return e;let t=e.toLowerCase().trim();return[`1`,`true`,`yes`,`on`].includes(t)}function p(e){if(e===void 0)return!1;if(typeof e==`boolean`)return!e;if(!e)return!1;let t=e.toLowerCase().trim();return[`0`,`false`,`no`,`off`].includes(t)}function m(){return f(process.env.CLAUDE_CODE_SIMPLE)||process.argv.includes(`--bare`)}function h(e){let t={};if(e)for(let n of e){let[e,...r]=n.split(`=`);if(!e||r.length===0)throw Error(`Invalid environment variable format: ${n}, environment variables should be added as: -e KEY1=value1 -e KEY2=value2`);t[e]=r.join(`=`)}return t}function g(){return process.env.AWS_REGION||process.env.AWS_DEFAULT_REGION||`us-east-1`}function _(){return process.env.CLOUD_ML_REGION||`us-east5`}function v(){return f(process.env.CLAUDE_BASH_MAINTAIN_PROJECT_WORKING_DIR)}function y(){return process.env.USER_TYPE===`ant`&&f(process.env.COO_RUNNING_ON_HOMESPACE)}function b(){return process.env.USER_TYPE===`ant`?(l(),e(s)).checkProtectedNamespace():!1}function x(e){if(e){let t=C.find(([t])=>e.startsWith(t));if(t)return process.env[t[1]]||_()}return _()}var S,C,w=t((()=>{i(),S=r(()=>(process.env.CLAUDE_CONFIG_DIR??o(a(),`.claude`)).normalize(`NFC`),()=>process.env.CLAUDE_CONFIG_DIR),C=[[`claude-haiku-4-5`,`VERTEX_REGION_CLAUDE_HAIKU_4_5`],[`claude-3-5-haiku`,`VERTEX_REGION_CLAUDE_3_5_HAIKU`],[`claude-3-5-sonnet`,`VERTEX_REGION_CLAUDE_3_5_SONNET`],[`claude-3-7-sonnet`,`VERTEX_REGION_CLAUDE_3_7_SONNET`],[`claude-opus-4-1`,`VERTEX_REGION_CLAUDE_4_1_OPUS`],[`claude-opus-4`,`VERTEX_REGION_CLAUDE_4_0_OPUS`],[`claude-sonnet-4-6`,`VERTEX_REGION_CLAUDE_4_6_SONNET`],[`claude-sonnet-4-5`,`VERTEX_REGION_CLAUDE_4_5_SONNET`],[`claude-sonnet-4`,`VERTEX_REGION_CLAUDE_4_0_SONNET`]]}));export{x as a,m as c,b as d,y as f,u as i,p as l,v as m,S as n,d as o,h as p,_ as r,w as s,g as t,f as u};