fix(ccs): resolve default profile shift error when no args provided

- add conditional check before shift command

- prevent failure when calling 'ccs' without arguments

- named profiles (ccs son, ccs glm) still work correctly
This commit is contained in:
kaitranntt committed 2025-11-01 18:51:24 -04:00
1 parent 08d8c1f21c
commit 84f4548dcb
1 file changed
+4 -2
+4 -2
View File
@@ -65,8 +65,10 @@ if [[ ! -f "$SETTINGS_PATH" ]]; then
exit 1
fi
# Shift profile arg, pass rest to claude
shift
# Shift profile arg if it was provided, pass rest to claude
if [[ $# -gt 0 ]]; then
shift
fi
# Execute claude with settings
exec claude --settings "$SETTINGS_PATH" "$@"