Created
May 7, 2023 05:05
-
-
Save mabry1985/ede0833d6ca355ba8be05a524ff833af to your computer and use it in GitHub Desktop.
This file contains 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
// Name: Prompt Manager | |
// Description: Manage your prompt templates | |
// Author: Josh Mabry | |
// Twitter: @AI_Citizen | |
//################## | |
// ScriptKit Imports | |
//################## | |
import "@johnlindquist/kit"; | |
// import { editPrompt } from "./utils/prompt-crud.js"; | |
export const editPrompts = async () => { | |
const actions = { | |
create: createPrompt, | |
update: updatePrompt, | |
delete: deletePrompt, | |
}; | |
const selectedAction = await mini("Choose an action", [ | |
{ | |
name: "Create prompt", | |
value: "create", | |
}, | |
{ | |
name: "Update prompt", | |
value: "update", | |
}, | |
{ | |
name: "Delete prompt", | |
value: "delete", | |
}, | |
]); | |
await actions[selectedAction](); | |
}; | |
onTab("Manage Prompts", async (input) => { | |
await editPrompts(); | |
}); | |
onTab("Prompts", async (input) => {}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment