在GitHub代码搜索中转义字符 [英] Escaping characters in GitHub code search
问题描述
我正在尝试使用 Github的代码搜索来搜索包含诸如 =
, +
等。
I'm trying to use Github's code search to search for some lines of code containing characters like =
, +
, etc.
我从 https://help.github.com/articles/searching-code/#这些字符是通配符,必须进行转义,否则将被忽略。
I understand from https://help.github.com/articles/searching-code/#considerations-for-code-search that these characters are wildcards and have to be escaped, otherwise they will be ignored.
这里有一个例子:if \(done is True\),另一个:if(done is True)。您可以看到,两个返回相同的您的查询包含被忽略的字符警告在搜索栏的右侧。我的逃脱似乎没有做任何事情,我得到的结果是忽略的角色。
Here's an example: "if \(done is True\)", and another: "if (done is True)". As you can see, both return the same "your query contains a character that is ignored" warning on the right side of the search bar. My escaping doesn't seem to be doing anything, and the results I get are with the characters ignored.
我如何在这个搜索中转义字符?
How do I escape characters in this search?
推荐答案
我不认为你可以转义字符为github
I dont think you can escape characters for github
从搜索代码 doc:
您不能使用以下通配符作为搜索的一部分
查询:。 ,: / $ \\= *!?#$& + ^ |〜<>(){} [] 。
搜索将简单地忽略这些符号。
这篇关于在GitHub代码搜索中转义字符的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!