Skip to content

Instantly share code, notes, and snippets.


Dan Levy justsml

View GitHub Profile
justsml / settings.json
Created Jun 21, 2022
VS Code Recommended Settings
View settings.json
// TypeScript configuration
// Use the project-local typescript version / may be desired, comment out on old TS versions
"typescript.tsdk": "node_modules/typescript/lib",
"typescript.preferences.importModuleSpecifier": "relative",
// Terminal settings
"terminal.integrated.scrollback": 100000, // Terminal scrollback line limit
// Set terminal font size to match VS Code font size. See:
"terminal.integrated.fontFamily": "'MesloLGS NF', 'Hack Nerd Font', Menlo, Monaco, 'Courier New', monospace",

Security Tooling

The following scanning tools offer significant security benefits over basic Dependabot NPM scanning & external scanning services (e.g. Nessus).

Dependency Scanning

OpenSSF/Package Analysis

Read the Package Analysis announcement.

justsml / RectangleConfig.json
Last active May 19, 2022
Rectangle: customized config for ⭐️ Mac window layout utility.
View RectangleConfig.json
"bundleId" : "com.knollsoft.Rectangle",
"defaults" : {
"allowAnyShortcut" : {
"bool" : false
"almostMaximizeHeight" : {
"float" : 0
"almostMaximizeWidth" : {
View getFileAndDirname.js
import path from "path";
import { fileURLToPath } from "url";
* Usage:
* const { __dirname, __filename } = getFileAndDirname(import.meta.url);
export default function getFileAndDirname(importMetaUrl) {
const __filename = fileURLToPath(importMetaUrl);
const __dirname = path.dirname(__filename);
justsml /
Last active Nov 19, 2021
Beautiful Terminal Apps with Nodejs
justsml /
Last active Oct 14, 2021
Project ideas for learning a language, framework or library.

Project Ideas

Project ideas for learning a language, framework or library.

UI Components

  • Autocomplete
    • Use local/static JSON data.
    • Use a popular public API (Star Wars API, Pokemon API, GitHub API, etc.)
  • Notes:
View hammerspoon-init.lua
-- credit:
--[[ function factory that takes the multipliers of screen width
and height to produce the window's x pos, y pos, width, and height ]]
function baseMove(x, y, w, h)
return function()
local win = hs.window.focusedWindow()
local f = win:frame()
local screen = win:screen()
local max = screen:frame()
justsml /
Last active Sep 10, 2021
Fix Open files limit on MacOS OSX 11.4
set -euo pipefail
sudo cat << HEREDOC > /Library/LaunchDaemons/limit.maxfiles.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "">
<plist version="1.0">

MacOS - Software Developer Environment Setup

Dan's collection of MacOS setup and configuration scripts, updated for 2022 🚀!

Table of Contents

Software & Apps

justsml / config-overrides.js
Created Mar 15, 2021
Reference for 'Rewiring' Create-React-Apps without their rude defaults.
View config-overrides.js
// Follow setup instructions
// Example config:
const path = require('path');
const { alias, configPaths } = require('react-app-rewire-alias');
const addRewireScssLoader = require('react-app-rewire-scss-loaders');
const rewireWebpackBundleAnalyzer = require('react-app-rewire-webpack-bundle-analyzer');
module.exports = function override(config, env) {
// Fucking CRApps feel entitled to overwrite tsconfig.json...