Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Searching for file/folder names, and keyword in files

gil August 21, 2023

Currently I can search for file/folder name, and file content in Bitbucket Cloud.  However, there's limit in size of file content for searching.  We need to be able to search for all content.  What's the workaround for this?  Any other tools I can use to have this feature in place?  Thanks.

1 answer

0 votes
Patrik S
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 22, 2023

Hello @gil and thank you for reaching out to the Community!

As you correctly stated, there are some considerations to take into account when using Bitbucket Cloud Code search, and one of them is that only files smaller than 320 KB get indexed. This is to grant the performance and stability of the platform to all the users.

In case you need to search content from larger files, a possible workaround would be to clone the repository locally and perform the search using the git grep command. The following git grep example will return the names and line number of all the files in master branch that contains the word "hello" :

git grep -n hello master

You can explore the different flags and arguments of git grep command on its official documentation.

Also, I found this article that contains multiple examples of using git grep to search files in the repository that may also be useful : 

Hope that helps! Let me know in case you have any questions. 

Thank you, @gil !

Patrik S

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PERMISSIONS LEVEL
Site Admin
TAGS
AUG Leaders

Atlassian Community Events