SlideShare a Scribd company logo
1 of 15
Visit Bitbucket.org
Bitbucket.org can host
code repositories.

Public repositories are
free. Private
repositories are free if
sharing with up to 5
people.

Bitbucket uses
Mercurial (hg) as well
as git for version
control.

We will use Mercurial.
Log in as
gramener
Click on the “Log in”
link at the top to log in.

The username is
“gramener”.

The password can be
obtained from
s.anand@gramener.com
Start a project
If you’re starting a new
project, click on the
“create repository” link
on the top right.
Fill in the details
Type a project Name
Select Private
Choose Mercurial
Select Issue tracking
Select Wiki
Choose Language
Type a Description

Optionally, add a
Website
Visit the site
The repository is now
created.

It can be accessed at
https://bitbucket.org
/gramener/<name>

Currently, it contains
no data
Clone a project
First, install cygwin
with Mercural (hg)
selected.

Clone an existing or
newly created project
by typing on the
command prompt:

hg clone <project-url>

This may ask you for
your ID (gramener) and
your password.
Add files
Create or copy the
project files into the
cloned repository.

Here, I am copying files
I already created into
the repository.

You may use Windows
Explorer to copy, or
Notepad++ to create.
Any other tool is fine
as well.
Commit changes
hg status tells you the
status of each file.
Now, nothing’s
tracked.

hg add file tells hg you
want to commit file. It
has not yet committed

hg commit commits
only added files into
the local repository.
Bitbucket still doesn’t
know of this yet.
Push changes
hg push tells hg to
send the changes to
bitbucket.

Only at this point will
others be able to see
your change.

This means that you
can commit changes
offline, locally, and
push all your local
commits when you go
online.
Changes pushed
After hg push, you will
be able to see your
files on bitbucket.org
Email notification
You can receive a mail
when someone
commits a change.

In Admin, click on
Services, and choose
Email.

Type in your email ID
and Save settings.
Ignore files
If you want to ignore
specific files, create a
.hgignore file.

Type in a list of regular
expressions matching
the files to ignore.

abc$ matches all files
ending with abc. ($
stands for the end.)
Pull changes first
Before committing
files, first pull other
people’s changes into
your repository.

ALWAYS.

hg pull copies them
from bitbucket to the
local repository.
hg update copies from
local repository to your
folder.
YOU MUST RUN BOTH
Add / change files
hg add any new files to
the repository.

hg commit any existing
or newly added files to
the local repository.

Make sure you type a
descriptive message
with –m"…"

hg push committed
changes to bitbucket.
View differences
On bitbucket, you can
browse and see the
exact lines that were
changed in every
commit.

More Related Content

Similar to Using Bitbucket and Mercurial

BSADD-Git-TRAINING
BSADD-Git-TRAININGBSADD-Git-TRAINING
BSADD-Git-TRAINING
bsadd
 
introductiontogitandgithub-120702044048-phpapp01.pdf
introductiontogitandgithub-120702044048-phpapp01.pdfintroductiontogitandgithub-120702044048-phpapp01.pdf
introductiontogitandgithub-120702044048-phpapp01.pdf
BruceLee275640
 

Similar to Using Bitbucket and Mercurial (20)

Git Hub Platform
Git Hub PlatformGit Hub Platform
Git Hub Platform
 
Git & GitLab
Git & GitLabGit & GitLab
Git & GitLab
 
16 Git
16 Git16 Git
16 Git
 
GitHub Basics - Derek Bable
GitHub Basics - Derek BableGitHub Basics - Derek Bable
GitHub Basics - Derek Bable
 
BSADD-Git-TRAINING
BSADD-Git-TRAININGBSADD-Git-TRAINING
BSADD-Git-TRAINING
 
Bsadd training-git
Bsadd training-gitBsadd training-git
Bsadd training-git
 
Intro to Git, GitHub, and BitBucket
Intro to Git, GitHub, and BitBucketIntro to Git, GitHub, and BitBucket
Intro to Git, GitHub, and BitBucket
 
Git Tutorials Git vs GitHub.pptx
Git Tutorials Git vs GitHub.pptxGit Tutorials Git vs GitHub.pptx
Git Tutorials Git vs GitHub.pptx
 
Git and Github.pptx
Git and Github.pptxGit and Github.pptx
Git and Github.pptx
 
Legal Analytics Course - Class #4 - Github and RMarkdown Tutorial - Professor...
Legal Analytics Course - Class #4 - Github and RMarkdown Tutorial - Professor...Legal Analytics Course - Class #4 - Github and RMarkdown Tutorial - Professor...
Legal Analytics Course - Class #4 - Github and RMarkdown Tutorial - Professor...
 
introductiontogitandgithub-120702044048-phpapp01.pdf
introductiontogitandgithub-120702044048-phpapp01.pdfintroductiontogitandgithub-120702044048-phpapp01.pdf
introductiontogitandgithub-120702044048-phpapp01.pdf
 
Git/GitHub
Git/GitHubGit/GitHub
Git/GitHub
 
Introduction to Git and GitHub Part 1
Introduction to Git and GitHub Part 1Introduction to Git and GitHub Part 1
Introduction to Git and GitHub Part 1
 
Git & Github Workshop - Le Wagon Melbourne
Git & Github Workshop - Le Wagon MelbourneGit & Github Workshop - Le Wagon Melbourne
Git & Github Workshop - Le Wagon Melbourne
 
Introduction to git and github
Introduction to git and githubIntroduction to git and github
Introduction to git and github
 
Brief tutorial on Git
Brief tutorial on GitBrief tutorial on Git
Brief tutorial on Git
 
Git and git hub basics
Git and git hub basicsGit and git hub basics
Git and git hub basics
 
Overview of github
Overview of githubOverview of github
Overview of github
 
A Tutorial for GitHub.pdf
A Tutorial for GitHub.pdfA Tutorial for GitHub.pdf
A Tutorial for GitHub.pdf
 
A Tutorial for GitHub.pdf
A Tutorial for GitHub.pdfA Tutorial for GitHub.pdf
A Tutorial for GitHub.pdf
 

More from Gramener

More from Gramener (20)

6 Methods to Improve Your Manufacturing Process with Computer Vision
6 Methods to Improve Your Manufacturing Process with Computer Vision6 Methods to Improve Your Manufacturing Process with Computer Vision
6 Methods to Improve Your Manufacturing Process with Computer Vision
 
Detecting Manufacturing Defects with Computer Vision
Detecting Manufacturing Defects with Computer VisionDetecting Manufacturing Defects with Computer Vision
Detecting Manufacturing Defects with Computer Vision
 
How to Identify the Right Key Opinion Leaders (KOLs) in Pharma & Healthcare
How to Identify the Right Key Opinion Leaders (KOLs) in Pharma  & HealthcareHow to Identify the Right Key Opinion Leaders (KOLs) in Pharma  & Healthcare
How to Identify the Right Key Opinion Leaders (KOLs) in Pharma & Healthcare
 
Automated Barcode Generation System in Manufacturing
Automated Barcode Generation System in ManufacturingAutomated Barcode Generation System in Manufacturing
Automated Barcode Generation System in Manufacturing
 
The Role of Technology to Save Biodiversity
The Role of Technology to Save BiodiversityThe Role of Technology to Save Biodiversity
The Role of Technology to Save Biodiversity
 
Enable Storytelling with Power BI & Comicgen Plugin
Enable Storytelling with Power BI  & Comicgen PluginEnable Storytelling with Power BI  & Comicgen Plugin
Enable Storytelling with Power BI & Comicgen Plugin
 
The Most Effective Method For Selecting Data Science Projects
The Most Effective Method For Selecting Data Science ProjectsThe Most Effective Method For Selecting Data Science Projects
The Most Effective Method For Selecting Data Science Projects
 
Low Code Platform To Build Data & AI Products
Low Code Platform To Build Data & AI ProductsLow Code Platform To Build Data & AI Products
Low Code Platform To Build Data & AI Products
 
5 Key Foundations To Build An Effective CX Program
5 Key Foundations To Build An Effective CX Program5 Key Foundations To Build An Effective CX Program
5 Key Foundations To Build An Effective CX Program
 
Using Power BI To Improve Media Buying & Ad Performance
Using Power BI To Improve Media Buying & Ad PerformanceUsing Power BI To Improve Media Buying & Ad Performance
Using Power BI To Improve Media Buying & Ad Performance
 
Recession Proofing With Data : Webinar
Recession Proofing With Data : WebinarRecession Proofing With Data : Webinar
Recession Proofing With Data : Webinar
 
Engage Your Audience With PowerPoint Decks: Webinar
Engage Your Audience With PowerPoint Decks: WebinarEngage Your Audience With PowerPoint Decks: Webinar
Engage Your Audience With PowerPoint Decks: Webinar
 
Structure Your Data Science Teams For Best Outcomes
Structure Your Data Science Teams For Best OutcomesStructure Your Data Science Teams For Best Outcomes
Structure Your Data Science Teams For Best Outcomes
 
Dawn Of Geospatial AI - Webinar
Dawn Of Geospatial AI - WebinarDawn Of Geospatial AI - Webinar
Dawn Of Geospatial AI - Webinar
 
5 Steps To Become A Data-Driven Organization : Webinar
5 Steps To Become A Data-Driven Organization : Webinar5 Steps To Become A Data-Driven Organization : Webinar
5 Steps To Become A Data-Driven Organization : Webinar
 
5 Steps To Measure ROI On Your Data Science Initiatives - Webinar
 5 Steps To Measure ROI On Your Data Science Initiatives - Webinar 5 Steps To Measure ROI On Your Data Science Initiatives - Webinar
5 Steps To Measure ROI On Your Data Science Initiatives - Webinar
 
Saving Lives with Geospatial AI - Pycon Indonesia 2020
Saving Lives with Geospatial AI - Pycon Indonesia 2020Saving Lives with Geospatial AI - Pycon Indonesia 2020
Saving Lives with Geospatial AI - Pycon Indonesia 2020
 
Driving Transformation in Industries with Artificial Intelligence (AI)
Driving Transformation in Industries with Artificial Intelligence (AI)Driving Transformation in Industries with Artificial Intelligence (AI)
Driving Transformation in Industries with Artificial Intelligence (AI)
 
The Art of Storytelling Using Data Science
The Art of Storytelling Using Data ScienceThe Art of Storytelling Using Data Science
The Art of Storytelling Using Data Science
 
Storyfying your Data: How to go from Data to Insights to Stories
Storyfying your Data: How to go from Data to Insights to StoriesStoryfying your Data: How to go from Data to Insights to Stories
Storyfying your Data: How to go from Data to Insights to Stories
 

Recently uploaded

Recently uploaded (20)

Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 

Using Bitbucket and Mercurial

  • 1. Visit Bitbucket.org Bitbucket.org can host code repositories. Public repositories are free. Private repositories are free if sharing with up to 5 people. Bitbucket uses Mercurial (hg) as well as git for version control. We will use Mercurial.
  • 2. Log in as gramener Click on the “Log in” link at the top to log in. The username is “gramener”. The password can be obtained from s.anand@gramener.com
  • 3. Start a project If you’re starting a new project, click on the “create repository” link on the top right.
  • 4. Fill in the details Type a project Name Select Private Choose Mercurial Select Issue tracking Select Wiki Choose Language Type a Description Optionally, add a Website
  • 5. Visit the site The repository is now created. It can be accessed at https://bitbucket.org /gramener/<name> Currently, it contains no data
  • 6. Clone a project First, install cygwin with Mercural (hg) selected. Clone an existing or newly created project by typing on the command prompt: hg clone <project-url> This may ask you for your ID (gramener) and your password.
  • 7. Add files Create or copy the project files into the cloned repository. Here, I am copying files I already created into the repository. You may use Windows Explorer to copy, or Notepad++ to create. Any other tool is fine as well.
  • 8. Commit changes hg status tells you the status of each file. Now, nothing’s tracked. hg add file tells hg you want to commit file. It has not yet committed hg commit commits only added files into the local repository. Bitbucket still doesn’t know of this yet.
  • 9. Push changes hg push tells hg to send the changes to bitbucket. Only at this point will others be able to see your change. This means that you can commit changes offline, locally, and push all your local commits when you go online.
  • 10. Changes pushed After hg push, you will be able to see your files on bitbucket.org
  • 11. Email notification You can receive a mail when someone commits a change. In Admin, click on Services, and choose Email. Type in your email ID and Save settings.
  • 12. Ignore files If you want to ignore specific files, create a .hgignore file. Type in a list of regular expressions matching the files to ignore. abc$ matches all files ending with abc. ($ stands for the end.)
  • 13. Pull changes first Before committing files, first pull other people’s changes into your repository. ALWAYS. hg pull copies them from bitbucket to the local repository. hg update copies from local repository to your folder. YOU MUST RUN BOTH
  • 14. Add / change files hg add any new files to the repository. hg commit any existing or newly added files to the local repository. Make sure you type a descriptive message with –m"…" hg push committed changes to bitbucket.
  • 15. View differences On bitbucket, you can browse and see the exact lines that were changed in every commit.