Skip to content

Instantly share code, notes, and snippets.

@JeffJacobson
JeffJacobson / __init__.py
Created February 12, 2026 19:56
Create CSV scale list from ArcGIS Pro
# Scale levels from https://developers.arcgis.com/documentation/demos/zoom-calculator/zoomCalculator.html
from collections import OrderedDict
from typing import Literal, TypedDict, NamedTuple
class ScaleItemDict(TypedDict):
scale: float
suggestion: str
@JeffJacobson
JeffJacobson / display-features-as-table.js
Last active February 4, 2026 21:58
Display FeatureSet as a Table - Postman - Post Response Visualization
/**
* @typedef SpatialReference
* @property {number} wkid
* @property {?number} latestWkid
*/
/**
* @typedef Field
* @property {string} name
* @property {string} type
# Try the following command sequence:
git lfs uninstall
git reset --hard
git lfs install
git lfs pull
# In case if this is not working (because this was not working for me), the following hack may work:
git rm --cached -r .
@JeffJacobson
JeffJacobson / README.md
Last active October 8, 2025 19:32
Locate WSDOT milepost nearest click

Locating WSDOT Milepost via feature layer queries and display filters.

See the JSDoc comment at the top of index.ts for details

@JeffJacobson
JeffJacobson / Microsoft.Powershell_profile.ps1
Last active June 21, 2024 01:15
Profile that imports modules and sets up programs ONLY IF THEY ARE AVAILABLE
# Tests if a command exists.
function commandExists($commandName) {
return $null -ne (Get-Command $commandName -ErrorAction SilentlyContinue)
}
# Tests to see if a module is installed on the computer.
function moduleExists($moduleName) {
return $null -ne (Get-Module $moduleName -ListAvailable)
}
@JeffJacobson
JeffJacobson / audio2midi.md
Created January 24, 2023 21:24 — forked from natowi/audio2midi.md
List of open source audio to midi packages
@JeffJacobson
JeffJacobson / commodore-64-colors.json
Last active November 9, 2022 21:05
Commodore 64 color palette JSON and script that generated it
{
"Black": "#000000",
"White": "#FFFFFF",
"Red": "#880000",
"Cyan": "#AAFFEE",
"Violet / purple": "#CC44CC",
"Green": "#00CC55",
"Blue": "#0000AA",
"Yellow": "#EEEE77",
"Orange": "#DD8855",
pip list --outdated --format json | ConvertFrom-Json | foreach { $_.name } | Out-File outdated.txt
pip install -r .\outdated.txt --update
@JeffJacobson
JeffJacobson / index.html
Created June 21, 2022 15:38
MapImageLayer Clipping Sample
<html>
<head>
<link rel="stylesheet" href="min.css">
<meta charset="utf-8" />
<meta
name="viewport"
content="initial-scale=1,maximum-scale=1,user-scalable=no"
/>
<!--
ArcGIS API for JavaScript, https://js.arcgis.com
@JeffJacobson
JeffJacobson / Extensions.cs
Last active January 29, 2019 18:59
ArcObjects extension methods
using ESRI.ArcGIS.Carto;
using ESRI.ArcGIS.esriSystem;
using ESRI.ArcGIS.Geodatabase;
using System;
using System.Collections.Generic;
using System.Text.RegularExpressions;
namespace Wsdot.ArcGis.Extensions
{
public static class Extensions