Skip to content

Instantly share code, notes, and snippets.

View wandy-dev's full-sized avatar

Andy DeVane wandy-dev

View GitHub Profile
@wandy-dev
wandy-dev / askgpt.sh
Last active January 4, 2023 19:58
GPT chat bot for the terminal.
#!/bin/bash
api_call() {
curl --no-progress-meter https://api.openai.com/v1/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer your-api-key" \
-d "{
\"model\": \"text-davinci-003\",
\"prompt\": \"$@\",
\"temperature\": 0,
set nocompatible " be iMproved, required
filetype off " required
"---- Plugins ----"
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
Plugin 'VundleVim/Vundle.vim'
Plugin 'tpope/vim-fugitive'
Plugin 'tpope/vim-surround'