const { Octokit } = await npm("scriptkit-octokit");
const octokit = new Octokit({
  auth: {
    scopes: ["gist"],
  },
});
const content = await paste();
if (!content) {
  console.log("clipboard is empty");
  exit();
}
const { data } = await octokit.rest.gists.create({
  description: "Created using https://github.com/johnlindquist/kit/discussions/266",
  public: false,
  files: {
    "clipboard.txt": { content },
  },
});
await copy(data.html_url);
console.log("Gist created at %s", data.html_url);