You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: replace individual UI flags with unified --custom-strings flag
Replace non-scalable individual flags (--login-title, --login-below, etc.)
with a unified --custom-strings flag that accepts JSON file paths or inline
JSON for UI customization. This leverages the existing i18n system for
better scalability and maintainability.
Changes:
- Add --custom-strings flag with JSON validation
- Extend i18n system to merge custom strings with defaults
- Remove newly-added individual login/UI flags
- Deprecate legacy --app-name and --welcome-text flags
- Update login route to use unified i18n system
- Add comprehensive tests for new functionality
- Update documentation with migration guide and examples
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <[email protected]>
docker run -it --name code-server -p 127.0.0.1:8080:8080 \
112
87
-v "$PWD:/home/coder/project" \
113
-
-e "CS_APP_NAME=ACME Corporation Dev Portal" \
114
-
-e "CS_LOGIN_TITLE=ACME Development Portal" \
115
-
-e "CS_LOGIN_BELOW=Enter your corporate credentials" \
116
-
-e "CS_PASSWORD_PLACEHOLDER=Corporate Password" \
117
-
-e "CS_SUBMIT_TEXT=SIGN IN" \
118
-
-e "CS_LOGIN_ENV_PASSWORD_MSG=Password managed by IT department" \
119
-
codercom/code-server:latest
88
+
codercom/code-server:latest --custom-strings '{
89
+
"WELCOME": "Welcome to ACME Corporation Development Portal",
90
+
"LOGIN_TITLE": "ACME Dev Portal Access",
91
+
"LOGIN_BELOW": "Enter your corporate credentials",
92
+
"PASSWORD_PLACEHOLDER": "Corporate Password",
93
+
"SUBMIT": "SIGN IN",
94
+
"LOGIN_USING_ENV_PASSWORD": "Password managed by IT department"
95
+
}'
96
+
```
97
+
98
+
## Legacy Support (Deprecated)
99
+
100
+
The following individual flags are still supported but deprecated. Use `--custom-strings` for new deployments:
101
+
102
+
```bash
103
+
# Deprecated - use --custom-strings instead
104
+
code-server \
105
+
--app-name "My Development Server" \
106
+
--welcome-text "Welcome to the development environment"
107
+
```
108
+
109
+
These legacy flags will show deprecation warnings and may be removed in future versions.
110
+
111
+
## Migration Guide
112
+
113
+
### From Individual Flags to Custom Strings
114
+
115
+
**Old approach:**
116
+
```bash
117
+
code-server \
118
+
--app-name "Dev Portal" \
119
+
--welcome-text "Welcome to development" \
120
+
--login-title "Portal Access"
121
+
```
122
+
123
+
**New approach:**
124
+
```bash
125
+
code-server --custom-strings '{
126
+
"WELCOME": "Welcome to development",
127
+
"LOGIN_TITLE": "Portal Access"
128
+
}'
129
+
```
130
+
131
+
**Note:** The `--app-name` flag controls the `{{app}}` placeholder in templates. Use it alongside `--custom-strings` or customize the full text without placeholders.
0 commit comments