Skip to content

Instantly share code, notes, and snippets.

View domenkozar's full-sized avatar
💭
I may be slow to respond.

Domen Kožar domenkozar

💭
I may be slow to respond.
View GitHub Profile
import collections
def nest_variables(variables):
nested = dict()
for key, value in variables.items():
segments = key.split('.')
location = nested
for segment in segments[:-1]:
if segment not in location:
location[segment] = dict()
{ config, pkgs, ... }:
# auto configure monitors
# xfce 4.12 will fix this, once released.
# TODO: save configuration state.
let
autoconnect = pkgs.writeScript "automonitors.sh" ''
#!/bin/sh
environment.systemPackages = with pkgs; [
# generally useful tools
links2
wgetpaste
pwgen
curl
vimHugeX
gitFull
#gitAndTools.tig
subversion
ARCH=`uname -m`
ARCH_SYS=`uname -s | tr "[A-Z]" "[a-z]"`
VERSION=1.6
NAME=nix-${VERSION}-${ARCH}-${ARCH_SYS}
if [ "$ARCH" = "i686" -a "$ARCH_SYS" = "freebsd" ]
then
DOWNLOAD_URL=http://hydra.nixos.org/build/6039367/download/1/nix-1.6-i686-freebsd.tar.bz2
elif [ "$ARCH" = "i686" -a "$ARCH_SYS" = "linux" ]
then
building console/dump-mixers.o
CC console/dump-mixers.o
console/dump-mixers.c:22:18: error: 'SOUND_DEVICE_LABELS' undeclared here (not in a function)
console/dump-mixers.c:23:18: error: 'SOUND_DEVICE_NAMES' undeclared here (not in a function)
console/dump-mixers.c:23:1: error: invalid initializer
console/dump-mixers.c: In function 'dump_mixer':
console/dump-mixers.c:43:5: warning: implicit declaration of function 'MIXER_READ' [-Wimplicit-function-declaration]
console/dump-mixers.c:43:36: error: 'SOUND_MIXER_DEVMASK' undeclared (first use in this function)
console/dump-mixers.c:43:36: note: each undeclared identifier is reported only once for each function it appears in
console/dump-mixers.c:44:29: error: 'SOUND_MIXER_STEREODEVS' undeclared (first use in this function)
VERSION=1.6.1
ARCH=`uname -m`
ARCH_SYS=`uname -s | tr "[A-Z]" "[a-z]"`
if [[ "$ARCH" = "i386" ]]
then
ARCH = "i686"
fi
WORK_DIR=`pwd`
VERSION=1.6.1
ARCH=`uname -m`
ARCH_SYS=`uname -s | tr "[A-Z]" "[a-z]"`
if [[ "$ARCH" = "i386" ]]
then
ARCH = "i686"
fi
WORK_DIR=`pwd`
{ config, pkgs, ... }:
{
require = [
<nixos/modules/programs/virtualbox.nix>
./hardware.nix
./monitors.nix
# ./mailpile.nix
];
services.redmine = {
enable = true;
databasePassword = "123456";
themes = {
circle = pkgs.fetchurl {
url = "http://www.redminecrm.com/license_manager/11619/circle_theme-1_0_2.zip";
md5 = "2cfc2e534dc57e8ce9475103ce087618";
};
};
plugins = {
services.redmine = {
enable = true;
databasePassword = "123456";
themes = {
circle = pkgs.fetchurl {
url = "http://www.redminecrm.com/license_manager/11619/circle_theme-1_0_2.zip";
md5 = "2cfc2e534dc57e8ce9475103ce087618";
};
};
plugins = {