Skip to content

Instantly share code, notes, and snippets.

@hypervillain
hypervillain / delete-repositories.js
Created March 25, 2020 13:18
Delete a list of Github repositories
const { Octokit } = require('@octokit/rest')
const octo = new Octokit({
auth: 'an-access-token-with-delete-repo-scope'
})
/** try w/ one first 😛 */
const repos = ['travis-tests']
const owner = 'hypervillain'

Keybase proof

I hereby claim:

  • I am hypervillain on github.
  • I am hypervillain (https://keybase.io/hypervillain) on keybase.
  • I have a public key ASBVQkB2fqw_HUupzN58OW_VduzJ7sVCoHSlVfpKUntzkgo

To claim this, I am signing this object:

@hypervillain
hypervillain / [uid].js
Last active June 25, 2020 09:19
Setup Next.js project with SliceMachine + essential slices
import { Client } from '../prismic'
import SliceZone from 'next-slicezone'
import { useGetStaticProps, useGetStaticPaths } from 'next-slicezone/hooks'
import resolver from '../sm-resolver.js'
const Page = (props) => <SliceZone {...props} resolver={resolver} />
export const getStaticProps = useGetStaticProps({
client: Client(),