Skip to content

Instantly share code, notes, and snippets.

@kevin-smets
kevin-smets / iterm2-solarized.md
Last active May 17, 2024 12:37
iTerm2 + Oh My Zsh + Solarized color scheme + Source Code Pro Powerline + Font Awesome + [Powerlevel10k] - (macOS)

Default

Default

Powerlevel10k

Powerlevel10k

@audacus
audacus / vanilla-js-ajax.js
Last active May 17, 2024 12:37
Template for making a AJAX request with vanilla JavaScript.
// create request object
var xhttp = new XMLHttpRequest();
// set params
var method = 'GET' || 'DELETE' || 'POST' || 'PUT' || 'PATCH';
var url = 'controller/action';
var asynchronous = true;
// open request
xhttp.open(method, url, asynchronous);
// set ajax headers
xhttp.setRequestHeader('X-Requested-With', 'XMLHttpRequest');
@Klerith
Klerith / configurar-node-ts.md
Last active May 17, 2024 12:37
Node con TypeScript - TS-Node-dev simplificado

Node con TypeScript - TS-Node-dev (preferido)

  1. Instalar TypeScript y demás dependencias
npm i -D typescript @types/node ts-node-dev rimraf
  1. Inicializar el archivo de configuración de TypeScript ( Se puede configurar al gusto)
npx tsc --init --outDir dist/ --rootDir src
@TrevTV
TrevTV / ArcOn10.md
Last active May 17, 2024 12:36
Guide to installing Arc Browser on Windows 10

As this is not an official way of installing Arc, if you encounter any issues do NOT report them to the developers, they did not intend for people to be running Arc on Windows 10.

This guide is a bit more manual since I wanted to respect the developers' wishes and not directly link any downloads to the beta of Arc.

I don't know how this will work with updates, you may just need to redo the process to update it, but I'm not sure

  1. Install this font: https://aka.ms/SegoeFluentIcons (this fixes the icons since Windows 10 doesn't have this font installed by default)
  2. Download the Arc appinstaller and open it in notepad/some other text editor
  3. Copy everything inside and paste it into this website: https://codebeautify.org/xmlviewer (this is optional, but it makes reading and copying from the file easier)
  4. Find the mainpackage @Uri, it should end in Arc.x64.msix, and open that in a new tab. It should download that msix file.
@zellwk
zellwk / deploy.yml
Created August 2, 2023 03:58
Github Actions
# See https://zellwk.com/blog/github-actions-deploy/ an explanation of this code
name: deploy
on:
push:
branches:
- main
- master
jobs:
build-and-deploy:
runs-on: ubuntu-latest
@fbarretto
fbarretto / streamdiffusion-mac.md
Last active May 17, 2024 12:34
StreamDiffusion on a Mac

This is a gist on how to get StreamDiffusion running on a Mac (mps)

  1. Clone the repo

git clone https://github.com/cumulo-autumn/StreamDiffusion.git
  1. Setup the environment

cd StreamDiffusion
@phiresky
phiresky / tune.md
Last active May 17, 2024 12:33
SQLite performance tuning

You can scale a SQLite database to multiple GByte in size and many concurrent readers by applying the below optimizations.

Run these every time you connect to the db

(some are applied permanently, but others are reset on new connection)

pragma journal_mode = WAL;

Instead of writing directly to the db file, write to a write-ahead-log instead and regularily commit the changes. Allows multiple concurrent readers, and can significantly improve performance.