Last active
July 29, 2024 15:16
-
-
Save salif/4b993c157362fab1a6f978ed913707a2 to your computer and use it in GitHub Desktop.
Patch the Gleam formatter to fix the indentation. For the Arch Linux PKGBUILD.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# git clone https://aur.archlinux.org/gleam.git | |
pkgver="1.0.0" | |
EDITOR=${EDITOR:-micro} | |
makepkg --nobuild | |
cd src/ | |
cp -r gleam-$pkgver gleam-$pkgver-new | |
$EDITOR gleam-$pkgver-new/compiler-core/src/format.rs | |
# - const INDENT: isize = 2; | |
# + const INDENT: isize = 3; | |
diff --unified --recursive --text gleam-$pkgver gleam-$pkgver-new > ../INDENT.patch | |
$EDITOR ../INDENT.patch | |
cd ../ | |
$EDITOR PKGBUILD | |
# Add ` "INDENT.patch"` to source: | |
# Add ` 'SKIP'` to sha256sums and sha512sums | |
# Add this to prepare: | |
# patch --forward --strip=1 --input=../INDENT.patch | |
makepkg --nobuild -c | |
makepkg -si |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment