Skip to content

Instantly share code, notes, and snippets.

@NijeboerFrank
NijeboerFrank / todo.sh.fish
Last active March 9, 2024 22:28
Fish completions for todo.txt-cli
#!/bin/fish
# Place this file into ~/.config/fish/completions or another completions directory
# https://fishshell.com/docs/current/completions.html#where-to-put-completions
# List the help page
set __todo_txt_help_output (todo.sh help)
# Commands
set -l todo_commands (string match -r '^\s{4}([[:lower:]]+).*$' -g $__todo_txt_help_output)
set -l commands_descriptions (string match -r '^\s{4}(\w+[[:ascii:]]+).*$' -g $__todo_txt_help_output)
@kborling
kborling / configuration.nix
Created December 24, 2021 23:59
NixOS Configuration (Sway/Wayland Enabled)
# 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, ... }:
{
nix = {
package = pkgs.nixUnstable;
extraOptions = ''
@diegorodrigo90
diegorodrigo90 / garmin-express-wine.md
Last active November 15, 2024 07:47
Installing garmin express in linux with wine

First we start by creating a wineprefix and installing our prerequisites from terminal:

WINEARCH=win32 WINEPREFIX=/home/$USER/GarminExpress winetricks dotnet452 vcrun2010 corefonts
WINEARCH=win32 WINEPREFIX=/home/$USER/GarminExpress winetricks win7
@DrSensor
DrSensor / desktop.nix
Last active June 11, 2024 01:48
My plan for full migration into NixOS and Wayland
{ pkgs ? import <nixpkgs>
, lib ? pkgs.lib
, desktopEnvironment
}: with pkgs;
desktopEnvironment {
session-manager = emptty;
window-manager = [ sway labwc ];
screen-display = {
use = kanshi; # autorandr
gui = wlay;
@ekickx
ekickx / rc.xml
Last active June 11, 2024 01:48
labwc sample conf
<?xml version="1.0" encoding="UTF-8"?>
<openbox_config>
<keyboard>
<keybind key="XF86AudioMute">
<action name="Execute">
<command>bash ~/Projects/bin/volume mute</command>
</action>
</keybind>
<keybind key="XF86AudioRaiseVolume">
@mschwaig
mschwaig / sway.nix
Last active July 13, 2024 01:10
Configure sway as the window manager for NixOS with gdm as the display manager
{ config, pkgs, lib, ... }:
{
# This sway config is mostly based on https://nixos.wiki/wiki/Sway
# which integrates sway with systemd in the style described here
# https://github.com/swaywm/sway/wiki/Systemd-integration
# and the replies in https://github.com/NixOS/nixpkgs/issues/57602
# with some individual packages added/removed and using sddm as the display manager.
#
# Take care to start the correct target as described by the sway proejct wiki.
@petelacey
petelacey / Dockerfile
Last active November 15, 2024 12:11
Docker Compose setup for Elixir, Phoenix, and Postgres
FROM elixir:latest
# Install debian packages
RUN apt-get update && \
apt-get install --yes build-essential inotify-tools postgresql-client git && \
apt-get clean
ADD . /app
# Install Phoenix packages
(*
RecursiveTypesAndFold-2.fsx
Related blog post: http://fsharpforfunandprofit.com/posts/recursive-types-and-folds-2/
*)
// ==============================================
// PART 2 - Introducing Folds
// ==============================================
@willurd
willurd / web-servers.md
Last active November 13, 2024 13:44
Big list of http static server one-liners

Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.

Discussion on reddit.

Python 2.x

$ python -m SimpleHTTPServer 8000
@pksunkara
pksunkara / config
Last active November 15, 2024 16:02
Sample of git config file (Example .gitconfig) (Place them in $XDG_CONFIG_HOME/git)
[user]
name = Pavan Kumar Sunkara
email = [email protected]
username = pksunkara
[init]
defaultBranch = master
[core]
editor = nvim
whitespace = fix,-indent-with-non-tab,trailing-space,cr-at-eol
pager = delta