Skip to content

Instantly share code, notes, and snippets.

alacritty
arandr
archiso
autoconf
automake
base
bat
bison
blueman
bluez
@knightspore
knightspore / sample-1.js
Created October 26, 2021 08:58
InDebted Code Samples
import Star from "@ui/atoms/Svg/icons/simple/star.svg";
export default function ReviewCardStars({ rating, t }) {
return (
<div className="grid grid-cols-1 mt-10 gap-y-3">
<div className="z-10 flex gap-x-3">
{[1, 2, 3, 4, 5].map((n) => {
if (n <= rating) {
return <Star key={n * n} />;
}
@knightspore
knightspore / dotfiles.sh
Last active July 14, 2021 19:35
Install Dotfiles + Regularly Used Programs
#!/bin/sh
echo "Running Dotfiles Setup"
cd ~
alias config='/usr/bin/git --git-dir=$HOME/.cfg/ --work-tree=$HOME'
echo ".cfg" >> .gitignore
echo "✨ Cloning Bare Repo"
git clone --bare https://github.com/knightspore/dotfiles.git $HOME/.cfg
alias config='/usr/bin/git --git-dir=$HOME/.cfg/ --work-tree=$HOME'
mkdir -p .config-backup && \
@knightspore
knightspore / gradient-generator.js
Last active July 28, 2020 09:57
This sript is for generating hex linear gradients at random with vanilla Javascript. Just create a blank index.html file and add a button with the id "colorButton" and start watching. When you see a gradient you like, check the console to grab its details (it's attached to the <body> element)
var lright = ['left', 'right'];
var updown = ['top', 'bottom'];
var colorButton = document.getElementById('colorButton');
colorButton.onmousedown = function () {
var gradA = "#" + ((1 << 24) * Math.random() | 0).toString(16);
var gradB = "#" + ((1 << 24) * Math.random() | 0).toString(16);
var random = Math.round(Math.random(2));
var random2 = Math.round(Math.random(2));
document.body.style.backgroundImage = '-moz-linear-gradient(to ' + updown[random] + ' ' + lright[random2] + ', ' + gradA + ', ' + gradB + ')'
@knightspore
knightspore / History|-102f8407|entries.json
Last active September 28, 2022 13:04
Visual Studio Code Settings Sync Gist
{"version":1,"resource":"file:///Users/ciaran/Desktop/indebted-website/components/ui/organisms/Forms/GeneralInquiriesForm.js","entries":[{"id":"VuHr.js","timestamp":1649330755461},{"id":"eSYf.js","source":"searchReplace.source","timestamp":1649330861934},{"id":"1wfa.js","timestamp":1649330862984}]}