Skip to content

Instantly share code, notes, and snippets.

View gclark-eightfold's full-sized avatar

Grant Clark gclark-eightfold

View GitHub Profile
@gclark-eightfold
gclark-eightfold / $README.md
Last active April 19, 2022 18:06
Patch for @expo/vector-icons to use react-native-vector-icons@9.1.0

How to Use

  1. Follow the instructions to setup/use patch-package
  2. Copy the included @expo+vector-icons+12.0.5.patch file into your patches directory.
  3. Since patch-package won't work for binary files, you'll need to copy the Fonts directory from react-native-vector-icons into your patches directory (or wherever else is convenient). If you only need a specific Font and don't intend to use the other fonts, you can reduce the Fonts directory down to only the fonts you require if you like.
  4. To copy over the Fonts directory when patching, make sure to include the following into your postinstall script in package.json:
{
  "scripts": {
 "postinstall": "patch-package && cp -r patches/Fonts node_modules/@expo/vector-icons/build/vendor/react-native-vector-icons",
@gclark-eightfold
gclark-eightfold / patch_glibc.sh
Created January 15, 2024 21:39
Patch glibc for Node 18+
#!/bin/bash
# Upgrades glibc to 2.28 on Ubuntu 18.04 LTS to support Node 18+
# Fixes: node: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.28' not found (required by node)
# Original script found here: https://github.com/nodesource/distributions/issues/1392#issuecomment-1815887430
# Check if this patching is needed
node -v &>/dev/null
if [ $? -eq 0 ]; then
echo "Node $(node -v) is installed, and does not require patching."