Skip to content

Instantly share code, notes, and snippets.

Avatar
🍌
I AM A BANANA

David Kowis dkowis

🍌
I AM A BANANA
View GitHub Profile
@jean-merelis
jean-merelis / _ng-select-theme.scss
Last active Jul 9, 2020
Directive that provides support for MatFormFieldControl (Angular Material) in NgSelect.
View _ng-select-theme.scss
// WIP
@import '~@angular/material/theming';
@mixin ng-select-theme($theme) {
$primary: map-get($theme, primary);
$accent: map-get($theme, accent);
$warn: map-get($theme, warn);
$isdark: map-get($theme, is-dark);
$foreground: map-get($theme, foreground);
@whizzzkid
whizzzkid / XPS-15 9560 Getting Nvidia To Work on KDE Neon
Last active Aug 5, 2020
[XPS 15 Early 2017 9560 kabylake] Making Nvidia Drivers + (CUDA 8 / CUDA 9 / CUDA 9.1) + Bumblebee work together on linux ( Ubuntu / KDE Neon / Linux Mint / debian )
View XPS-15 9560 Getting Nvidia To Work on KDE Neon
# Instructions for 4.14 and cuda 9.1
# If upgrading from 4.13 and cuda 9.0
$ sudo apt-get purge --auto-remove libcud*
$ sudo apt-get purge --auto-remove cuda*
$ sudo apt-get purge --auto-remove nvidia*
# also remove the container directory direcotory at /usr/local/cuda-9.0/
# Important libs required with 4.14.x with Cuda 9.X
$ sudo apt install libelf1 libelf-dev
View install-letsencrypt-in-jdk.sh
#!/bin/bash
set -e
JAVA_HOME=${1-text}
[ $# -eq 0 ] && { echo "Usage: sudo $0 \$(/usr/libexec/java_home -v '1.8*')" ; exit 1; }
KEYSTORE=$JAVA_HOME/jre/lib/security/cacerts
wget https://letsencrypt.org/certs/letsencryptauthorityx1.der
wget https://letsencrypt.org/certs/letsencryptauthorityx2.der
@rschreijer
rschreijer / MetricRegistryJsonProtocol.scala
Last active Sep 17, 2019
spray-json protocol for the Metric lib. Serializes a MetricRegistry and/or single Metric objects from Spray. See https://dropwizard.github.io/metrics, https://github.com/spray/spray-json
View MetricRegistryJsonProtocol.scala
package spray.json.examples
import java.util.concurrent.TimeUnit
import scala.collection.JavaConverters._
import scala.util.{Try, Success, Failure}
import com.codahale.metrics._
import spray.json._
View mvncolor.sh
#!/usr/bin/env bash
# Formatting constants
BOLD=`tput bold`
UNDERLINE_ON=`tput smul`
UNDERLINE_OFF=`tput rmul`
TEXT_BLACK=`tput setaf 0`
TEXT_RED=`tput setaf 1`
TEXT_GREEN=`tput setaf 2`
TEXT_YELLOW=`tput setaf 3`
@sasimpson
sasimpson / isitquesoweek.py
Created Oct 30, 2013
determines if it is queso week at Biff Buzby's Burgers. Assumes the beginning of the week is Monday.
View isitquesoweek.py
#!/usr/bin/python
import sys
import datetime
import argparse
def is_queso_week(today=None):
if today is None:
today = datetime.datetime.now()
if today.weekday() is not 0:
@cdombroski
cdombroski / backend-caller.sh
Created Aug 26, 2013
Full backend debugging for dovecot-antispam
View backend-caller.sh
#!/bin/bash
tmpf=/tmp/antispam.log.$$
(
date
id
let i=0
for arg; do
let i=1+i
echo "arg $i $arg"
done
You can’t perform that action at this time.