Skip to content

Instantly share code, notes, and snippets.

View waptik's full-sized avatar
💻
Learning JavaScript and ReactJS...

TheVirginBrokey waptik

💻
Learning JavaScript and ReactJS...
View GitHub Profile
@waptik
waptik / randomFile.sh
Created September 2, 2025 20:18
creates 25 empty files for <your_name><numer> each time it runs
#!/bin/bash
NAME="stephane"
last_num=$(ls scripts/${NAME}[0-9]* 2>/dev/null | sed "s/[^0-9]//g" | sort -n |$
echo $last_num
if [ -z "$last_num" ]; then
last_num=0
@waptik
waptik / youtube-tiktok-catchup-workflow.json
Created September 1, 2025 06:05
Dev.to Real-Time AI Agents powered by n8n and Bright Data: Youtube & Tiktok video catchup digest
{
"name": "Catch up on your bookmarked Youtube & Tiktok videos",
"nodes": [
{
"parameters": {
"options": {
"reset": false
}
},
"type": "n8n-nodes-base.splitInBatches",
@waptik
waptik / deploy-from-root-error.sh
Created July 26, 2025 01:36
bts-monorepo workers-vite deploy errors
```
> @woym/server@ deploy /Users/waptik/labs/woym/apps/server
> wrangler deploy
⛅️ wrangler 4.25.1 (update available 4.26.0)
─────────────────────────────────────────────
Using redirected Wrangler configuration.
- Configuration being used: "dist/woym_template_api/wrangler.json"
{
"name": "AI product Images",
"nodes": [
{
"parameters": {},
"type": "n8n-nodes-base.manualTrigger",
"typeVersion": 1,
"position": [
0,
0
@waptik
waptik / deno.lock
Created December 14, 2024 14:26
new lock file
{
"version": "4",
"specifiers": {
"jsr:@libs/logger@^3.1.0": "3.1.3",
"jsr:@oak/commons@1": "1.0.0",
"jsr:@oak/oak@^17.1.3": "17.1.3",
"jsr:@std/assert@1": "1.0.9",
"jsr:@std/bytes@1": "1.0.4",
"jsr:@std/bytes@^1.0.2": "1.0.4",
"jsr:@std/crypto@1": "1.0.3",
<?
# MIT license, do whatever you want with it
#
# This is my invoice.php page which I use to make invoices that customers want,
# with their address on it and which are easily printable. I love Stripe but
# their invoices and receipts were too wild for my customers on Remote OK
#
require_once(__DIR__.'/../vendor/autoload.php');
@waptik
waptik / gist:bc7bb95b11758401cd49856443332d63
Created September 27, 2024 08:52
get farcaster user moxie fantoken address & name
{
# replace 12 with the id of your choice
# if you want for a channel the value of symbol should be "cid:channel_username"
# eg: cid:fitness
subjectTokens(where: {symbol: "fid:12"}) {
tokenAddress: id
name
}
}
@waptik
waptik / compress-base64-imgs.js
Created June 16, 2024 18:48 — forked from 1isten/compress-base64-imgs.js
js compress image (base64) using canvas api
const toBase64 = (file) => new Promise((resolve, reject) => {
const reader = new FileReader();
reader.readAsDataURL(file);
reader.onload = (e) => resolve(e.target.result);
reader.onerror = (err) => reject(err);
});
const compressBase64 = (src, quality = 0.5) => new Promise((resolve) => {
const img = new Image();
img.src = src;
@waptik
waptik / ngrok_hostname.sh
Created January 21, 2024 22:00 — forked from rjz/ngrok_hostname.sh
Get ngrok hostname from command line
#!/bin/sh
# ngrok's web interface is HTML, but configuration is bootstrapped as a JSON
# string. We can hack out the forwarded hostname by extracting the next
# `*.ngrok.io` string from the JSON
#
# Brittle as all get out--YMMV. If you're still reading, usage is:
#
# $ ./ngrok_hostname.sh <proto> <addr>
#
@waptik
waptik / turbo-workspaces-error.sh
Created January 4, 2024 22:48
cli error message for @turbo/workspaces package when migrating from yarn to pnpm
>>> TURBOREPO
Welcome, let's convert your project.
? Where is the root of your repo? .
? Convert from yarn workspaces to: pnpm workspaces
Converting project from yarn to pnpm.