Skip to content

Instantly share code, notes, and snippets.

View PedramNavid's full-sized avatar
😼
i am not a cat

Pedram Navid PedramNavid

😼
i am not a cat
View GitHub Profile
@PedramNavid
PedramNavid / ferry-next-support.md
Last active September 21, 2026 00:35
Ferry Next support

Ferry Next support

Ferry Next shows the next Golden Gate Ferry departure for Larkspur, Sausalito, Tiburon and Angel Island, in either direction, on iPhone and Apple Watch, with a Home Screen widget.

Times come from the Golden Gate Bridge, Highway and Transportation District's public timetable and refresh when you pull down on the Ferries screen. The app shows scheduled times only; the district does not publish live boat positions. Service alerts are the district's own.

Questions or problems: email pedram_apps@fastmail.com with your iPhone model and iOS version.

@PedramNavid
PedramNavid / ferry-next-privacy.md
Last active October 1, 2026 04:11
Ferry Next privacy policy

Ferry Next privacy policy

Ferry Next does not collect, store, or share any personal data.

  • No accounts, no analytics, no advertising, no third-party SDKs.
  • The app downloads three public files: Golden Gate Transit's timetable (realtime.goldengate.org), San Francisco Bay Ferry's timetable (gtfs.sanfranciscobayferry.com) and Golden Gate's service alerts page (goldengate.org). These requests carry no identifiers beyond what any web request includes.
  • Location. Only when you tap "Find terminals near me" does the app ask for your location. It
#!/usr/bin/env python3
"""
Simple Project Management CLI Tool
"""
import json
import os
from datetime import datetime
from pathlib import Path
This uses llm.datasette.io and OpenAI.
I use `git commit --template` to provide the output from the LLM to Git. This way, if you do not like the results, you
can quit your editor and no commit will be made.
# Shell function for generating a diff and editing it in your default editor:
gcllm() {
GIT_DIR="$(git rev-parse --git-dir)"
TEMPLATE="$GIT_DIR/COMMIT_EDITMSG_TEMPLATE"
@PedramNavid
PedramNavid / gatsby-ssr.js
Last active August 7, 2022 01:51
Gatsby SSR with Jitsu
// https://www.gatsbyjs.com/docs/reference/config-files/gatsby-ssr/
import React from "react";
export function onRenderBody({ setHeadComponents }, pluginOptions) {
const host = 'https://t.jitsu.com/s/lib.js'
const key = process.env.GATSBY_JITSU_API_KEY
const snippet = `window.jitsu = window.jitsu || (function(){(window.jitsuQ = window.jitsuQ || []).push(arguments);})`
// only render snippet if write key exists
if (key) {
@PedramNavid
PedramNavid / gist:d35876f1c4a1f393f08977e430ed7ed3
Created September 5, 2021 00:34
Neovim settings for js/python
──────┬─────────────────────────────────────────────────────────────────────────────────────────────────
β”‚ File: ftplugin/json.vim
───────┼─────────────────────────────────────────────────────────────────────────────────────────────────
1 β”‚ set shiftwidth=2 " number of spaces to use for each indent
2 β”‚ set tabstop=2 " tabs appear as 4 spaces
3 β”‚ set softtabstop=2 " pressing tab inserts 4 spaces
4 β”‚ set expandtab " pressing tab uses spaces instead of tabs
5 β”‚ set smartindent " auto-indent on new lines
6 β”‚
7 β”‚ set colorcolumn=80
@PedramNavid
PedramNavid / entrypoint.sh
Created February 6, 2019 19:52
Add airflow connections to GCP via Commandline
for conn in bigquery_default google_cloud_default; do
airflow connections -d --conn_id $conn;
airflow connections -a \
--conn_id $conn \
--conn_type google_cloud_platform \
--conn_extra '{ "extra__google_cloud_platform__key_path":"'`
`'token.json", '`
`'"extra__google_cloud_platform__project":'`
`'"my-project-id", '`
`'"extra__google_cloud_platform__scope":'`