Commands

1️⃣ Before Changes

hg st

status. Same as git status it seems.

Output meaning - link

hg pull

The same as git fetch. Gets latest info from remote.

hg up

Sort of equivalent to git pull. Pulls remote changes into your local repo.

Also is equivalent of git checkout, used for switching branches.

<aside> 💡 Can also also use it to remove uncommitted local changes: hg up -C (short for --clean).

</aside>

↩️ Undoing Changes

hg revert --all

The stuff. Undoes uncommitted changes. Link 👌

(SXO-815-improve-visibility-of-mtm ~1)> hg revert --all
reverting packages\\frend\\web\\client\\src\\app\\shell\\layout\\header\\main-nav\\main-nav.component.ts
(SXO-815-improve-visibility-of-mtm)>

hg purge

Removes un-tracked files.

# 4 Untracked files
(KAJ-31-mao---new-offers-api-endpoint ?4)> hg purge

# All gone!
(KAJ-31-mao---new-offers-api-endpoint)>

Can also be used to remove .orig files that get left behind after file conflicts are resolved. S/O answer.