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
(ns counterstats-clj.core | |
(:gen-class) | |
(:require [clj-http.client :as client] | |
[cheshire.core :refer :all])) | |
(def steam-key "XXX") | |
(def csgo-appid "730") | |
(def steam-profile "76561198005221932") | |
(defn flatten-steam-stats [stats] |
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
package main | |
import ( | |
"fmt" | |
"os" | |
"syscall" | |
"time" | |
"unsafe" | |
) |
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/sh | |
# Cero3 Shaper | |
# A 3 bin tc_codel and ipv6 enabled shaping script for | |
# ethernet gateways | |
# This program is free software; you can redistribute it and/or modify | |
# it under the terms of the GNU General Public License version 2 as | |
# published by the Free Software Foundation. | |
# | |
# Copyright (C) 2012-4 Michael D. Taht, Toke Høiland-Jørgensen, Sebastian Moeller |
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
defmodule Crawlerex do | |
@url "http://lib.colostate.edu/wildlife/atoz.php?letter=ALL" | |
@fname "/tmp/animals.html" | |
def download do | |
%HTTPoison.Response{body: body} = HTTPoison.get! @url | |
File.write! @fname, body | |
end | |
def run do |
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
defmodule Character do | |
use GraphQL.ObjectInterface | |
field :id, null: false | |
field :name | |
field :friends, type: List.of(Character) | |
field :appearsIn, type: List.of(Episode) | |
end | |
defmodule Human do |
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 python | |
import sys | |
import getpass | |
import poplib | |
if len(sys.argv) != 3: | |
print("{0} <POP3 host> <username>".format(sys.argv[0])) | |
sys.exit(1) |
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
package main | |
import ( | |
"fmt" | |
"os" | |
"os/signal" | |
"time" | |
) | |
const n = 5 |
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
<input type="text" ng-model="searchQuery" clear-with-esc> |
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
--- simple.qos | |
+++ simple-bwlimit.qos | |
@@ -77,6 +77,7 @@ | |
BE_RATE=`expr $CEIL / 6` # Min for best effort | |
BK_RATE=`expr $CEIL / 6` # Min for background | |
BE_CEIL=`expr $CEIL - 16` # A little slop at the top | |
+BL_RATE=`expr $CEIL / 100` | |
LQ="quantum `get_mtu $IFACE $CEIL`" | |
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
defmodule XXX.Schema.Middleware.FieldACL do | |
@behaviour Absinthe.Middleware | |
def call(resolution, {_field, nil}) do | |
resolution | |
end | |
def call(resolution, {field, public_fields}) do | |
logged_in? = Map.get(resolution.context, :current_user) != nil |
OlderNewer