Skip to content

Instantly share code, notes, and snippets.

@ZeroDragon
ZeroDragon / How to clone a git repo to an existing folder (not empty).md
Last active December 4, 2024 17:45
How to clone a git repo to an existing folder (not empty)
  1. First get to the existing directory
    $ cd my/folder/

  2. Now start a new git repository
    $ git init

  3. Identify if the current elements on the directory are needed or not and add them to the .gitignore file. When ready...
    $ vim .gitignore

  4. When ready create the first commit on the server

@Omar-Aldawy
Omar-Aldawy / index.html
Created October 8, 2022 11:33
yeti login
<form>
<div class="svgContainer">
<div>
<svg class="mySVG" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 200 200">
<defs>
<circle id="armMaskPath" cx="100" cy="100" r="100"/>
</defs>
<clipPath id="armMask">
<use xlink:href="#armMaskPath" overflow="visible"/>
</clipPath>
@karpathy
karpathy / add_to_zshrc.sh
Created August 25, 2024 20:43
Git Commit Message AI
# -----------------------------------------------------------------------------
# AI-powered Git Commit Function
# Copy paste this gist into your ~/.bashrc or ~/.zshrc to gain the `gcm` command. It:
# 1) gets the current staged changed diff
# 2) sends them to an LLM to write the git commit message
# 3) allows you to easily accept, edit, regenerate, cancel
# But - just read and edit the code however you like
# the `llm` CLI util is awesome, can get it here: https://llm.datasette.io/en/stable/
gcm() {
// AI Cortex
// name : Count by X
// link : https://www.codewars.com/kata/5513795bd3fafb56c200049e
#include <vector>
std::vector<int> countBy(int x,int n){
std::vector<int> v;
for(int i=1; i<=n; i++)
v.push_back(i*x);
@pickletoni
pickletoni / countryPhoneCodes.json
Last active December 4, 2024 17:38 — forked from AdonaiAraya/countryPhoneCodes.json
JSON array of 248 countries with phone codes and ISO country code
[{"country":"Afghanistan","code":"93","iso":"AF"},
{"country":"Albania","code":"355","iso":"AL"},
{"country":"Algeria","code":"213","iso":"DZ"},
{"country":"American Samoa","code":"1-684","iso":"AS"},
{"country":"Andorra","code":"376","iso":"AD"},
{"country":"Angola","code":"244","iso":"AO"},
{"country":"Anguilla","code":"1-264","iso":"AI"},
{"country":"Antarctica","code":"672","iso":"AQ"},
{"country":"Antigua and Barbuda","code":"1-268","iso":"AG"},
{"country":"Argentina","code":"54","iso":"AR"},
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@mediaupstream
mediaupstream / make_certs.sh
Last active December 4, 2024 17:30
extract ca-certs, key, and crt from a pfx file
#!/bin/bash
#
# Usage:
# ./make_certs.sh test.example.com
#
# The required input to make_certs.sh is the path to your pfx file without the .pfx prefix
#
# test.example.com.key
# test.example.com.crt (includes ca-certs)
@harperreed
harperreed / peter-thiels-cs183-startup-class-01-notes-essay.md
Created July 29, 2012 21:20
Notes Essays—Peter Thiel’s CS183: Startup—Stanford, Spring 2012

Here is an essay version of my class notes from Class 1 of CS183: Startup. Errors and omissions are my own. Credit for good stuff is Peter’s entirely.

CS183: Startup—Notes Essay—The Challenge of the Future

Purpose and Preamble

@LeftistTachyon
LeftistTachyon / fun.js
Last active December 4, 2024 17:28
The scripting half of the pfp insanity
savestring = "*insert Base64 junk here*";
saving=true;
document.getElementById('button_save').style.background='#888';
statusdiv.innerHTML='Saving the painting';
(SaveObj=new XMLHttpRequest()).open('POST', 'includes/ajax_dsipaint_save.php', true);
SaveObj.setRequestHeader('Content-type', 'application/x-www-form-urlencoded');
SaveObj.send ('data='+savestring);
SaveObj.onreadystatechange=function(){
if(SaveObj.readyState==4){
@ayodejiayodele
ayodejiayodele / copilot-metrics-dashboard-instructions.md
Last active December 4, 2024 17:26
Setup Instructions for GitHub Copilot Metrics Power BI Dashboard

Copilot Metrics Dashboard (Power BI Version)

This guide provides step-by-step instructions for deploying the Copilot Metrics Dashboard in your environment.

Setup Instructions

To use this report, ensure you have Power BI Desktop installed or access to the Power BI online service.

This report supports Copilot Business and Copilot Enterprise products, utilizing the GitHub Copilot User Management and Metrics APIs. The Copilot Metrics API became generally available on October 30th, 2024. For more information, read here.