Skip to content

Instantly share code, notes, and snippets.

View patharanordev's full-sized avatar
🤝
Focusing

PatharaNor patharanordev

🤝
Focusing
View GitHub Profile
@patharanordev
patharanordev / react-native-require-gradle-high-ver.md
Created March 4, 2023 13:55
React Native | fixing The Android Gradle plugin supports only kotlin-android-extensions Gradle plugin version x.y.z and higher

React Native : kotlin-android-extensions Gradle plugin version x.y.z and higher

Example error log :

...
BUILD FAILED in 31s

error Failed to install the app. Make sure you have the Android development environment set up: https://reactnative.dev/docs/environment-setup.
Error: Command failed: ./gradlew app:installDebug -PreactNativeDevServerPort=8081
@patharanordev
patharanordev / nestjs.Dockerfile
Created September 16, 2023 12:16
Reduce size of Dockerized NestJS from 7XXMB to 185MB
# -------------------------------------------
# Prepare runner
FROM node:18-alpine AS runner
RUN apk update && \
apk add curl bash g++ make && \
rm -rf /var/cache/apk/*
# Install node-prune (https://github.com/tj/node-prune)
@patharanordev
patharanordev / run-ios-dotnet7-maui-mac-m1.md
Created February 9, 2024 12:53
Run App on iOS14.2 simulator by using MAUI .NET v7.0 on macOS M1

Run App on iOS14.2 simulator by using MAUI .NET v7.0 on macOS M1

Note: Multi-platform Application UI (MAUI).

Requirements

  • .NET v7 (compat with MS iOS SDK 16.2)
  • Visual Studio 2022
  • iOS simulator 14.2
  • macOS M1
@patharanordev
patharanordev / convert-gguf-ollama2llama.sh
Last active July 26, 2026 15:58
reuse model in gguf format from ollama to llama.cpp
MODEL="qwen2.5"
PARAMS="7b"
# Get the manifest path and extract the digest for the 'model' layer
# Then print the final blob path
MODEL_PATH=$(find ~/.ollama/models/manifests -name "${MODEL//:/_}" | head -n 1)
DIGEST=$(jq -r '.layers[] | select(.mediaType == "application/vnd.ollama.image.model") | .digest' "$MODEL_PATH/$PARAMS")
BLOB_PATH="$HOME/.ollama/models/blobs/${DIGEST/:/-}"
echo "Model path: $MODEL_PATH"