git clone --depth=1 <REPO_URL> appName
cd appName
rm -rf package-lock.json
| #!/usr/bin/env bash | |
| # Regenerates the "Domain modules" section of CLAUDE.md from src/modules/*. | |
| # Everything outside the BEGIN/END markers is left untouched. | |
| # Run from the repo root: ./update-claude-md.sh | |
| set -euo pipefail | |
| FILE="CLAUDE.md" | |
| MODULES_DIR="src/modules" | |
| BEGIN="<!-- BEGIN:modules -->" |
| #!/usr/bin/env bash | |
| # Regenerates the "Routes" section of CLAUDE.md from a Next.js project. | |
| # Works with App Router (app/) or Pages Router (pages/), auto-detected. | |
| # Handles any route group names (parens), dynamic segments ([id], [...slug]), | |
| # and flat structures with no groups at all. | |
| # Everything outside the BEGIN/END markers is left untouched. | |
| # Run from the repo root: ./update-claude-md.sh | |
| set -euo pipefail |
| function convertTimeForLocale(timeString, currentTimezone, targetTimezone) { | |
| // Check if time starts with ~ | |
| if (!timeString.startsWith('~')) { | |
| return timeString; // Return as-is if no ~ prefix | |
| } | |
| // If same timezone, return as-is | |
| if (currentTimezone === targetTimezone) { | |
| return timeString; | |
| } |
| function formatTimestamp(timestampInput) { | |
| const timestamp = parseInt(timestampInput, 10); | |
| if (isNaN(timestamp)) { | |
| return 'Invalid timestamp'; | |
| } | |
| // Convert timestamp from seconds to milliseconds | |
| const date = new Date(timestamp * 1000); | |
| const options = { day: '2-digit', month: 'short', year: 'numeric' }; |
| import React from 'react'; | |
| const ExtensionInstaller = () => { | |
| const handleDrop = (event) => { | |
| event.preventDefault(); | |
| const file = event.dataTransfer.files[0]; | |
| if (file.name.endsWith('.crx') || file.name.endsWith('.zip')) { | |
| const reader = new FileReader(); | |
| reader.onload = (event) => { | |
| const url = event.target.result; |
| from PIL import Image | |
| import pytesseract | |
| # Load the image from file | |
| img_path = '/mnt/data/image.png' | |
| img = Image.open(img_path) | |
| # Use tesseract to do OCR on the image | |
| text = pytesseract.image_to_string(img) |
| function binarySearchIterative(inputArray, searchTerm) { | |
| let left = 0; | |
| let right = inputArray.length - 1; | |
| while(left <= right) { | |
| const midPoint = Math.floor((left + right) / 2); | |
| if (inputArray[midPoint] === searchTerm) { | |
| return true; | |
| } else if (searchTerm < inputArray[midPoint]) { |
| function searchRecursive(inputArray, searchTerm, left, right) { | |
| if (left > right) { | |
| return false; | |
| } | |
| const midPoint = Math.floor((left + right) / 2); | |
| if (inputArray[midPoint] === searchTerm) { | |
| return true; | |
| } else if (searchTerm < inputArray[midPoint]) { |
| server { | |
| ssi on; | |
| proxy_intercept_errors on; | |
| location /product-list { | |
| proxy_set_header Host $host; | |
| proxy_set_header X-Real-IP $remote_addr; | |
| proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
| proxy_set_header X-Forwarded-Proto $scheme; |