Skip to content

Instantly share code, notes, and snippets.

View dark dex v4
--[[
DEX Main Script
Created by: Moon and Courtney
RASPBERRY PI IS A SKIDDY SKID AF
--]]
-- Metas
local Services = setmetatable({},{
@joelonsql
joelonsql / PostgreSQL-EXTENSIONs.md
Last active May 13, 2023 05:17
1000+ PostgreSQL EXTENSIONs
View PostgreSQL-EXTENSIONs.md

🗺🐘 1000+ PostgreSQL EXTENSIONs

This is a list of URLs to PostgreSQL EXTENSION repos, listed in alphabetical order of parent repo, with active forks listed under each parent.

⭐️ >= 10 stars
⭐️⭐️ >= 100 stars
⭐️⭐️⭐️ >= 1000 stars
Numbers of stars might not be up-to-date.

@BretFisher
BretFisher / docker-for-mac.md
Last active May 13, 2023 05:17
Getting a Shell in the Docker Desktop Mac VM
View docker-for-mac.md

2021 Update: Easiest option is Justin's repo and image

Just run this from your Mac terminal and it'll drop you in a container with full permissions on the Docker VM. This also works for Docker for Windows for getting in Moby Linux VM (doesn't work for Windows Containers).

docker run -it --rm --privileged --pid=host justincormack/nsenter1

more info: https://github.com/justincormack/nsenter1


@ymdx
ymdx / index.js
Created December 18, 2017 15:05
How to download CSV File from HttpResponse with Ajax
View index.js
success: function(data) {
var blob=new Blob([data]);
var link=document.createElement('a');
link.href=window.URL.createObjectURL(blob);
link.download="<FILENAME_TO_SAVE_WITH_EXTENSION>";
link.click();
}
@sgup
sgup / recommended-routine.md
Last active May 13, 2023 05:08
Recommended Routine - Reddit BodyweightFitness
View recommended-routine.md
@aallan
aallan / async_webserver.py
Created July 4, 2022 15:38
An asynchronous webserver written in MicroPython to turn an LED on/off on a Raspberry Pi Pico W
View async_webserver.py
import network
import socket
import time
from machine import Pin
import uasyncio as asyncio
led = Pin(15, Pin.OUT)
onboard = Pin("LED", Pin.OUT, value=0)
@homaily
homaily / gist:8672499
Last active May 13, 2023 05:05
Regex to validate saudi mobile numbers
View gist:8672499

السلام عليكم ، هذا كود ريجيكس بسيط للتحقق من صحة أرقام الجوالات السعودية ، يقوم الريجيكس بالتحقق من مفتاح الدولة ، مفتاح شركة الإتصالات لضمان صحة النص المدخل .

Hello, this is a simple regex to validate saudi mobile numbers, the code will validate country code, telecome company code and make sure the tested sting is correct .

/^(009665|9665|\+9665|05|5)(5|0|3|6|4|9|1|8|7)([0-9]{7})$/

Regex Breakdown - شرح الكود

@mouredev
mouredev / chatgpt.py
Last active May 13, 2023 05:05
Ejemplo de uso de ChatGPT desde Python
View chatgpt.py
import openai
# Tutorial en vídeo: https://youtu.be/1Pl1FWHKHXQ
# Genera una API Key desde https://openai.com/api
openai.api_key = "TU_API_KEY"
while True:
prompt = input("\nIntroduce una pregunta: ")
@jtleek
jtleek / nhanes-flexdashboard.Rmd
Created March 13, 2019 17:50
Example interactive app in R
View nhanes-flexdashboard.Rmd
---
title: "How does your BMI measure up?"
output: flexdashboard::flex_dashboard
runtime: shiny
---
Inputs {.sidebar}
-------------------------------------
```{r}
View no-try-catch-async-await.js
/* Helper buddy for removing async/await try/catch litter 🗑 */
function O_o(promise) {
return promise.then(data => {
if (data instanceof Error) return [data]
return [null, data]
}).catch(err => [err])
}
/* Look ma, no try/catch */
async function usageExample(params) {