Searching code in a specific GitHub branch

前端 未结 3 1706
深忆病人
深忆病人 2021-02-03 16:22

I am trying to search some code in a branch in a GitHub repository.

However this indicates that I can only search the default branch.

Is there a way I can search c

3条回答
  •  清歌不尽
    2021-02-03 17:11

    Using console, I would search for specific code in a specific branch with the following

    git grep 'my_search_text' my_branch
    
    • my_branch should be available locally
    • git grep can perform pattern matching of high complexity (see the documentation)

提交回复
热议问题