Skip to content

Instantly share code, notes, and snippets.

View kritoke's full-sized avatar

Matt kritoke

View GitHub Profile
@kritoke
kritoke / 0_reuse_code.js
Last active August 29, 2015 14:15
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@kritoke
kritoke / nixos_tips.txt
Last active November 11, 2021 19:51
Various Tips/Tricks and Install Tips for NixOS
Installing on a newer PC with GFI requires a little differen't partitioning. When you open up gparted or your favorite command line partition tool, you need to do the following:
Create a partition scheme that is GPT. Then create the first partition as FAT32 and make it 200 mb or larger, set the flags to boot and esp. Then create your main partition and if you want, a home partition and swap partition.
Next step is to partition the main os partition:
mkfs.ext4 -L nixos /dev/sda1
Mount the partition:
mount /dev/disk/by-label/nixos /mnt
@kritoke
kritoke / haskell_nixos.txt
Last active September 5, 2016 17:20
Haskell Tips
nix-env -f "<nixpkgs>" -iA haskellPackages.stack # installs stack
stack --nix install package
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running ‘nixos-help’).
{ config, pkgs, options, ... }:
{
imports =
[ # Include the results of the hardware scan.
@kritoke
kritoke / config.plist
Created March 12, 2017 19:16
OS X Clover Config for Sierra Samsung M.2 SSD
<dict>
<key>Comment</key>
<string>IONVMeFamily IONameMatch</string>
<key>Disabled</key>
<false/>
<key>Name</key>
<string>IONVMeFamily</string>
<key>InfoPlistPatch</key>
<true/>
<key>Find</key>
clang
libxml2
libxslt
readline
sqlite
openssl
@kritoke
kritoke / elixirTips.txt
Last active December 24, 2018 16:01
Elixir Solus Project Tips
To Setup Postgres SQL after initial setup so Ecto can work:
sudo systemctl enable postgresql
sudo systemctl start postgresql
For new pheonix projects on 1.4, may have to update cowboy to 2:
{:cowboy, "~> 2.0"},
{:plug_cowboy, "~> 2.0"}
@kritoke
kritoke / generate-ssh-key.sh
Created September 29, 2019 14:59 — forked from grenade/01-generate-ed25519-ssh-key.sh
Correct file permissions for ssh keys and config.
ssh-keygen -t rsa -b 4096 -N '' -C "rthijssen@gmail.com" -f ~/.ssh/id_rsa
ssh-keygen -t rsa -b 4096 -N '' -C "rthijssen@gmail.com" -f ~/.ssh/github_rsa
ssh-keygen -t rsa -b 4096 -N '' -C "rthijssen@gmail.com" -f ~/.ssh/mozilla_rsa
@kritoke
kritoke / launch.json
Last active April 19, 2020 16:12
Visual Studio Code Config Files (Mostly for Elixir Settings)
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"type": "mix_task",
"name": "mix (Default task)",
@kritoke
kritoke / gist:607128a69da0a8444eb0d48155fce116
Last active July 31, 2020 14:19
Windows Terminal Configuration
Install PowerLine Font:
https://github.com/microsoft/cascadia-code/
https://docs.microsoft.com/en-us/windows/terminal/tutorials/powerline-setup:
Install-Module posh-git -Scope CurrentUser
Install-Module oh-my-posh -Scope CurrentUser
# If Powershell Core
Install-Module -Name PSReadLine -AllowPrerelease -Scope CurrentUser -Force -SkipPublisherCheck