You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

44 lines
2.6 KiB

5 years ago
  1. **Edit a file, create a new file, and clone from Bitbucket in under 2 minutes**
  2. When you're done, you can delete the content in this README and update the file with details for others getting started with your repository.
  3. *We recommend that you open this README in another tab as you perform the tasks below. You can [watch our video](https://youtu.be/0ocf7u76WSo) for a full demo of all the steps in this tutorial. Open the video in a new tab to avoid leaving Bitbucket.*
  4. ---
  5. ## Edit a file
  6. You’ll start by editing this README file to learn how to edit a file in Bitbucket.
  7. 1. Click **Source** on the left side.
  8. 2. Click the README.md link from the list of files.
  9. 3. Click the **Edit** button.
  10. 4. Delete the following text: *Delete this line to make a change to the README from Bitbucket.*
  11. 5. After making your change, click **Commit** and then **Commit** again in the dialog. The commit page will open and you’ll see the change you just made.
  12. 6. Go back to the **Source** page.
  13. ---
  14. ## Create a file
  15. Next, you’ll add a new file to this repository.
  16. 1. Click the **New file** button at the top of the **Source** page.
  17. 2. Give the file a filename of **contributors.txt**.
  18. 3. Enter your name in the empty file space.
  19. 4. Click **Commit** and then **Commit** again in the dialog.
  20. 5. Go back to the **Source** page.
  21. Before you move on, go ahead and explore the repository. You've already seen the **Source** page, but check out the **Commits**, **Branches**, and **Settings** pages.
  22. ---
  23. ## Clone a repository
  24. Use these steps to clone from SourceTree, our client for using the repository command-line free. Cloning allows you to work on your files locally. If you don't yet have SourceTree, [download and install first](https://www.sourcetreeapp.com/). If you prefer to clone from the command line, see [Clone a repository](https://confluence.atlassian.com/x/4whODQ).
  25. 1. You’ll see the clone button under the **Source** heading. Click that button.
  26. 2. Now click **Check out in SourceTree**. You may need to create a SourceTree account or log in.
  27. 3. When you see the **Clone New** dialog in SourceTree, update the destination path and name if you’d like to and then click **Clone**.
  28. 4. Open the directory you just created to see your repository’s files.
  29. Now that you're more familiar with your Bitbucket repository, go ahead and add a new file locally. You can [push your change back to Bitbucket with SourceTree](https://confluence.atlassian.com/x/iqyBMg), or you can [add, commit,](https://confluence.atlassian.com/x/8QhODQ) and [push from the command line](https://confluence.atlassian.com/x/NQ0zDQ).