-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathset_claude_backend
More file actions
executable file
·44 lines (39 loc) · 1.11 KB
/
set_claude_backend
File metadata and controls
executable file
·44 lines (39 loc) · 1.11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#!/bin/bash
function print_help {
echo "usage: "
echo 'set_claude_backend <backend (claude|zai)>'
}
while [ $# -gt 0 ]; do
case "$1" in
--help)
print_help;
exit 0
;;
--backend)
BACKEND=$2
shift 2
;;
*)
BACKEND=$1
shift
;;
esac
done
if [ $BACKEND == 'zai' ]; then
echo "
if you don't get an ANTHROPIC_AUTH_TOKEN in the following output, you probably have not created $HOME/.claude_code_secret_zai_env_vars, which should export that variable.
------"
cat $HOME/.claude_code_secret_zai_env_vars
echo " export ANTHROPIC_BASE_URL="https://api.z.ai/api/anthropic"
export API_TIMEOUT_MS="3000000"
export ANTHROPIC_DEFAULT_HAIKU_MODEL="glm-4.5-air"
export ANTHROPIC_DEFAULT_SONNET_MODEL="glm-4.6"
export ANTHROPIC_DEFAULT_OPUS_MODEL="glm-4.6"
-----
"
elif [ $BACKEND == 'claude' ]; then
echo "cp ~/.claude/settings.claude.json ~/.claude/settings.json"
#cp ~/.claude/settings.claude.json ~/.claude/settings.json
else
echo "you did not select a backend... please specify 'claude' or 'zai' "
fi