Skip to content

Commit

Permalink
[patch] Simplify workspace name restrictions (#409)
Browse files Browse the repository at this point in the history
  • Loading branch information
durera authored Aug 11, 2023
1 parent 47fdca4 commit 3a0f594
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
2 changes: 0 additions & 2 deletions docs/commands/install.md
Original file line number Diff line number Diff line change
Expand Up @@ -161,8 +161,6 @@ Provide the basic information about your MAS instance:
Workspace display name restrictions:

- Must be 3-300 characters long
- Only the space (` `) whitespace character may be used
- Must not start or end with a whitespace character

### Step 6: Configure Operation Mode
The install will default to a production mode installation, but by choosing "y" at the prompt you will be able to install MAS in non-production mode.
Expand Down
6 changes: 2 additions & 4 deletions image/cli/mascli/functions/pipeline_config
Original file line number Diff line number Diff line change
Expand Up @@ -110,14 +110,12 @@ function pipeline_config() {
fi
echo

# Workspace display name regex: ^[^\ \t\n\r\f\v][^\t\n\r\f\v]{1,298}[^\ \t\n\r\f\v]$
# Workspace display name regex: ^.{3,300}$
echo "${TEXT_DIM}Workspace display name restrictions:"
echo " - Must be 3-300 characters long"
echo " - Only the space ( ) whitespace character may be used"
echo " - Must not start or end with a whitespace character"
reset_colors
prompt_for_input "MAS Workspace Display Name" MAS_WORKSPACE_NAME
if [[ ! "${MAS_WORKSPACE_NAME}" =~ ^[^\ \t\n\r\f\v][^\t\n\r\f\v]{1,298}[^\ \t\n\r\f\v]$ ]]; then
if [[ ! "${MAS_WORKSPACE_NAME}" =~ ^.{3,300}$ ]]; then
echo_warning "Workspace name (${MAS_WORKSPACE_NAME}) does not meet requirements"
exit 1
fi
Expand Down

0 comments on commit 3a0f594

Please sign in to comment.