Skip to content

Instantly share code, notes, and snippets.

View kj800x's full-sized avatar

Kevin Johnson kj800x

View GitHub Profile
@kj800x
kj800x / cloudSettings
Created December 8, 2018 06:11
Visual Studio Code Settings Sync Gist
{"lastUpload":"2018-12-08T06:11:22.733Z","extensionVersion":"v3.2.2"}
@kj800x
kj800x / index.mjs
Created January 13, 2019 22:02
NodeJS Bug Report
import * as request from 'request-promise-native';
{
"panels": [
{
"datasource": {
"type": "grafana",
"uid": "grafana"
},
"description": "",
"fieldConfig": {
"defaults": {
~/src/monarch-ui (kj-impl-s4r ✔) code --list-extensions
alesiong.clang-tidy-linter
alexcvzz.vscode-sqlite
bierner.markdown-mermaid
circledev.glsl-canvas
cschlosser.doxdocgen
dbaeumer.vscode-eslint
dtoplak.vscode-glsllint
eamodio.gitlens
esbenp.prettier-vscode
@kj800x
kj800x / Hacking the LG Monitor's EDID.md
Last active September 12, 2024 23:46
Hacking the LG Monitor's EDID

preface: Posting these online since it sounds like these notes are somewhat interesting based on a few folks I've shared with. These are semi-rough notes that I basically wrote for myself in case I ever needed to revisit this fix, so keep that in mind.

I recently bought an LG ULTRAGEAR monitor secondhand off of a coworker. I really love it and it's been great so far, but I ran into some minor issues with it in Linux. It works great on both Mac and Windows, but on Linux it displays just a black panel until I use the second monitor to go in and reduce the refresh rate down to 60 Hz.

This has worked decent so far but there's some issues:

  • It doesn't work while linux is booting up. The motherboards boot sequence is visible just fine, but as soon as control is handed over to Linux and I'd normally see a splash screen while I'm waiting for my login window, I see nothing.
  • It doesn't work on the login screen. This would be fine if login consistently worked on my second screen, but I need to manually switch
@kj800x
kj800x / autoarchive.js
Created September 8, 2024 01:48
~/src auto archiver
// Scan CWD for directories modified longer than 365 days ago and move them to a new directory based on the current date in the archive directory.
// No dependencies, so only built-in modules are used.
// Just stick this in a directory and `node autoarchive.js`.
const fs = require('fs');
const path = require('path');
function leftPad(num, len) {
return num.toString().padStart(len, '0');
}