Skip to content

Instantly share code, notes, and snippets.

View lando2319's full-sized avatar

Mike Land lando2319

View GitHub Profile
View Get Xcode to bump every build
// Go to edit scheme, then Build > Post-actions
// Change 'Build From' from 'None' to <App Name>
// Add this to the text area
cd "${PROJECT_DIR}" ; agvtool next-version
@lando2319
lando2319 / firebaseFunctionsV2HTTPSEndpointWithoutExpress.js
Last active October 2, 2023 13:50
using hyphens/dashes in firebase-functions V2 HTTPS routes without express
View firebaseFunctionsV2HTTPSEndpointWithoutExpress.js
const { onRequest } = require('firebase-functions/v2/https');
function say() {
return { hello : sayHello }
}
var sayHello = onRequest(
(req, res) => {
res.status(200).send("Hello, is it me you're looking for");
}
View autoImportVSCodeSetting
Setting for the auto import injection
javascript.suggest.autoImports
View breakpoints clientside
{
"type": "chrome",
"request": "launch",
"name": "chrome lookup url",
"url": "http://localhost:3000/#/lookup",
"webRoot": "${workspaceFolder}/src/components"
}
,
View git tag with sed filter
export VERSIONS=$(git tag -l *-prerelease* | sed 's/-prerelease//')
View this as me with argv
#!/usr/bin/osascript
on run argv
tell application "This" to activate
tell application "System Events"
keystroke "/"
delay 1.2
keystroke "m"
View this as me
tell application "this" to activate
tell application "System Events"
keystroke "/"
delay 1.2
keystroke "m"
delay 0.3
keystroke "e"
delay 1.1
keystroke space
View see what's running on 5000
lsof -i :5000
mikes-imac:~ mikeland$ lsof -i :5000
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
Google <num> mikeland 33u IPv4 0xcb550ff... 0t0 TCP localhost:60632->localhost:commplex-main (ESTABLISHED)
Google <num> mikeland 45u IPv4 0xcb550ff... 0t0 TCP localhost:60610->localhost:commplex-main (CLOSED)
node <num> mikeland 29u IPv4 0xcb550ff... 0t0 TCP localhost:commplex-main (LISTEN)
node <num> mikeland 44u IPv4 0xcb550ff... 0t0 TCP localhost:commplex-main->localhost:60632 (ESTABLISHED)
View number of files in dir
ls -l /media/lando2319/76E8-CACF/ | wc -l
View update json via bash
#!/bin/bash
echo "Updating Release State (.releaseState.json) with version $BACKEND_VERSION, with message $RELEASE_MESSAGE"
echo "$(sed '$d' .releaseState.json),
\"$BACKEND_VERSION\":{
\"message\":\"$RELEASE_MESSAGE\",
\"sandbox\":true,
\"production\":false
}