-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Move typescript package into subdirectory (#170)
### Changelog None ### Docs None ### Description Migrate `@foxglove/schemas` typescript package into `typescript` directory. This prepares for other typescript packages to live in this repo. Also restrict to only necessary files included in the npm package.
- Loading branch information
Showing
85 changed files
with
176 additions
and
71 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,19 @@ | ||
.catkin_tools | ||
.DS_Store | ||
.idea/ | ||
.mypy_cache/ | ||
.pytest_cache/ | ||
.yarn/ | ||
.idea/ | ||
*.py[cod] | ||
*.so | ||
/python/**/dist/ | ||
*.tsbuildinfo | ||
/python/*/dist/ | ||
/python/foxglove-schemas-flatbuffer/foxglove_schemas_flatbuffer/*.bfbs | ||
/python/foxglove-schemas-flatbuffer/foxglove_schemas_flatbuffer/*.py | ||
/python/foxglove-schemas-protobuf/foxglove_schemas_protobuf/*.py | ||
/python/foxglove-schemas-protobuf/foxglove_schemas_protobuf/*.pyi | ||
/python/foxglove-sdk/python/foxglove/_protobuf/ | ||
/target/ | ||
/typescript/*/dist/ | ||
/typescript/schemas/src/jsonschema/ | ||
node_modules/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,16 @@ | ||
{ | ||
"name": "@foxglove/schemas", | ||
"version": "1.6.6", | ||
"description": "Foxglove-defined message schemas for ROS, Protobuf, FlatBuffers, OMG IDL, and JSON", | ||
"license": "MIT", | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/foxglove/schemas.git" | ||
}, | ||
"author": { | ||
"name": "Foxglove Technologies Inc", | ||
"email": "[email protected]" | ||
}, | ||
"engines": { | ||
"node": ">=16" | ||
}, | ||
"name": "foxglove-sdk", | ||
"private": true, | ||
"packageManager": "[email protected]", | ||
"main": "schemas/typescript/index.js", | ||
"typings": "schemas/typescript/index.d.ts", | ||
"workspaces": [ | ||
"typescript/*" | ||
], | ||
"scripts": { | ||
"prepack": "yarn update-generated-files && tsc -p tsconfig.json", | ||
"typecheck": "tsc -p tsconfig.json --noEmit", | ||
"build": "tsc -b", | ||
"lint:ci": "eslint --report-unused-disable-directives .", | ||
"lint": "eslint --report-unused-disable-directives --fix .", | ||
"test": "jest", | ||
"update-generated-files": "yarn test --updateSnapshot && ts-node --files --project tsconfig.json ./scripts/updateGeneratedFiles.ts --out-dir schemas --ros-out-dir ros_foxglove_msgs" | ||
"update-generated-files": "ts-node --files --project tsconfig.json ./scripts/updateGeneratedFiles.ts --out-dir schemas --ros-out-dir ros_foxglove_msgs && yarn test --updateSnapshot" | ||
}, | ||
"devDependencies": { | ||
"@foxglove/eslint-plugin": "2.0.0", | ||
|
@@ -43,6 +30,7 @@ | |
"eslint-plugin-import": "2.31.0", | ||
"eslint-plugin-jest": "28.11.0", | ||
"eslint-plugin-prettier": "5.2.3", | ||
"globals": "^15.14.0", | ||
"jest": "29.7.0", | ||
"prettier": "^3.4.2", | ||
"prettier-plugin-toml": "^2.0.1", | ||
|
@@ -51,9 +39,5 @@ | |
"ts-jest": "29.2.5", | ||
"ts-node": "^10.9.2", | ||
"typescript": "5.7.3" | ||
}, | ||
"dependencies": { | ||
"@foxglove/rosmsg-msgs-common": "^3.0.0", | ||
"tslib": "^2.8.1" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
# @foxglove/schemas | ||
|
||
This package contains TypeScript type definitions and JSON Schemas for the Foxglove schemas. | ||
|
||
## Installation | ||
|
||
```bash | ||
npm install @foxglove/schemas | ||
``` | ||
|
||
## Usage | ||
|
||
For a list of available schemas, see https://docs.foxglove.dev/docs/visualization/message-schemas/introduction | ||
|
||
```ts | ||
import type { CompressedImage } from '@foxglove/schemas'; | ||
import { CompressedImage } from '@foxglove/schemas/jsonschema'; | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export * from "./dist/internal/index"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
// allows importing @foxglove/schemas/internal | ||
module.exports = require("./dist/internal/index.js"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export * from "./dist/jsonschema/index"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
// allows importing @foxglove/schemas/jsonschema | ||
module.exports = require("./dist/jsonschema/index.js"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
{ | ||
"name": "@foxglove/schemas", | ||
"version": "1.6.6", | ||
"description": "Foxglove-defined message schemas for ROS, Protobuf, FlatBuffers, OMG IDL, and JSON", | ||
"license": "MIT", | ||
"author": { | ||
"name": "Foxglove", | ||
"email": "[email protected]", | ||
"url": "https://foxglove.dev/" | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "git+https://github.com/foxglove/foxglove-sdk.git", | ||
"directory": "typescript/schemas" | ||
}, | ||
"main": "./dist/index.js", | ||
"types": "./dist/index.d.ts", | ||
"files": [ | ||
"dist", | ||
"internal.d.ts", | ||
"internal.js", | ||
"jsonschema.d.ts", | ||
"jsonschema.js" | ||
], | ||
"packageManager": "[email protected]", | ||
"scripts": { | ||
"build": "cp -R ../../schemas/jsonschema ./src/jsonschema && tsc -b", | ||
"clean": "git clean -Xdf", | ||
"prepack": "yarn clean && yarn build" | ||
}, | ||
"dependencies": { | ||
"tslib": "^2" | ||
}, | ||
"devDependencies": { | ||
"@foxglove/rosmsg-msgs-common": "^3.0.0", | ||
"rimraf": "^6.0.1", | ||
"typescript": "5.7.3" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export * from "./types/index"; |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
// This file only exists to ensure the jsonschema directory was copied. | ||
// If you get an build error you need to run `yarn build` first. | ||
export * from "./jsonschema/index"; |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"extends": "@foxglove/tsconfig/base", | ||
"include": ["./**/*"], | ||
"compilerOptions": { | ||
"rootDir": "./src", | ||
"outDir": "./dist", | ||
"module": "commonjs", | ||
"lib": ["es2020"], | ||
"noEmit": false | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters