Skip to content

Instantly share code, notes, and snippets.

Avatar

adilw3nomad adilw3nomad

  • Somewhere
View GitHub Profile
View Yabai_Configs.md

This is my current (as of 4/30/2020) Yabai and skhdrc config as well as the Ubersicht (http://tracesof.net/uebersicht/) widget I use rather than the Yabai status bar. I went this route rather than the built-in status bar because I didn't like how Yabai as of 2.0.1 handled multiple monitors in the status bar.

Nothing is too far from defaults here, and the spaces.coffee was something I found linked in an issue on Yabai's github page.

View cluster.yaml
---
kind: Service
apiVersion: v1
metadata:
name: main-app
annotations:
service.beta.kubernetes.io/do-loadbalancer-protocol: "http"
service.beta.kubernetes.io/do-loadbalancer-algorithm: "least_connections"
service.beta.kubernetes.io/do-loadbalancer-tls-ports: "443"
service.beta.kubernetes.io/do-loadbalancer-certificate-id: "YOUR_CERT_ID_GOES_HERE"
View min-api-try-conversion
...........
calculateVolumePriceConversionCoefficient = function(currentObj1, currentObj2, timestampForCalculation){
var timePassedObj1 = timestampForCalculation - currentObj1.LASTUPDATE;
var timePassedObj2 = timestampForCalculation - currentObj2.LASTUPDATE;
//negative or 0 cap it at 1
if(timePassedObj1 <=0 ){ timePassedObj1 = 1; }
if(timePassedObj2 <=0 ){ timePassedObj2 = 1; }
//if last update is more than 1 day ago cap it at 1 day
if(timePassedObj1 > 86400){ timePassedObj1 = 86400; }
@LucaTNT
LucaTNT / Spotify-now-playing-on-TouchBar.scpt
Last active Sep 27, 2018
This script can be used in conjunction with Better Touch Tool to display the currently playing track in Spotify on the MacBook Pro TouchBar. More info here: https://lucatnt.com/2017/02/display-the-currently-playing-track-in-itunesspotify-on-the-touch-bar
View Spotify-now-playing-on-TouchBar.scpt
-- This script can be used in conjunction with Better Touch Tool to display the currently playing track on the MacBook Pro TouchBar
-- More info here: https://lucatnt.com/2017/02/display-the-currently-playing-track-in-itunesspotify-on-the-touch-bar
if application "Spotify" is running then
tell application "Spotify"
if player state is playing then
return (get artist of current track) & " - " & (get name of current track)
else
return ""
end if
@mubix
mubix / infosec_newbie.md
Last active Oct 6, 2022
How to start in Infosec
View infosec_newbie.md
@josephspurrier
josephspurrier / values_pointers.go
Last active Sep 19, 2022
Golang - Asterisk and Ampersand Cheatsheet
View values_pointers.go
/*
********************************************************************************
Golang - Asterisk and Ampersand Cheatsheet
********************************************************************************
Also available at: https://play.golang.org/p/lNpnS9j1ma
Allowed:
--------
p := Person{"Steve", 28} stores the value