Skip to content

Instantly share code, notes, and snippets.

@Fantailed
Fantailed / supernote_template_tips.md
Last active May 6, 2024 17:39
Supernote A6X2 Nomad Template Mockup + Template Creation Workflow Tips

Supernote A6X2 Nomad Template Mockup + Template Creation Workflow Tips

Downloads

Mockup

Affinity: Download .aftemplate
Photoshop (PSD export; compatibility not guaranteed): Download .psd

@webketje
webketje / README.md
Last active May 6, 2024 17:37
Soundcloud Downloader Clean - Tampermonkey userscript OR bookmarklet

Tampermonkey userscript - Soundcloud Downloader Clean

An ad-less, multilingual, clean Soundcloud downloader with robust code. Adds a 'Download' button to all single track views.

Features

  • No third-party embeds, redirects or ads, directly uses the Soundcloud API.
import { Controller, get, Message, useFormContext } from "react-hook-form"
import { FormElement, Input as NextInput, InputProps } from "@nextui-org/react"
import { helperText } from "@/utils/constants"
import { PatternType } from "@/types"
import { useIMask } from "react-imask"
import React, { MutableRefObject, useState } from "react"
type Props = {
pattern?: PatternType
message?: string
@rash0
rash0 / puppeteer_twitterLogin.js
Last active May 6, 2024 17:33
Automate login to twitter with Puppeteer
const puppeteer = require("puppeteer");
const user_email = "email@example.com";
const user_handle = "@example"; //either your handle or phone number
const password = "theEndisNear";
async function fkTwitter() {
const browser = await puppeteer.launch({
headless: false,
});
@amanjuman
amanjuman / derper
Last active May 6, 2024 17:31
TailScale Derper Install on Linux
## Download Go
sudo wget --output-document /opt/go.tar.gz https://go.dev/dl/go1.22.0.linux-amd64.tar.gz
## Remove Existing Go and Extract Downloaded Go
sudo rm -rf /usr/local/go && sudo tar --directory /usr/local --extract --gzip --file /opt/go.tar.gz && sudo rm /opt/go.tar.gz
## Delete & Recreate user for Derper
sudo userdel -r derp && sudo useradd --system --create-home --home-dir /opt/derp --shell /bin/bash derp
## Export Profile path
@luizomf
luizomf / ambiente-dev-ubuntu-curso-python.sh
Created October 31, 2022 01:23
Instalação ambiente dev Ubuntu 22 do curso de Python
#!/bin/bash
# Executar comandos a seguir para atualizar os pacotes
sudo apt update -y
sudo apt upgrade -y
# Só o Python
sudo apt install python3.10-full python3.10-dev -y
# Instalar pacotes a seguir

MySQL Cheat Sheet

Help with SQL commands to interact with a MySQL database

MySQL Locations

  • Mac /usr/local/mysql/bin
  • Windows /Program Files/MySQL/MySQL version/bin
  • Xampp /xampp/mysql/bin

Add mysql to your PATH

merge into vimeo.video t
using (
select
t.record_content:op::text as op
-- for the 'd' case, the 'id' will only come through in the 'before' section
, coalesce(t.record_content:before.id::integer, t.record_content:after.id::integer) as id
, t.record_content:after.user_id::integer as user_id
, t.record_content:after.video_title::text as video_title
, to_timestamp_tz(t.record_content:after.created_at::integer, 3) as created_at
@Kestrer
Kestrer / how-to-write-hygienic-macros.md
Created October 17, 2020 05:35
A guide on how to write hygienic Rust macros

How to Write Hygienic Rust Macros

Macro hygiene is the concept of macros that work in all contexts; they don't affect and aren't affected by anything around them. Ideally all macros would be fully hygienic, but there are lots of pitfalls and traps that make it all too easy to accidentally write unhygienic macros. This guide attempts to provide a comprehensive resource for writing the most hygienic macros.

Understanding the Module System

First, a little aside on the details of Rust's module system, and specifically paths; it is

@AndrewMast
AndrewMast / disable_vanguard.vbs
Last active May 6, 2024 17:25
Commands to disable Riot Vanguard when you aren't playing Valorant
' Disables Vanguard from starting when you boot your computer
Call CreateObject("Shell.Application").ShellExecute("cmd.exe", "/c ""sc config vgc start= disabled & sc config vgk start= disabled""", "", "runas")