Rmate for remote editing
Rmate is a powerful plugin in VSCode for remote editing. We can edit files on remote server directly.
- F1 then select
remote: start server
- In VSCode integrated terminal:
ssh -R 52698:localhost:52698 username@server_address -p server_port
cdto the folder on server, open the file with
Mercurial for version control
Mercurial is very similar to Git.
hg diff -r changeset1..changeset2
hg log -G: graph view
hg add .
hg commit -m 'my description'
hg update _identifier(changeset)_: navigate through different versions of repo
Reconsiling the forks
Two ways to combine the two changes into one.
hg rebase: update the base commit of your local commit from wherever you cloned onto their change. https://www.mercurial-scm.org/wiki/RebaseExtension
hg rebase -s X -d E, X is the base of a fork, E is the new base.
hg rebase -r Y3::Z3 -d E --collapse, collapse Y3 and Z3 into one commit, put it after E.
hg rebase --abortwill abort
hg rebase --continuewill continue
hg push: merge two commits together.
hg merge: http://hgbook.red-bean.com/read/a-tour-of-mercurial-merging-work.html
hg merge -r changeset1, merge two branches
- Then commit