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
Home/Core TX9XD-98N7V-6WMQ6-BX7FG-H8Q99 | |
Home/Core (Country Specific) PVMJN-6DFY6-9CCP6-7BKTT-D3WVR | |
Home/Core (Single Language) 7HNRX-D7KGG-3K4RQ-4WPJ4-YTDFH | |
Home/Core N 3KHY7-WNT83-DGQKR-F7HPR-844BM | |
Professional W269N-WFGWX-YVC9B-4J6C9-T83GX | |
Professional N MH37W-N47XK-V7XM9-C7227-GCQG9 | |
Professional Enterprise | |
Professional Workstation | |
Enterprise NPPR9-FWDCX-D2C8J-H872K-2YT43 | |
Enterprise N DPH2V-TTNVB-4X9Q3-TJR4H-KHJW4 |
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
module hexagon(radius) | |
{ | |
circle(r=radius,$fn=6); | |
} | |
module shell(radius) | |
{ | |
difference() | |
{ | |
hexagon(radius*1.2); // base |
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 | |
# Thanks to G3NSVRV | |
# https://github.com/yuk7/ArchWSL/issues/91#issuecomment-506806989 | |
sudo rm -R /etc/pacman.d/gnupg/ | |
sudo rm -R /root/.gnupg/ | |
sudo rm -R /var/cache/pacman/pkg/ | |
sudo gpg --refresh-keys | |
sudo pacman-key --init | |
sudo pacman-key --populate archlinux |
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 sh | |
# Simple script to create a buildVimPlugin drv for NixOs | |
# JagaJaga 2014 | |
# Usage ./vim2nix.sh repoOwner/repoName (only github is supported) | |
# Deps: nix-prefetch-scripts | |
rep="https://github.com/"$1".git" | |
homepage="https://github.com/"$1 | |
rev=$(git ls-remote "$rep" | head -1 | cut -f1) | |
name=$(echo "$1" | sed 's/\(.*\)\/\(.*\)/\2/g' | sed 's/vim-\(.*\)/\1/g' | sed 's/\(.*\)\.vim/\1/g') |
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
{ lib ? null, ... }: | |
let | |
net = { | |
ip = { | |
# add :: (ip | mac | integer) -> ip -> ip | |
# | |
# Examples: |
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
#!/bin/usr/env bash | |
# Originaly from: https://www.reddit.com/r/NixOS/comments/5yxt45/simple_nix_package_search/ | |
nq () { | |
local CACHE="$HOME/.cache/nq-cache" | |
if ! ( [ -e $CACHE ] && [ $(stat -c %Y $CACHE) -gt $(( $(date +%s) - 3600*24*7 )) ] ); then | |
# read gotcha.. can't pipe to read (as usual zsh beats bash) | |
read x MEM_AVAIL_KB UNIT < <(grep MemAvailable: /proc/meminfo) | |
if [[ $UNIT != "kB" || $MEM_AVAIL_KB -lt 1000000 ]]; then | |
# nix-env can easily use up to 1GB during -qa |
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, ...}: { | |
systemd.services.generate-nix-cache-key = { | |
wantedBy = [ "multi-user.target" ]; | |
serviceConfig.Type = "oneshot"; | |
path = [ pkgs.nix ]; | |
script = '' | |
[[ -f /etc/nix/private-key ]] && exit | |
nix-store --generate-binary-cache-key ${config.networking.hostName}-1 /etc/nix/private-key /etc/nix/public-key | |
''; | |
}; |
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
{ cert ? "", key ? "" }: { | |
server = { config, pkgs, ... }: { | |
services.openssh.enable = true; | |
services.panamax.enable = false; | |
}; | |
hidden = { config, lib, pkgs, ... }: with lib; { | |
options = { | |
owncloudHost = lib.mkOption { | |
default = ""; |
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
:set -XRankNTypes | |
:set -XGADTs | |
:set -XTypeFamilies | |
:set -XTypeApplications | |
:set -XBangPatterns | |
:set -XMagicHash | |
:set -XMultiParamTypeClasses | |
:set -XPatternSynonyms | |
:set -XDataKinds | |
:set -XConstraintKinds |
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
; Ender 3 Custom Start G-code | |
M140 S{material_bed_temperature_layer_0} ; Set Heat Bed temperature | |
M190 S{material_bed_temperature_layer_0} ; Wait for Heat Bed temperature | |
M104 S160; start warming extruder to 160 | |
G28 ; Home all axes | |
G29 ; Auto bed-level (BL-Touch) | |
G92 E0 ; Reset Extruder | |
M104 S{material_print_temperature_layer_0} ; Set Extruder temperature | |
G1 X0.1 Y20 Z0.3 F5000.0 ; Move to start position | |
M109 S{material_print_temperature_layer_0} ; Wait for Extruder temperature |
NewerOlder