Skip to content

Instantly share code, notes, and snippets.

View Synthetica9's full-sized avatar

Patrick Hilhorst Synthetica9

View GitHub Profile
This file has been truncated, but you can view the full file.
0,154375
0,200541
0,207589
0,830941
0,1216025
0,3055677
0,3884285
0,7011997
0,7210205
0,7217253
This file has been truncated, but you can view the full file.
1,42634
1,996698
7,84302
10,715758
10,1026176
11,42024
14,334022
14,705310
15,77
15,35573
from datetime import timedelta
import re
def parseTime(s):
m = re.match(r'^(\d+) *([a-z]+)$', s)
if m is None:
raise ValueError("couldn't parse time string")
units = 'seconds minutes hours days weeks'.split()
num = float(m[1])
from datetime import timedelta
import re
def parseTime(s):
m = re.match(r'^(\d+) *([a-z]+)$', s)
if m is None:
raise ValueError("couldn't parse time string")
units = 'seconds minutes hours days weeks'.split()
num = float(m[1])
for unit in units:
if unit.startswith(m[2]):
G = Graph({
0: [3, 5],
1: [4, 5, 6],
2: [4, 6],
3: [0, 6],
4: [1, 2, 5],
5: [0, 1, 4, 6],
6: [1, 2, 3, 5]
})
2020-01-10 15:17:56 - [sway/main.c:152] Linux AquaRing 5.4.8 #1-NixOS SMP Sat Jan 4 18:19:19 UTC 2020 x86_64 GNU/Linux
2020-01-10 15:17:56 - [sway/main.c:168] Contents of /etc/os-release:
2020-01-10 15:17:56 - [sway/main.c:152] NAME=NixOS
2020-01-10 15:17:56 - [sway/main.c:152] ID=nixos
2020-01-10 15:17:56 - [sway/main.c:152] VERSION="20.03pre-git (Markhor)"
2020-01-10 15:17:56 - [sway/main.c:152] VERSION_CODENAME=markhor
2020-01-10 15:17:56 - [sway/main.c:152] VERSION_ID="20.03pre-git"
2020-01-10 15:17:56 - [sway/main.c:152] PRETTY_NAME="NixOS 20.03 (Markhor)"
2020-01-10 15:17:56 - [sway/main.c:152] LOGO="nix-snowflake"
2020-01-10 15:17:56 - [sway/main.c:152] HOME_URL="https://nixos.org/"
startplasmacompositor: Starting up...
dbus-update-activation-environment: warning: error sending to systemd: org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.systemd1 was not provided by any .service files
qt.qpa.plugin: Could not load the Qt platform plugin "wayland-org.kde.kwin.qpa" in "" even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.
Available platform plugins are: wayland-org.kde.kwin.qpa, wayland-egl, wayland, wayland-xcomposite-egl, wayland-xcomposite-glx, eglfs, linuxfb, minimal, minimalegl, offscreen, vnc, xcb.
/run/current-system/sw/bin/startplasmacompositor: line 283: 4662 Aborted (core dumped) /nix/store/6d0s7par6wsg668m7vks6ym4xdafz49q-kwin-5.16.5-bin/bin/kwin_wayland --xwayland --libinput --exit-with-session=/nix/store/fsvhg692l3lfv7p7gwqfqrxgflbjjnlk-plasma-workspace-5.16.5/libexec/startplasma
startplasmacompositor: Shutting down...
startplasmac
2019-06-19 14:44:51 - [sway/main.c:151] Linux AquaRing 4.19.52 #1-NixOS SMP Mon Jun 17 17:51:57 UTC 2019 x86_64 GNU/Linux
2019-06-19 14:44:51 - [sway/main.c:167] Contents of /etc/os-release:
2019-06-19 14:44:51 - [sway/main.c:151] NAME=NixOS
2019-06-19 14:44:51 - [sway/main.c:151] ID=nixos
2019-06-19 14:44:51 - [sway/main.c:151] VERSION="19.09pre-git (Loris)"
2019-06-19 14:44:51 - [sway/main.c:151] VERSION_CODENAME=loris
2019-06-19 14:44:51 - [sway/main.c:151] VERSION_ID="19.09pre-git"
2019-06-19 14:44:51 - [sway/main.c:151] PRETTY_NAME="NixOS 19.09pre-git (Loris)"
2019-06-19 14:44:51 - [sway/main.c:151] LOGO="nix-snowflake"
2019-06-19 14:44:51 - [sway/main.c:151] HOME_URL="https://nixos.org/"
{ pkgs, lib, ... }:
let
inherit (pkgs.scss-to-json-init.nodePackages) scss-to-json;
stylesJSON = pkgs.runCommand "styles.json" {} ''
${scss-to-json}/bin/scss-to-json ${./styles.scss} > "$out"
'';
styles = lib.importJSON stylesJSON;
in
let
home-manager-repo = builtins.fetchTarball "https://github.com/rycee/home-manager/archive/master.tar.gz";
in
{ ... }:
{
imports = [ "${home-manager-repo}/nixos" ];
programs.home-manager.enable = true;
}