This file contains hidden or 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
#include <Arduino.h> | |
#include <ESP8266WiFi.h> | |
#include <ESP8266WiFiMulti.h> | |
#include <ESP8266HTTPClient.h> | |
#include <WiFiClientSecureBearSSL.h> | |
const uint8_t fingerprint[20] = {0xA3, 0xDE, 0xBD, 0xC9, 0x77, 0xE0, 0xDC, 0x68, 0x2F, 0x97, 0xB5, 0x59, 0xA0, 0xD0, 0x0A, 0x8E, 0x3B, 0xBA, 0x5C, 0xFC}; |
This file contains hidden or 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, ... }: | |
{ | |
imports = | |
[ # Include the results of the hardware scan. | |
./hardware-configuration.nix | |
./mount.nix | |
./dropbox.nix | |
]; |
This file contains hidden or 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 | |
set -e | |
TRASH="~/.local/share/Trash" | |
nix-collect-garbage -d | |
nix optimise-store | |
rm -rfv "$TRASH/*" | |
nixos-rebuild switch --repair |
This file contains hidden or 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
use std::io::{self, Write}; | |
use std::process::{exit, Command, Stdio}; | |
use std::env; | |
fn main() { | |
main2().unwrap_or_else(|e| { | |
eprintln!("{}", e); | |
exit(1); | |
}) | |
} |
This file contains hidden or 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, lib, ... }: | |
let | |
cfg = config.mailserver; | |
backupUser = "tardis"; | |
dsyncBackupScript = "dsyncbackup.sh"; | |
set = cfg.loginAccounts; |
This file contains hidden or 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
sbtlatest() { | |
curl -s "https://github.com/sbt/sbt/releases/latest" | perl -pe 's/^.*href="(.*)".*$/$1/' | perl -pe 's/^.*tag\/v(.*).*$/$1/' | |
} |
This file contains hidden or 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
object GhettoValidation { | |
implicit class Optionator[A](val a: A) extends AnyVal { | |
def iff(f: => Boolean): Option[A] = | |
if (f) Some(a) else None | |
} | |
} |
This file contains hidden or 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 ruby | |
ivy = File.join(Dir.home, '/.ivy2/local') | |
local = Dir[File.join(ivy, '*/*/*')] | |
if not local.empty? | |
puts "\e[1m\e[33mFiles in IVY local:" | |
local.each do |d| | |
puts "- " + d.sub(ivy + '/', '').split('/').map { |s| '"' + s + '"' }.join(' % ') | |
end |
This file contains hidden or 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 | |
IDEA='' | |
PROJECT_DIR='' | |
function main() { | |
openIdea "$@" | |
} | |
function openIdea() { |
This file contains hidden or 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
$ xiki | |
> Summary | |
The 'xiki' shell command is mostly meant to be called by programs | |
that want to interface with Xiki. But it is sometimes useful for | |
people to call it directly. Example usages: | |
$ xiki ip | |
$ xiki docs/faq | |
> Setting up your editor |