Skip to content

Instantly share code, notes, and snippets.

View aaronlifton's full-sized avatar
:octocat:
AstroJS

Aaron Lifton aaronlifton

:octocat:
AstroJS
View GitHub Profile
/* Optional vault name */
const vault = "";
/* Optional folder name such as "Clippings/" */
const folder = "";
/* Optional tags */
let tags = "clippings";
@aaronlifton
aaronlifton / alacritty-tmux-vim_truecolor.md
Created October 21, 2023 16:52 — forked from andersevenrud/alacritty-tmux-vim_truecolor.md
True Color (24-bit) and italics with alacritty + tmux + vim (neovim)

True Color (24-bit) and italics with alacritty + tmux + vim (neovim)

This should make True Color (24-bit) and italics work in your tmux session and vim/neovim when using Alacritty (and should be compatible with any other terminal emulator, including Kitty).

Testing colors

Running this script should look the same in tmux as without.

curl -s https://gist.githubusercontent.com/lifepillar/09a44b8cf0f9397465614e622979107f/raw/24-bit-color.sh >24-bit-color.sh
@Dimentium
Dimentium / leader-layer.edn
Created July 30, 2023 19:48
leader-layer and commands (like space/doom emacs)
{:des "Leader-key layer"
:rules [
:!leader-layer
[:right_command :right_command nil {:alone [["leader-layer" 1][:noti :leader "leader-key"]]
:delayed {:invoked [["leader-layer" 0][:noti :leader]]}
:params {:delay 2000}}]
:leader-layer
[:s [["leader-layer-s" 1]["leader-layer" 0][:noti :leader "leader-key s"]]]
[{:any :key_code} [["leader-layer" 0][:noti :leader]]]
@aaronlifton
aaronlifton / chatGPT-explanation-info.md
Created July 23, 2023 03:59 — forked from birkin/chatGPT-explanation-info.md
chatGPT code-explanation example

cool chatGPT info...

Recently experimenting with rust, I wanted to convert an image to a base64 string. I got some code working via my usual mix of trying stuff and googling. There was a step between loading the image and encoding it to a base64 string that I was curious about. I'd been hearing about copilot-explain, but only have copilot installed, and wanted to move forward. But I'd also recently been experimenting with chatGPT and thought I'd heard that it could explain code. Here's the result...

My prompt...

explain this code...

fn main() {
@yubrew
yubrew / cw-flattener.txt
Last active July 23, 2023 00:31
cw-flattener GPT conversation log
Rust CosmWasm Flattener
User
you are a code expert. The solidity-flattener repo contains a utility that can be used to combine Solidity projects into a single flat file. To use the utility, you first need to clone the repo and install the dependencies:
Code snippet
git clone https://github.com/poanetwork/solidity-flattener
cd solidity-flattener
npm install
Use code with caution. Learn more
Once the dependencies are installed, you can start the script by passing the path to the Solidity contract definition file as a parameter:
@AIAssistantDeveloper
AIAssistantDeveloper / chat.js
Created April 30, 2023 09:11
GPT4 html.index
# Folder > js #
const query = (obj) =>
Object.keys(obj)
.map((k) => encodeURIComponent(k) + "=" + encodeURIComponent(obj[k]))
.join("&");
const colorThemes = document.querySelectorAll('[name="theme"]');
const markdown = window.markdownit();
const message_box = document.getElementById(`messages`);
const message_input = document.getElementById(`message-input`);
@ericksoa
ericksoa / weeklyReport.ts
Created March 21, 2023 18:56
Summarize your work from Jira into an engaging narrative for your boss
// Step 1: Setup your development environment and install required dependencies.
// Install required packages using npm or yarn:
// npm install axios @types/axios dotenv openai @types/node
// or
// yarn add axios @types/axios dotenv openai @types/node
import axios, { AxiosResponse } from 'axios';
import * as dotenv from 'dotenv';
import * as openai from 'openai';
@wking-io
wking-io / app.css
Created January 30, 2023 21:09
Crunchy Data Tailwind config
@tailwind base;
@tailwind components;
@tailwind utilities;
:root {
--gray-50: 250 250 250;
--gray-100: 244 244 245;
--gray-200: 228 228 231;
--gray-300: 161 161 170;
--gray-400: 212 212 216;
@birkin
birkin / chatGPT-explanation-info.md
Last active July 23, 2023 03:59
chatGPT code-explanation example

cool chatGPT info...

Recently experimenting with rust, I wanted to convert an image to a base64 string. I got some code working via my usual mix of trying stuff and googling. There was a step between loading the image and encoding it to a base64 string that I was curious about. I'd been hearing about copilot-explain, but only have copilot installed, and wanted to move forward. But I'd also recently been experimenting with chatGPT and thought I'd heard that it could explain code. Here's the result...

My prompt...

explain this code...

fn main() {
@girip11
girip11 / mac_os_kb_ubuntu_like.md
Last active April 18, 2024 07:50
Configuring Mac OS keyboard shortcuts to resemble Ubuntu

Setup MacOS shortcuts to be same as Ubuntu

I have been using Ubuntu for last few years. Now I have to work on Mac OS for work. But I still use personal laptop which has Ubuntu. So I decided to setup the Mac OS shortcuts to be exactly same as in Ubuntu.

Prerequisites