Skip to content

Instantly share code, notes, and snippets.

@johndevedu
johndevedu / close_notifications_applescript.js
Created February 21, 2023 22:17 — forked from lancethomps/close_notifications_applescript.js
AppleScript to close all notifications on macOS Big Sur, Monterey, and Ventura
function run(input, parameters) {
const appNames = [];
const skipAppNames = [];
const verbose = true;
const scriptName = "close_notifications_applescript";
const CLEAR_ALL_ACTION = "Clear All";
const CLEAR_ALL_ACTION_TOP = "Clear";
[
{
"type": "escape",
"width": 54,
"align": "left"
},
{
"type": "weather",
"align": "right",
"units": "imperial",
[
{
"type": "escape",
"width": 54,
"align": "left"
},
{
"type": "weather",
"align": "right",
"units": "imperial",
@johndevedu
johndevedu / init.lua
Last active June 11, 2019 15:45
hammerspoon settings for Marble Trackball
function dump(o)
if type(o) == 'table' then
local s = '{ '
for k,v in pairs(o) do
if type(k) ~= 'number' then k = '"'..k..'"' end
s = s .. '['..k..'] = ' .. dump(v) .. ','
end
return s .. '} '
else
return tostring(o)
#$snapins = Get-PSSnapin -Registered
#$snapins | Add-PSSnapin
#Get-Module -ListAvailable | Import-Module
#Get-PSSnapin | Format-Table -autosize PSVersion, Name
#Get-Module | Format-Table -autosize ModuleType, Name
function ff ([string] $glob) { get-childitem -recurse -include $glob }
@johndevedu
johndevedu / gulpfile.js
Created January 28, 2016 16:55 — forked from adamrneary/gulpfile.js
Sample gulpfile for pushing functions to Lambda
var gulp = require('gulp');
var gutil = require('gulp-util');
var del = require('del');
var rename = require('gulp-rename');
var install = require('gulp-install');
var zip = require('gulp-zip');
var AWS = require('aws-sdk');
var fs = require('fs');
var runSequence = require('run-sequence');