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

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,554,344
Community Members
 
Community Events
184
Community Groups

How to search and copy files from 100 Repos into ONE Repo? (by searching keywords in filename)

There are 100+ Repos, want to scan, copy, and save those files (with keywords in filenames),  into ONE repo, please help!

1 answer

1 accepted

1 vote
Answer accepted
Aron Gombas _Midori_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
Apr 13, 2023

I think this question is not particularly specific to Bitbucket, but a general batch processing problem that includes working with a VCS a bit.

I would develop an external script (probably in Python) that would do something like this:

  1. Connect to the Bitbucket REST API and get all repositories
  2. Iterate over the repos and clone those one by one to the local filesystem
  3. (now you have a local copy of everything that you can process)
  4. Create a new empty repository "Result" through the Bitbucket REST API
  5. Also clone "Result" to the local filesystem
  6. Process the local files
    1. Match the keywords to the filename
    2. If it matches, copy the file to the result
  7. (now you have the result in the "result" local clone)
  8. "git push" the result

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events