From bbd1f06a46b8e8db3e93e258de7a632cf40b0033 Mon Sep 17 00:00:00 2001 From: Cristian Oliveira Date: Sat, 8 Apr 2023 11:55:09 +0200 Subject: [PATCH] docs: add getting started --- README.md | 39 ++++++++++++++++++++++++++++++++++++++- 1 file changed, 38 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 83ed2b2..4e45dd6 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,39 @@ # snipgpt -A cli to generate short snippets using openai LLM + +A CLI to generate short snippets using Openai LLM + +### Demo + +![snipgpt demo](https://raw.githubusercontent.com/cristianoliveira/snipgpt/main/snipgpt-demo.png) + +## Getting started + +Clone this repo and install the dependencies. + +```bash +git clone git@github.com:cristianoliveira/snipgpt.git +cd snipgpt +npm i +``` + +Obtain your OpenAI key following these [instructions](https://help.openai.com/en/articles/4936850-where-do-i-find-my-secret-api-key). + +```bash +cp .env.example .env +# edit the file with your key +echo "OPENAI_API_KEY=your-key" > .env +``` + +All good. Now run start it: + +```bash +npm start +``` + +It will open a prompt where you can request for short snippets. It also works +for other stuff, for instance, to ask for examples of how to use a given +command from the coreutils. + +## LICENSE + +I don't care. AKA: MIT.