To run this, simply run ./organizeDock.js
in a Terminal while in the directory that this script is saved.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo pmset -g sched # see current power schedule | |
sudo pmset repeat wakeorpoweron MTWRF 7:00:00 shutdown MTWRF 20:00:00 # turn on at 7 AM, turn off at 8 PM | |
sudo pmset repeat cancel # cancel current power schedule |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const stripe = require('stripe')(process.env.STRIPE_SECRET_KEY); | |
const { | |
updateUserSubscription, | |
deleteUserSubscription, | |
} = require('./database'); | |
exports.handler = async function (event, context, callback) { | |
const webhookSecret = process.env.STRIPE_WEBHOOK_SECRET; | |
try { | |
const requestId = event?.requestContext?.requestId; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
docker rm $(docker ps -aq) | |
docker rmi --force $(docker images -q) | |
docker system prune --volumes |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var winston = require('winston'); | |
// In other files use var winston = require('./config/winston') and place this file in the app's config/ directory | |
var options = { | |
console: { | |
level: 'info', | |
handleExceptions: true, | |
json: true, | |
colorize: true, |