当使用emacs Projectile和helm-projectile时,我习惯在整个项目中搜索文本 . 但有没有办法只搜索项目的一部分?
就像是:
仅在子文件夹中搜索
搜索时排除子文件夹
是的你可以exclude (sub) folders . 在 .projectile 中添加一行:
.projectile
-/sub/folder
因此,在子文件夹中搜索,我看不到自动的东西 . 您可以将项目文件放在某些子文件夹(https://projectile.readthedocs.io/en/latest/configuration/#file-local-project-root-definitions)和switch projects中 .
现在我正在使用 rgrep ,它会提示输入字符串和目录 .
rgrep
我很高兴听到使用 ag 的等效解决方案,我应该提到我还没有从@goromlagche(https://github.com/ggreer/the_silver_searcher#emacs)挖掘链接 .
ag
2 回答
是的你可以exclude (sub) folders . 在
.projectile
中添加一行:因此,在子文件夹中搜索,我看不到自动的东西 . 您可以将项目文件放在某些子文件夹(https://projectile.readthedocs.io/en/latest/configuration/#file-local-project-root-definitions)和switch projects中 .
现在我正在使用
rgrep
,它会提示输入字符串和目录 .我很高兴听到使用
ag
的等效解决方案,我应该提到我还没有从@goromlagche(https://github.com/ggreer/the_silver_searcher#emacs)挖掘链接 .