Every Nix derivation produces a Nix store output that has 3 things:
- Executables
- Libraries
- Data
Executables are always exported using the PATH
environment variable. This is pretty much automatic.
/* selected file list item */ | |
.part.sidebar.right.pane-composite-part { | |
border: none !important; | |
} | |
.monaco-workbench .part > .content { | |
width: 100% !important; | |
} | |
/* comments */ |
{...}: { | |
# imports by full path without copying to /nix/store | |
imports = builtins.map (n: toString ./. + "/${n}") (builtins.attrNames (builtins.removeAttrs (builtins.readDir ./.) [(builtins.unsafeGetAttrPos "_" {_ = null;}).file])); | |
# copies all files from the current directory to /nix/store and imports from /nix/store | |
# imports = builtins.map (n: "${./.}/${n}") (builtins.attrNames (builtins.removeAttrs (builtins.readDir ./.) [(builtins.unsafeGetAttrPos "_" {_ = null;}).file])); | |
} |
# vim: set softtabstop=2 tabstop=2 shiftwidth=2 expandtab autoindent syntax=nix nocompatible : | |
# Containers | |
{ config, pkgs, ... }: | |
{ containers.browser = | |
let hostAddr = "192.168.100.10"; | |
in | |
{ privateNetwork = true; | |
hostAddress = hostAddr; |
local_client | |
server | |
client | |
ext |
#!/bin/bash | |
function multiselect { | |
# little helpers for terminal print control and key input | |
ESC=$( printf "\033") | |
cursor_blink_on() { printf "$ESC[?25h"; } | |
cursor_blink_off() { printf "$ESC[?25l"; } | |
cursor_to() { printf "$ESC[$1;${2:-1}H"; } | |
print_inactive() { printf "$2 $1 "; } | |
print_active() { printf "$2 $ESC[7m $1 $ESC[27m"; } |
nadeem@myznc:~/go/src$ ls -al dummy | |
total 12 | |
drwxrwxr-x 2 nadeem nadeem 4096 Jul 20 18:46 . | |
drwxrwxr-x 6 nadeem nadeem 4096 Jul 20 18:45 .. | |
-rw-rw-r-- 1 nadeem nadeem 129 Jul 20 18:46 hello.go | |
nadeem@myznc:~/go/src/dummy$ cat hello.go | |
// Package dummy contains hello world library. | |
package dummy |
#!/usr/bin/env python3 | |
import sys | |
import json | |
import subprocess | |
direction=bool(sys.argv[1] == 't' or sys.argv[1] == 'T') | |
swaymsg = subprocess.run(['swaymsg', '-t', 'get_tree'], stdout=subprocess.PIPE) | |
data = json.loads(swaymsg.stdout) | |
current = data["nodes"][1]["current_workspace"] |
#!/bin/sh | |
# TODO: If using --criteria on a window in another workspace, sway switches to that workspace | |
USAGE="\ | |
${0} [--id|--criteria] <index|id|criteria> | |
Focus/hide the container at <index> in the scratchpad | |
Depends: | |
jq | |
Args: |