Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: improve deno readme #429

Merged
merged 1 commit into from
Nov 6, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 9 additions & 5 deletions build-deno
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,24 @@ set -exuo pipefail
rm -rf deno; mkdir deno
cp -rp src/* deno

PACKAGE_VERSION=$(node -p 'require("./package.json").version')

cat << EOF > deno/README.md
# OpenAI Node API Library - Deno build

This is a build produced from openai/openai-node - please go there to read the source, file issues, etc.
This is a build produced from https://github.com/openai/openai-node - please go there to read the source and docs, file issues, etc.

Installation:
Usage:

\`\`\`
import OpenAI from "https://deno.land/x/openai";
\`\`\`ts
import OpenAI from "https://deno.land/x/openai@$PACKAGE_VERSION/mod.ts";

const client = new OpenAI();
\`\`\`

Note that in many Deno environments, you can also do this:

\`\`\`
\`\`\`ts
import OpenAI from "npm:openai";
\`\`\`
EOF
Expand Down