This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export FLAKE_BASE=$HOME/nixos/my-company | |
export FLAKE_PATH=$FLAKE_BASE/${PWD##*/} | |
watch_file $FLAKE_PATH/flake.nix | |
watch_file .env | |
use flake $FLAKE_PATH --impure | |
export PYTHONPATH=$PWD |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
inputs = { | |
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; | |
devenv.url = "github:cachix/devenv"; | |
}; | |
nixConfig = { | |
extra-trusted-public-keys = "devenv.cachix.org-1:w1cLUi8dv3hnoSPGAuibQv+f9TZLr6cv/Hm9XgU50cw="; | |
extra-substituters = "https://devenv.cachix.org"; | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ config, lib, pkgs, helix, ... }: | |
{ | |
imports = | |
[ | |
# Include the results of the hardware scan. | |
./hardware-configuration.nix | |
../../openrgb | |
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ config, pkgs, pkgs-stable, ... }: | |
{ | |
imports = [ | |
./shell | |
./programs | |
]; | |
home = { | |
username = "mikelane"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
description = "Mike's NixOS Flake"; | |
nixConfig = { | |
experimental-features = [ "nix-command" "flakes" ]; | |
extra-substituters = [ | |
# Nix community's cache server | |
"https://nix-community.cachix.org" | |
]; | |
extra-trusted-public-keys = [ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
check_commands_available() { | |
local missing_cmds=() | |
local cmds=("sgpt" "pandoc") # Add any other required commands to this array | |
for cmd in "${cmds[@]}"; do | |
if ! command -v "$cmd" &> /dev/null; then | |
missing_cmds+=("$cmd") | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
*.env | |
# Created by .ignore support plugin (hsz.mobi) | |
### Diff template | |
*.patch | |
*.diff | |
### Windows template | |
# Windows thumbnail cache files | |
Thumbs.db |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import re | |
from collections import deque | |
from typing import List, Union | |
def tokenize(expression: str) -> List[Union[int, str]]: | |
tokens = [ | |
int(token) | |
if token.isnumeric() | |
else token |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import click | |
import difflib | |
import numpy as np | |
import random | |
import sys | |
import time | |
from os import name, system | |
from scipy.ndimage import convolve |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def draw_square(side_length: int) -> None: | |
for _ in range(4): | |
turtle.forward(side_length) | |
turtle.right(90) | |
def draw_concentric_squares(number_of_squares: int = 5, radius_increase: int = 20) -> None: | |
turtle.begin_fill() | |
for length in range(radius_increase, 2 * number_of_squares * radius_increase, radius_increase * 2): | |
draw_square(length) | |
x, y = turtle.pos() |
NewerOlder