Imagine a package.json that looks like this:
{
"name": "my-package",
"type": "module",
"exports": {
".": {
"source": "./src/index.ts",
"import": "./dist/index.js",
Imagine a package.json that looks like this:
{
"name": "my-package",
"type": "module",
"exports": {
".": {
"source": "./src/index.ts",
"import": "./dist/index.js",
// Name: Trim latest OBS video | |
import "@johnlindquist/kit"; | |
import { z } from "zod"; | |
import { getActiveEditorFilePath } from "./helpers/vscode"; | |
const { stdout } = await $`ls -t ~/Movies/*.mp4 | head -n 1`; | |
const inputVideo = stdout.trim(); |
// Name: Trim latest OBS video | |
import "@johnlindquist/kit"; | |
import { z } from "zod"; | |
const { stdout } = await $`ls -t ~/Movies/*.mp4 | head -n 1`; | |
const inputVideo = stdout.trim(); | |
const THRESH = "-40"; |
// Name: Trim latest OBS video | |
import "@johnlindquist/kit"; | |
const { stdout } = await $`ls -t ~/Movies/*.mp4 | head -n 1`; | |
const inputVideo = stdout.trim(); | |
const outputVideo = home("Movies", "trimmed", path.parse(inputVideo).base); |
// Name: convert to webp | |
import "@johnlindquist/kit"; | |
import * as path from "path"; | |
const folder = await selectFolder("Select folder to convert from png to webp"); | |
const files = await readdir(folder); | |
const pngFiles = files |
// Name: Stop Work | |
// Description: It's the end of the day! Time to chill. | |
import "@johnlindquist/kit"; | |
const appsToClose = [ | |
`Slack`, | |
`Discord`, | |
`QuickTime Player`, | |
`Centered`, |
// Name: Delete node modules | |
import "@johnlindquist/kit"; | |
await $`find ~/repos -name 'node_modules' -type d -prune -exec rm -rf '{}' +`; |
// Name: convert to webp | |
import "@johnlindquist/kit"; | |
import * as path from "path"; | |
const folder = await selectFolder("Select folder to convert from png to webp"); | |
const files = await readdir(folder); | |
const pngFiles = files |
// Available variables: | |
// - Machine | |
// - interpret | |
// - assign | |
// - send | |
// - sendParent | |
// - spawn | |
// - raise | |
// - actions |
// Available variables: | |
// - Machine | |
// - interpret | |
// - assign | |
// - send | |
// - sendParent | |
// - spawn | |
// - raise | |
// - actions |