Skip to content

Instantly share code, notes, and snippets.

View up1's full-sized avatar

Somkiat Puisungnoen up1

View GitHub Profile
@up1
up1 / 2.txt
Last active July 4, 2026 03:05
ULimit BEAM
# 1. Check in OS limit
ulimit -n
# 2. Check on system (ulimit -n cannot exceed)
cat /proc/sys/fs/file-max
# 3. check in BEAM
:erlang.system_info(:port_limit) # the +Q ceiling
:erlang.system_info(:port_count) # current usage
@up1
up1 / Hello.java
Last active July 3, 2026 06:52
Hello Java
import static java.lang.IO.print;
import static java.lang.IO.println;
void main() {
int[] arr = {1, 2, 3, 4, 5};
// For each
for (int i : arr) {
print(i + " ");
}
@up1
up1 / 1.txt
Last active July 3, 2026 07:00
Demo with Idempotency
func process1(a int, b int) int{
return a+b
}
$container --version
container CLI version 1.0.0 (build: release, commit: ee848e3)
$container system start
Launching container-apiserver...
Testing access to container-apiserver...
Verifying machine API server is running...
No default kernel configured.
Install the recommended default kernel from [https://github.com/kata-containers/kata-containers/releases/download/3.28.0/kata-static-3.28.0-arm64.tar.zst]? [Y/n]: Y
Installing kernel...
@up1
up1 / 1.txt
Created July 1, 2026 06:03
Postgresql 19 beta 1
-- Create tables for customers, orders, customer_orders, and a property graph to represent the relationships between customers and their orders.
CREATE TABLE customers (
customer_id INT PRIMARY KEY,
name VARCHAR(100),
email VARCHAR(100)
);
CREATE TABLE orders (
order_id INT PRIMARY KEY,
customer_id INT,
@up1
up1 / 1.txt
Last active June 28, 2026 09:23
Demo with codebase-memory-mcp to visualize your code
# Install only in AI Agent
$curl -fsSL https://raw.githubusercontent.com/DeusData/codebase-memory-mcp/refs/heads/main/install.sh | bash
codebase-memory-mcp installer
os: darwin
arch: arm64
variant: standard
target: /Users/.local/bin/codebase-memory-mcp
# Install with UI mode
$curl -fsSL https://raw.githubusercontent.com/DeusData/codebase-memory-mcp/refs/heads/main/install.sh | bash -s -- --ui
@up1
up1 / 1.txt
Last active June 26, 2026 15:24
Deno Desktop
$deno upgrade
$deno --version
deno 2.9.0 (stable, release, aarch64-apple-darwin)
v8 14.9.207.2-rusty
typescript 6.0.3
@up1
up1 / 1.txt
Last active June 23, 2026 15:39
Browser Use Skills
# 1. ติดตั้ง Skills ใน Claude Code แบบ user scope บน MacOS
$mkdir -p ~/.claude/skills/browser-use
$curl -o ~/.claude/skills/browser-use/SKILL.md https://raw.githubusercontent.com/browser-use/browser-use/main/skills/browser-use/SKILL.md
# 2. ใช้งานผ่าน Claude Code
❯ /browser-use how to use ?
⏺ The browser-use skill is a CLI for fast browser automation. A background daemon keeps the browser open between
commands (~50ms latency). Here's how to use it:
@up1
up1 / 1.txt
Last active June 21, 2026 03:52
UUID in go 1.27
$go install golang.org/dl/go1.27rc1@latest
$go1.27rc1 download
$go version
go version go1.27rc1 darwin/arm64
@up1
up1 / 1.txt
Created June 14, 2026 17:46
Demo prompt
# ROLE & GOAL
You are my executive assistant. Triage my inbox to clear out noise and surface high-priority items. Do not send any emails automatically; save all responses as drafts.
# STEP 1: CATEGORIZE
Analyze each unread email and assign it to one of these categories:
- PRIORITY: Direct client requests, urgent team questions, or action items with deadlines.
- FYI: Internal updates, project status reports, or informational emails requiring no action.
- IGNORE: Newsletters, generic promotions, or automated system alerts.
# STEP 2: TAKE ACTION