Skip to content

Commit

Permalink
Demonstrate install w/ local consumer package
Browse files Browse the repository at this point in the history
  • Loading branch information
amckinney committed Oct 30, 2024
1 parent b44d55c commit f744cbc
Show file tree
Hide file tree
Showing 8 changed files with 135 additions and 1 deletion.
11 changes: 11 additions & 0 deletions generators/go-v2/acme-snippets/.depcheckrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"ignores": [
"@types/jest",
"globals",
"@types/node",
"@fern-fern/ir-sdk"
],
"ignore-patterns": [
"lib"
]
}
1 change: 1 addition & 0 deletions generators/go-v2/acme-snippets/.prettierrc.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
module.exports = require("../../../.prettierrc.json");
51 changes: 51 additions & 0 deletions generators/go-v2/acme-snippets/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
{
"name": "@fern-api/acme-snippets",
"version": "0.0.0",
"repository": {
"type": "git",
"url": "https://github.com/fern-api/fern.git",
"directory": "generators/go-v2/acme-snippets"
},
"files": [
"lib"
],
"type": "module",
"source": "src/index.ts",
"main": "lib/index.js",
"types": "lib/index.d.ts",
"sideEffects": false,
"scripts": {
"clean": "rm -rf ./lib && tsc --build --clean",
"compile": "tsc --build",
"test": "vitest --run",
"test:update": "vitest --run -u",
"lint:eslint": "eslint --max-warnings 0 . --ignore-path=../../../.eslintignore",
"lint:eslint:fix": "yarn lint:eslint --fix",
"format": "prettier --write --ignore-unknown --ignore-path ../../../shared/.prettierignore \"**\"",
"format:check": "prettier --check --ignore-unknown --ignore-path ../../../shared/.prettierignore \"**\"",
"organize-imports": "organize-imports-cli tsconfig.json",
"depcheck": "depcheck"
},
"dependencies": {
"@fern-api/core-utils": "workspace:*",
"@fern-api/fs-utils": "workspace:*",
"@fern-api/generator-commons": "workspace:*",
"@fern-api/go-dynamic-snippets": "file:../dynamic-snippets/dist/fern-api-go-dynamic-snippets-0.0.0.tgz",
"@fern-fern/ir-sdk": "^53.15.0",
"zod": "^3.22.3"
},
"devDependencies": {
"@fern-api/fs-utils": "workspace:*",
"@fern-api/generator-commons": "workspace:*",
"@fern-fern/ir-sdk": "^53.15.0",
"@types/jest": "^29.5.12",
"@types/node": "^18.7.18",
"depcheck": "^1.4.6",
"eslint": "^8.56.0",
"organize-imports-cli": "^0.10.0",
"prettier": "^2.7.1",
"typescript": "4.6.4",
"vitest": "^2.0.5",
"zod": "^3.22.3"
}
}
7 changes: 7 additions & 0 deletions generators/go-v2/acme-snippets/src/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import { DynamicSnippetsGenerator } from "@fern-api/go-dynamic-snippets";

void main();

async function main() {
const generator = new DynamicSnippetsGenerator();
}
11 changes: 11 additions & 0 deletions generators/go-v2/acme-snippets/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"extends": "../../../shared/tsconfig.shared.json",
"compilerOptions": { "composite": true, "outDir": "lib", "rootDir": "src" },
"include": ["./src/**/*"],
"references": [
{ "path": "../../../packages/commons/core-utils" },
{ "path": "../../../packages/commons/fs-utils" },
{ "path": "../../../packages/commons/logging-execa" },
{ "path": "../../commons" }
]
}
1 change: 1 addition & 0 deletions generators/go-v2/acme-snippets/vitest.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export { default } from "../../../shared/vitest.config";
2 changes: 1 addition & 1 deletion generators/go-v2/dynamic-snippets/build.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ main();

async function main() {
await tsup.build({
entry: ['src/**/*.ts', '!src/**/__test__/**/*.ts'],
entry: ['src/**/*.ts', '!src/__test__'],
format: ['cjs'],
clean: true,
minify: true,
Expand Down
52 changes: 52 additions & 0 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit f744cbc

Please sign in to comment.