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

How can i create a directory?

Vukasin Filipovic March 11, 2024

I don't really understand how to create a directory, because when I want to add, it only offers me filesHvataj.PNG

2 answers

2 accepted

1 vote
Answer accepted
Theodora Boudale
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
March 13, 2024

Hi @Vukasin Filipovic and welcome to the community!

You cannot create a directory only. As Mikael said, Git will not commit an empty directory.

However, if you want to add a directory and then a file in this directory, this is possible also from Bitbucket UI:

1. Select the Add file option from your screenshot

2. In the field where you enter the file name, enter the name of the directory, e.g. myDir:

Screenshot 2024-03-13 at 13.36.34.png

3. Then add a slash /

As soon as you do that, you will see that a directory with that name gets created:

Screenshot 2024-03-13 at 13.36.42.png

You can then enter the file name and the content of the file and commit it.

Please feel free to reach out if you have any questions.

Kind regards,
Theodora

Vukasin Filipovic March 13, 2024

Thank you very much, I have successfully created the directory c:

Theodora Boudale
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
March 13, 2024

That's good to hear, you are very welcome!

Please feel free to reach out if you ever need anything else!

1 vote
Answer accepted
Mikael Sandberg
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
March 11, 2024

Hi @Vukasin Filipovic,

Welcome to Atlassian Community!

You will have to clone your repository and then create the directory and files on your client and then push it back to Bitbucket.

Note that you cannot create empty directories in a repository, Git do not include them in a commit. So if you need an empty folder you would have to add a file to it as well in order for Git to include it in the commit/push.  

Vukasin Filipovic March 13, 2024

Thank you very much, I have successfully created the directory c:

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
TAGS
AUG Leaders

Atlassian Community Events