Make AST Grep Rule Directories Configurable via Environment Variables#134
Closed
maks-ivanov wants to merge 1 commit intomainfrom
Closed
Make AST Grep Rule Directories Configurable via Environment Variables#134maks-ivanov wants to merge 1 commit intomainfrom
maks-ivanov wants to merge 1 commit intomainfrom
Conversation
Co-authored-by: Genie <genie@cosine.sh>
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.
This pull request modifies the AST Grep client to allow configuration of rule directories through environment variables. The default paths for symbol, identifier, and reference configuration files are retained, but users can now override these defaults by setting the respective environment variables:
AST_GREP_SYMBOL_CONFIG,AST_GREP_IDENTIFIER_CONFIG, andAST_GREP_REFERENCE_CONFIG.The changes include:
scan_filecalls to use the new functions instead of hardcoded paths.This enhancement is particularly useful for users running pre-built Docker images, as it provides flexibility in configuring the paths without modifying the code.
Original Task: lsproxy/1r5d2b2g6tma
Author: Maksim Ivanov