Skip to content

Commit

Permalink
feat: allow installing package directly from github (#215)
Browse files Browse the repository at this point in the history
  • Loading branch information
stainless-bot committed Nov 21, 2023
1 parent 4ab77b7 commit 3de3f1b
Show file tree
Hide file tree
Showing 3 changed files with 53 additions and 42 deletions.
79 changes: 40 additions & 39 deletions package.json
@@ -1,14 +1,53 @@
{
"name": "@anthropic-ai/sdk",
"version": "0.9.1",
"description": "Client library for the Anthropic API",
"description": "The official TypeScript library for the Anthropic API",
"author": "Anthropic <support@anthropic.com>",
"types": "dist/index.d.ts",
"main": "dist/index.js",
"type": "commonjs",
"repository": "github:anthropics/anthropic-sdk-typescript",
"license": "MIT",
"private": false,
"scripts": {
"test": "bin/check-test-server && yarn jest",
"build": "bash ./build",
"prepack": "echo 'to pack, run yarn build && (cd dist; yarn pack)' && exit 1",
"prepublishOnly": "echo 'to publish, run yarn build && (cd dist; yarn publish)' && exit 1",
"format": "prettier --write --cache --cache-strategy metadata . !dist",
"prepare": "npm run build",
"tsn": "ts-node -r tsconfig-paths/register",
"lint": "eslint --ext ts,js .",
"fix": "eslint --fix --ext ts,js ."
},
"dependencies": {
"@types/node": "^18.11.18",
"@types/node-fetch": "^2.6.4",
"abort-controller": "^3.0.0",
"agentkeepalive": "^4.2.1",
"digest-fetch": "^1.3.0",
"form-data-encoder": "1.7.2",
"formdata-node": "^4.3.2",
"node-fetch": "^2.6.7",
"web-streams-polyfill": "^3.2.1"
},
"devDependencies": {
"@types/jest": "^29.4.0",
"@typescript-eslint/eslint-plugin": "^6.7.0",
"@typescript-eslint/parser": "^6.7.0",
"@anthropic-ai/sdk": "file:.",
"eslint": "^8.49.0",
"eslint-plugin-prettier": "^4.0.0",
"eslint-plugin-unused-imports": "^2.0.0",
"jest": "^29.4.0",
"prettier": "rattrayalex/prettier#postfix-ternaries",
"ts-jest": "^29.1.0",
"ts-morph": "^19.0.0",
"ts-node": "^10.5.0",
"tsc-multi": "^1.1.0",
"tsconfig-paths": "^4.0.0",
"typescript": "^4.8.2"
},
"sideEffects": [
"./_shims/index.js",
"./_shims/index.mjs",
Expand Down Expand Up @@ -74,43 +113,5 @@
"require": "./dist/*.js",
"default": "./dist/*.mjs"
}
},
"scripts": {
"test": "bin/check-test-server && yarn jest",
"build": "bash ./build",
"prepack": "echo 'to pack, run yarn build && (cd dist; yarn pack)' && exit 1",
"prepublishOnly": "echo 'to publish, run yarn build && (cd dist; yarn publish)' && exit 1",
"format": "prettier --write --cache --cache-strategy metadata . !dist",
"tsn": "ts-node -r tsconfig-paths/register",
"lint": "eslint --ext ts,js .",
"fix": "eslint --fix --ext ts,js ."
},
"dependencies": {
"@types/node": "^18.11.18",
"@types/node-fetch": "^2.6.4",
"abort-controller": "^3.0.0",
"agentkeepalive": "^4.2.1",
"digest-fetch": "^1.3.0",
"form-data-encoder": "1.7.2",
"formdata-node": "^4.3.2",
"node-fetch": "^2.6.7",
"web-streams-polyfill": "^3.2.1"
},
"devDependencies": {
"@types/jest": "^29.4.0",
"@typescript-eslint/eslint-plugin": "^6.7.0",
"@typescript-eslint/parser": "^6.7.0",
"@anthropic-ai/sdk": "link:.",
"eslint": "^8.49.0",
"eslint-plugin-prettier": "^4.0.0",
"eslint-plugin-unused-imports": "^2.0.0",
"jest": "^29.4.0",
"prettier": "rattrayalex/prettier#postfix-ternaries",
"ts-jest": "^29.1.0",
"ts-morph": "^19.0.0",
"ts-node": "^10.5.0",
"tsc-multi": "^1.1.0",
"tsconfig-paths": "^4.0.0",
"typescript": "^4.8.2"
}
}
1 change: 1 addition & 0 deletions scripts/make-dist-package-json.cjs
Expand Up @@ -16,5 +16,6 @@ for (const key of ['types', 'main', 'module']) {
delete pkgJson.devDependencies;
delete pkgJson.scripts.prepack;
delete pkgJson.scripts.prepublishOnly;
delete pkgJson.scripts.postinstall;

console.log(JSON.stringify(pkgJson, null, 2));
15 changes: 12 additions & 3 deletions yarn.lock
Expand Up @@ -22,9 +22,18 @@
dependencies:
tslib "^2.2.0"

"@anthropic-ai/sdk@link:.":
version "0.0.0"
uid ""
"@anthropic-ai/sdk@file:.":
version "0.9.1"
dependencies:
"@types/node" "^18.11.18"
"@types/node-fetch" "^2.6.4"
abort-controller "^3.0.0"
agentkeepalive "^4.2.1"
digest-fetch "^1.3.0"
form-data-encoder "1.7.2"
formdata-node "^4.3.2"
node-fetch "^2.6.7"
web-streams-polyfill "^3.2.1"

"@babel/code-frame@7.18.6":
version "7.18.6"
Expand Down

0 comments on commit 3de3f1b

Please sign in to comment.