From cf1d82ac66b0c5c6e9989dc18c6ba06225c0868f Mon Sep 17 00:00:00 2001 From: Oscar Hinton Date: Thu, 16 Dec 2021 14:10:11 +0100 Subject: [PATCH] Add .git-blame-ignore-revs and prettier instructions (#585) --- .git-blame-ignore-revs | 1 + README.md | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+) create mode 100644 .git-blame-ignore-revs diff --git a/.git-blame-ignore-revs b/.git-blame-ignore-revs new file mode 100644 index 00000000..b2c2a6a4 --- /dev/null +++ b/.git-blame-ignore-revs @@ -0,0 +1 @@ +193434461dbd9c48fe5dcbad95693470aec422ac diff --git a/README.md b/README.md index fed8186b..95529e3f 100644 --- a/README.md +++ b/README.md @@ -16,3 +16,23 @@ Common code referenced across Bitwarden JavaScript projects. - _Microsoft Build Tools 2015_ in Visual Studio Installer - [Windows 10 SDK 17134](https://developer.microsoft.com/en-us/windows/downloads/sdk-archive/) either by downloading it seperately or through the Visual Studio Installer. + +## Prettier + +We recently migrated to using Prettier as code formatter. All previous branches will need to updated to avoid large merge conflicts using the following steps: + +1. Check out your local Branch +2. Run `git merge 8b2dfc6cdcb8ff5b604364c2ea6d343473aee7cd` +3. Resolve any merge conflicts, commit. +4. Run `npm prettier` +5. Commit +6. Run `git merge -Xours 193434461dbd9c48fe5dcbad95693470aec422ac` +7. Push + +### Git diff + +We also recommend that you configure git to ignore the prettier revision using: + +```bash +git config blame.ignoreRevsFile .git-blame-ignore-revs +```