Commit fde42e5
Add \c mattermost step to PostgreSQL preparation grants (#8920)
* Add \c mattermost step to PostgreSQL preparation grants
The ALTER SCHEMA public and GRANT USAGE, CREATE ON SCHEMA public
commands operate on the current database's public schema, so users
must connect to the mattermost database before running them.
Without \c mattermost, these grants are applied to the wrong
database's public schema.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* Add comment explaining the \c mattermost step
Clarifies that the connection switch is what makes the subsequent
ALTER SCHEMA and GRANT commands target the mattermost database's
public schema.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* Switch code-block to postgresql to handle \c cleanly
The generic sql lexer flags \c as an unknown token (red error box
in rendered output). The postgresql lexer recognizes psql
meta-commands like \c as builtins, so the block renders cleanly
while still highlighting the SQL statements.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* Use text lexer to avoid Pygments error token on \c
Both the sql and postgresql Pygments lexers flag backslash-prefixed
psql meta-commands as error tokens (rendered as a red box). Switch
to the text lexer so the block renders cleanly. Loses SQL syntax
highlighting on four lines, but keeps the commands as a single
copy-pasteable unit.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 67012b5 commit fde42e5
1 file changed
Lines changed: 3 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
62 | | - | |
| 62 | + | |
63 | 63 | | |
64 | 64 | | |
| 65 | + | |
| 66 | + | |
65 | 67 | | |
66 | 68 | | |
67 | 69 | | |
| |||
0 commit comments