10/7/2023 0 Comments Jump desktopOther languages use search-based code navigation, which searches all definitions and references across a repository to find entities with a given name. You can find all references for a function or method within the same repository by clicking the function or method call in a file.Ĭertain languages supported by GitHub have access to precise code navigation, which uses an algorithm (based on the open source stack-graphs library) that resolves definitions and references based on the set of classes, functions, and imported definitions that are visible at any given point in your code. You can jump to a function or method's definition within the same repository by clicking the function or method call in a file.įinding all references of a function or method Jumping to the definition of a function or method To exit the search for a specific symbol, click All Symbols. To navigate to a specific reference to a symbol, click a result of the symbol search under In this file. To navigate between references to a symbol, click or. To search for a symbol in all repositories on GitHub, click all repositories. To search for a symbol in the repository as a whole, in the symbols pane, click Search for this symbol in this repository.Clickable symbols are highlighted in yellow when you hover over them.Ĭlick the symbol you would like to find from the symbols pane or within the file itself. Īlternatively, you can open the symbols pane by clicking an eligible symbol in your file. To bring up the symbols pane, above the file content, click. Select a repository, then navigate to a file containing symbols. For more information, see " Understanding GitHub Code Search syntax." Symbol search is a feature of code search. You can search for a symbol in a single file, in all files in a repository, or even in all public repositories on GitHub. You can now quickly view and navigate between symbols such as functions or classes in your code with the symbols pane. For more information, see " Keyboard shortcuts." Using the symbols pane You can use keyboard shortcuts to navigate within a code file. To learn more about these approaches, see " Precise and search-based navigation."įuture releases will add precise code navigation for more languages, which is a code navigation approach that can give more accurate results. Precise - resolves definitions and references based on the set of classes, functions, and imported definitions at a given point in your code.Search-based - searches all definitions and references across a repository to find entities with a given name.GitHub has developed two code navigation approaches based on the open source tree-sitter and stack-graphs library: We will automatically extract search-based and precise code navigation information for these supported languages in all repositories and you can switch between the two supported code navigation approaches if your programming language is supported by both. You do not need to configure anything in your repository to enable code navigation.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |