I was in the exact same situation late last year, and I went with a X1 Carbon 6th Generation. It has been fantastic. Everything just works, and it has probably the best keyboard I have ever used on a laptop
Just 2 days ago, I spent 2 hours researching alternatives for my mid-2012 MBPr 15 and had settled on an X1 Carbon as well.
How's the trackpad?
How's sleep mode if you use it with Linux?
I'm still on the fence, but I ordered an iFixit battery replacement kit for the MBP. After almost 7 years (!), it still has everything I need except for the fact that it randomly shuts down when the battery is at 60%...
My trackpad works well, as does the trackpad of everyone else at my company that I have ordered them for, however I have been told they had different suppliers for some of the X1's and a few people have complained that the trackpad and nubbin won't work at the same time.
Sleep mode works great, there is a bios setting for Linux which by default is set to Windows 10, once you set it to linux deep sleep works just by closing the lid, and it resumes as expected.
I do use it with Linux, I have Ubuntu 18.04 running on it and it works great. usb-c charging it amazing, and it works great with my usb-c monitor ( lets me have a single cable to connect everything to the laptop and to charge the laptop ) Battery life is fantastic, the only thing I have to get used to is the CPU in it can burn a lot of battery if you are running it at full load for an extended period of time. When I am running lots of containers on kubernetes it can burn down the battery in a few hours.
I've had an X1 Carbon for a few months, coming from a 2015 MBP. Track pad is pretty bad compared to a MacBook. Everything else is very good. I got the high res screen too and it is comparable to a retina display IMHO.
I've installed Ubuntu 18 with 0 problems. Sleep works fine, haven't had any issues with wake up. You do need to install some custom software and change a BIOS setting for it to use 'Linux' sleep mode (or something like that). Battery life is 'pretty good', not exceptional like MBPs, but definitely in the 6hr range.
Overall I'd recommend a X1 Carbon, especially since you will spend nearly $1k less on the comparable specs.
If you update the firmware on your X1 you won't need the custom software any more. That was on an old version of the BIOS, the new one has a single setting for linux that makes everything work on a stock distro.
Can vouch for ThinkPad X1 carbon. I was in the same situation, MBP 2017 nTB and downgraded to a 2015 ThinkPad X1 with qwhd display.
Cost me 330 euros from eBay. Pretty good computer for development, but it only has 8gb of RAM.
Nevertheless the 2015 Carbon X1 runs Manjaro Linux with KDE very well, everything works out of the box.
More developers really should consider moving away from MacOS and "fashion" technology, and start recycling older systems. A web developer does not need the fastest most expensive device on the market. Especially not a $5000 MacBook with a bullshit touchbar.