Repository navigation
Fix CQL names that were colored as keywords or commands - #214
Open
eric-schneider wants to merge 1 commit into
Open
eric-schneider wants to merge 1 commit into
eric-schneider wants to merge 1 commit into
Conversation
Match dist/cql.cjs from highlightjs-cql's commit "Fix names colored as keywords or commands", which fixes names that were colored as keywords or commands: - Columns named like cqlsh commands (consistency, source, copy) in statements that span lines, such as the audit log's DESC TABLE output. - A role named role after TO, and the new name in RENAME ... TO. - DSE search index schema paths (SET field[@name='x']), the field after ADD FIELD or DROP FIELD, and dotted paths such as config.queryExecutorThreads. lowerCaseString in ADD lowerCaseString is now colored as a keyword.
Contributor
|
UI bundle preview build successful! ✅ |
|
Build successful! ✅ |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Updates the vendored CQL grammar to the latest highlightjs-cql. A review of the DataStax Enterprise examples, and of examples that span several lines, found names colored as keywords or as cqlsh commands:
consistency,source, orcopy. These were colored as cqlsh commands, and their types lost their color.TO. A role calledrole(GRANT ... TO role) and the new name inRENAME ... TOare now names.field[@name='x']paths, the field name afterADD FIELDorDROP FIELD, and dotted settings such asconfig.queryExecutorThreadsare now names.lowerCaseStringinADD lowerCaseStringis now colored as a keyword, as the DSE docs describe it.How to review
Compare these pages on the draft docs site with production:
audit_logschema,consistencyandsourcelook like the other columns, and theirtexttypes are colored.DROP field comment,commentisn't a keyword.SET field[@name='_partitionKey'],fieldisn't a keyword.config.queryExecutorThreadsis one name.lowerCaseStringis a keyword.GRANT ALL ON REMOTE OBJECT DseResourceManager TO roleand theDseClientToolexample after it,roleisn't a keyword.