Skip to content

Instantly share code, notes, and snippets.

@cryocaustik
cryocaustik / discourse-dark.css
Created August 21, 2018 18:33
simple modification to alter the discourse dark theme
/* common */
body {
background-repeat: no-repeat;
background-attachment: fixed;
background-position: center;
}
#main-outlet{
background-color: rgba(30, 30, 30, 0.9);
}
@cryocaustik
cryocaustik / README.md
Created December 19, 2018 20:21
Django using Jinja2 template engine and importing Django filters

Django using Jinja2 Template Engine + Django Filters

quick example of the setup files to allow the use of Jinja2 template engine within Django, while still being able to import Django template filters (e.g. Humanize).

Initial Setup

Following the Django Built-in Template docs, you will need to insure you have Jinja2 installed and then we need to create a jinja2.py setup file in our main app directory (same locaiton of our settings.py file).

@cryocaustik
cryocaustik / findtables.py
Last active January 2, 2019 23:48
quick script to find names of tables used in .sql queries
import os
import re
class FindTables:
"""Finds SQL files in directory tree and returns and SQL tables found.
String searches are case in-sensitive and are only considered if they follow a [from|into|join] string.
Returns:
@cryocaustik
cryocaustik / README.md
Last active May 2, 2025 03:12
JSON Dump of ICD 10 Codes & Desc

CMS ICD GEMs JSON Dump

JSON Dump of ICD 10 Codes & Desc

Data Sample (formatted)

[
    {
      "code": "A000",
@cryocaustik
cryocaustik / proc_codes.json
Created January 27, 2019 06:51
CMS Billable Procedure Codes
[{"code":12,"name":"ANESTH EAR EXAM","type":"CPT"},{"code":71,"name":"ANESTH SURGERY OF BREAST","type":"CPT"},{"code":135,"name":"ANESTH LUMBAR PUNCTURE","type":"CPT"},{"code":154,"name":"ANESTH REPAIR OF HERNIA","type":"CPT"},{"code":163,"name":"ANESTH SURG UPPER ABDOMEN","type":"CPT"},{"code":222,"name":"ANESTH TESTIS SUSPENSION","type":"CPT"},{"code":234,"name":"ANESTH HYSTEROSCOPE/GRAPH","type":"CPT"},{"code":296,"name":"ANESTH KNEE ARTHROPLASTY","type":"CPT"},{"code":313,"name":"ANESTH LOWER LEG SURGERY","type":"CPT"},{"code":317,"name":"ANESTH LOWER LEG BONE SURG","type":"CPT"},{"code":336,"name":"CAD BREAST MRI","type":"CPT"},{"code":440,"name":"ANES/ANALG CS DELIVER ADD-ON","type":"CPT"},{"code":465,"name":"NJX PARAVERT W/US CER/THOR","type":"CPT"},{"code":556,"name":"FNA BX W/O IMG GDN 1ST LES","type":"CPT"},{"code":570,"name":"REMOVE FOREIGN BODY","type":"CPT"},{"code":575,"name":"COMPLEX DRAINAGE WOUND","type":"CPT"},{"code":597,"name":"DEBRIDE INFECTED SKIN","type":"CPT"},{"code":600,"name":"DEBRI
@cryocaustik
cryocaustik / monk.txt
Created February 14, 2019 03:59
you're not a monk
A man is driving down the road and his car breaks down near a monastery. He goes to the monastery, knocks on the door, and says, "My car broke down. Do you think I could stay the night?"
The monks graciously accept him, feed him dinner, even fix his car. As the man tries to fall asleep, he hears a strange sound. A sound unlike anything he's ever heard before. The Sirens that nearly seduced Odysseus into crashing his ship comes to his mind. He doesn't sleep that night. He tosses and turns trying to figure out what could possibly be making such a seductive sound.
The next morning, he asks the monks what the sound was, but they say, "We can't tell you. You're not a monk." Distraught, the man is forced to leave.
Years later, after never being able to forget that sound, the man goes back to the monastery and pleads for the answer again.
The monks reply, "We can't tell you. You're not a monk."
The man says, "If the only way I can find out what is making that beautiful sound is to become a monk, then please, mak
{
"particles": {
"number": {
"value": 80,
"density": {
"enable": true,
"value_area": 800
}
},
"color": {
@cryocaustik
cryocaustik / interceptors.js
Created May 19, 2019 06:16
Vuex + axios interceptors to to attach JWT auth tokens to requests, and trigger token refreshes on 401 errors
import axios from 'axios'
import store from '@/store'
export default function setup() {
/**
* Intercept axios request and attach JWT tokens as authorization
*/
axios.interceptors.request.use(
config => {
if (!config.url.endsWith('/refresh')) {
@cryocaustik
cryocaustik / BillCalendar.vue
Created July 26, 2019 17:40
vue places overlay over `v-dialog`, making the dialog unusable
<template>
<div id="bill-calendar">
<ErrorAlerts v-bind:errorList="errors" />
<BillView v-if="selectedBill" :bill="selectedBill" v-model="showBillView" />
<v-layout wrap>
<v-flex xs12 class="my-3">
<v-sheet elevation="5">
<v-calendar
ref="calendar"
v-model="calendar.start"