Working with stacked commits in GitHub with Sapling

submited by
Style Pass
2024-04-26 14:00:06

It’s a fork of Mercurial, built internally at Meta. As I’ve been at Meta for over 10 years, I got used to using Mercurial. The ability of working with stacked commits has changed the way I write code, and expect others to write code. It helps break down a large feature into smaller chunks of code which are easier to write, review and test.

I wanted to try how this looks using the public version of Sapling, so I gave it a go: I created a new repo: https://github.com/bugok/sapling-test. I cloned the repo by sl clone https://github.com/bugok/sapling-test, created a dummy first commit and pushed it directly using sl push.

Following this guide, I ran sl push --to remote/my-new-feature, which created this pull request. Now, sl ssl I can see that the local commits are linked to the pull request:

Unfortunately, GitHub doesn’t show the different commits, but that’s where ReviewStack comes into play. Loading https://reviewstack.dev/bugok/sapling-test/pull/1 Shows the following:

Leave a Comment