Skip to content

Instantly share code, notes, and snippets.

View PierreAndreis's full-sized avatar

Pierre Ortega PierreAndreis

View GitHub Profile
@PierreAndreis
PierreAndreis / setup-multifactor-ssh.ps1
Last active July 29, 2026 23:47
Temporary Multifactor Windows SSH setup
Add-WindowsCapability -Online -Name OpenSSH.Server~~~~0.0.1.0
Start-Service sshd
Set-Service sshd -StartupType Automatic
$key = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIL+8D83rLmSNINKLwGqRHyfKlJEpGM+YA+Ox8zq9o6zm"
New-Item C:\ProgramData\ssh -ItemType Directory -Force | Out-Null
Set-Content C:\ProgramData\ssh\administrators_authorized_keys $key -Encoding ascii
# This is the configuration file for Ghostty.
#
# =============
# Theme
# =============
theme = GitHub Dark Default
# =============
# Keybinds
# =============
@PierreAndreis
PierreAndreis / instagram.js
Created December 10, 2025 18:58
instagram-get-reels-details
(async () => {
// replace this with the shortcode you want to test
const shortcode = "REPLACE_WITH_SHORTCODE"; // e.g. "CxYz1234abc"
const docId = "26130443479876713";
const appId = "936619743392459";
const csrfToken = document.cookie.match(/csrftoken=([^;]+)/)?.[1];
if (!csrfToken) {
console.error("No CSRF token found - are you logged in?");
@PierreAndreis
PierreAndreis / useScrollTop.ts
Created December 3, 2023 21:52
useScrollTop.ts expo-router
// Copied from https://github.com/react-navigation/react-navigation/blob/main/packages/native/src/useScrollToTop.tsx
// and modified to work with expo-router
import { useNavigation } from "expo-router";
import * as React from "react";
import type { ScrollView } from "react-native";
type ScrollOptions = { animated?: boolean; x?: number; y?: number };
type ScrollableView =
@PierreAndreis
PierreAndreis / README.md
Created November 11, 2022 03:10 — forked from craftyc0der/README.md
Minikube/Ambassador/Agones

Minikube - Agones

Install Ambassador

helm repo add datawire https://app.getambassador.io
helm repo update

helm install -n emissary --create-namespace \
    emissary-ingress --devel \
import theme from '@chakra-ui/theme';
import { mode } from '@chakra-ui/theme-tools';
const defaultButton = theme.components.Button;
type Dict = Record<string, any>;
function variantSolid(props: Dict) {
const { colorScheme: c } = props;
unbindall
bind "0" "slot10"
bind "1" "slot1"
bind "2" "slot2"
bind "3" "slot3"
bind "4" "slot4"
bind "5" "slot5"
bind "6" "slot6"
bind "7" "slot7"
bind "8" "slot8"
// This example depends on hello.js to be running in another process.
// This Node is a socket that replies to hello.js with "world!" when it receives "Hello".
// This example tests concurrency with parallel messages in IPC.
const { Node } = require("../src/index");
const node = new Node("concurrent")
.on("error", console.error)
.on("connect", () => console.log("Connected!"));
{"lastUpload":"2020-06-18T19:48:03.063Z","extensionVersion":"v3.4.3"}
{
"workbench.iconTheme": "vscode-icons",
"editor.renderWhitespace": "all",
"editor.minimap.enabled": true,
"editor.minimap.renderCharacters": false,
"files.exclude": {
"**/.git": true,
"**/.svn": true,
"**/.hg": true,
"**/CVS": true,