Skip to content

Instantly share code, notes, and snippets.

View gkio's full-sized avatar
🏠
Working from home

Giorgi gkio

🏠
Working from home
View GitHub Profile

Core Principles

1. The Boy Scout Rule

"Leave the campground cleaner than you found it."

Always leave code better than you found it. Make incremental improvements when you touch a file.

Constraint: Improvements must remain surgical and within blast radius.

import { spawn, ChildProcess } from 'child_process';
import { EventEmitter } from 'events';
import path from 'path';
import fs from 'fs';
import os from 'os';
import { v4 as uuidv4 } from 'uuid';
export interface ClaudeExecutorConfig {
projectPath: string;
permissionMode: 'acceptEdits' | 'bypassPermissions' | 'default' | 'plan';
use std::thread;
use reqwest::Client;
use reqwest::Proxy;
use std::fs;
use std::io::{self, BufRead};
use std::sync::{Mutex, MutexGuard};
use std::thread::sleep;
use std::time::Duration;
use rand::Rng;
#!/bin/bash
function error {
echo -e "\\e[91m$1\\e[39m"
exit 1
}
function check_internet() {
printf "Checking if you are online..."
wget -q --spider http://github.com
@gkio
gkio / multiple_ssh_setting.md
Created January 3, 2022 06:13 — forked from jexchan/multiple_ssh_setting.md
Multiple SSH keys for different github accounts

Multiple SSH Keys settings for different github account

create different public key

create different ssh key according the article Mac Set-Up Git

$ ssh-keygen -t rsa -C "your_email@youremail.com"
import {
useRosterState,
useAttendeeStatus,
} from 'amazon-chime-sdk-component-library-react';
const useMeetingAttendees = () => {
const { roster } = useRosterState();
return Object.values(roster).map((attendee) => {
const { chimeAttendeeId, externalUserId } = attendee;
https://medium.com/@nickpeleh/dockerizing-a-node-js-web-app-with-redis-and-postgresql-60ddc697b44
/*
digital_root(16)
=> 1 + 6
=> 7
digital_root(942)
=> 9 + 4 + 2
=> 15 ...
=> 1 + 5
=> 6
/*
likes [] // must be "no one likes this"
likes ["Peter"] // must be "Peter likes this"
likes ["Jacob", "Alex"] // must be "Jacob and Alex like this"
likes ["Max", "John", "Mark"] // must be "Max, John and Mark like this"
likes ["Alex", "Jacob", "Mark", "Max"] // must be "Alex, Jacob and 2 others like this"
*/
function likes(names) {
return {