@aptre/common 0.34.1 → 0.34.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/.oxfmtrc.json ADDED
@@ -0,0 +1,9 @@
1
+ {
2
+ "$schema": "./node_modules/oxfmt/configuration_schema.json",
3
+ "semi": false,
4
+ "singleQuote": true,
5
+ "tabWidth": 2,
6
+ "printWidth": 80,
7
+ "sortPackageJson": false,
8
+ "ignorePatterns": ["node_modules", "dist", "vendor", ".tools"]
9
+ }
package/.oxlintrc.json ADDED
@@ -0,0 +1,133 @@
1
+ {
2
+ "$schema": "./node_modules/oxlint/configuration_schema.json",
3
+ "plugins": ["typescript", "unicorn"],
4
+ "categories": {
5
+ "correctness": "off"
6
+ },
7
+ "env": {
8
+ "builtin": true
9
+ },
10
+ "ignorePatterns": [
11
+ "node_modules/**",
12
+ "dist/**",
13
+ "vendor/**",
14
+ ".tools/**",
15
+ "coverage/**",
16
+ "example/target/**",
17
+ "**/*.pb.ts",
18
+ "**/*.pb.js"
19
+ ],
20
+ "rules": {
21
+ "constructor-super": "error",
22
+ "for-direction": "error",
23
+ "getter-return": "error",
24
+ "no-async-promise-executor": "error",
25
+ "no-case-declarations": "error",
26
+ "no-class-assign": "error",
27
+ "no-compare-neg-zero": "error",
28
+ "no-cond-assign": "error",
29
+ "no-const-assign": "error",
30
+ "no-constant-binary-expression": "error",
31
+ "no-constant-condition": "error",
32
+ "no-control-regex": "error",
33
+ "no-debugger": "error",
34
+ "no-delete-var": "error",
35
+ "no-dupe-class-members": "error",
36
+ "no-dupe-else-if": "error",
37
+ "no-dupe-keys": "error",
38
+ "no-duplicate-case": "error",
39
+ "no-empty": "error",
40
+ "no-empty-character-class": "error",
41
+ "no-empty-pattern": "error",
42
+ "no-empty-static-block": "error",
43
+ "no-ex-assign": "error",
44
+ "no-extra-boolean-cast": "error",
45
+ "no-fallthrough": "error",
46
+ "no-func-assign": "error",
47
+ "no-global-assign": "error",
48
+ "no-import-assign": "error",
49
+ "no-invalid-regexp": "error",
50
+ "no-irregular-whitespace": "error",
51
+ "no-loss-of-precision": "error",
52
+ "no-misleading-character-class": "error",
53
+ "no-new-native-nonconstructor": "error",
54
+ "no-nonoctal-decimal-escape": "error",
55
+ "no-obj-calls": "error",
56
+ "no-prototype-builtins": "error",
57
+ "no-redeclare": "error",
58
+ "no-regex-spaces": "error",
59
+ "no-self-assign": "error",
60
+ "no-setter-return": "error",
61
+ "no-shadow-restricted-names": "error",
62
+ "no-sparse-arrays": "error",
63
+ "no-this-before-super": "error",
64
+ "no-unassigned-vars": "error",
65
+ "no-unreachable": "error",
66
+ "no-unsafe-finally": "error",
67
+ "no-unsafe-negation": "error",
68
+ "no-unsafe-optional-chaining": "error",
69
+ "no-unused-labels": "error",
70
+ "no-unused-private-class-members": "error",
71
+ "no-unused-vars": [
72
+ "error",
73
+ {
74
+ "argsIgnorePattern": "^_",
75
+ "varsIgnorePattern": "^_",
76
+ "caughtErrors": "none"
77
+ }
78
+ ],
79
+ "no-useless-backreference": "error",
80
+ "no-useless-catch": "error",
81
+ "no-useless-escape": "error",
82
+ "no-with": "error",
83
+ "preserve-caught-error": "error",
84
+ "require-yield": "error",
85
+ "use-isnan": "error",
86
+ "valid-typeof": "error",
87
+ "no-array-constructor": "error",
88
+ "no-unused-expressions": "error",
89
+ "typescript/ban-ts-comment": "error",
90
+ "typescript/no-duplicate-enum-values": "error",
91
+ "typescript/no-explicit-any": "warn",
92
+ "typescript/no-extra-non-null-assertion": "error",
93
+ "typescript/no-misused-new": "error",
94
+ "typescript/no-namespace": "error",
95
+ "typescript/no-non-null-asserted-optional-chain": "error",
96
+ "typescript/no-require-imports": "error",
97
+ "typescript/no-this-alias": "error",
98
+ "typescript/no-unnecessary-type-constraint": "error",
99
+ "typescript/no-unsafe-declaration-merging": "error",
100
+ "typescript/no-unsafe-function-type": "error",
101
+ "typescript/no-wrapper-object-types": "error",
102
+ "typescript/prefer-as-const": "error",
103
+ "typescript/prefer-namespace-keyword": "error",
104
+ "typescript/triple-slash-reference": "error"
105
+ },
106
+ "overrides": [
107
+ {
108
+ "files": ["**/*.ts", "**/*.tsx", "**/*.mts", "**/*.cts"],
109
+ "rules": {
110
+ "constructor-super": "off",
111
+ "getter-return": "off",
112
+ "no-class-assign": "off",
113
+ "no-const-assign": "off",
114
+ "no-dupe-class-members": "off",
115
+ "no-dupe-keys": "off",
116
+ "no-func-assign": "off",
117
+ "no-import-assign": "off",
118
+ "no-new-native-nonconstructor": "off",
119
+ "no-obj-calls": "off",
120
+ "no-redeclare": "off",
121
+ "no-setter-return": "off",
122
+ "no-this-before-super": "off",
123
+ "no-unreachable": "off",
124
+ "no-unsafe-negation": "off",
125
+ "no-var": "error",
126
+ "no-with": "off",
127
+ "prefer-const": "error",
128
+ "prefer-rest-params": "error",
129
+ "prefer-spread": "error"
130
+ }
131
+ }
132
+ ]
133
+ }
package/README.md CHANGED
@@ -1,13 +1,11 @@
1
1
  # common
2
2
 
3
- [![GoDoc Widget]][GoDoc] [![Go Report Card Widget]][Go Report Card] [![npm Widget]][npm]
3
+ [![GoDoc Widget]][GoDoc] [![npm Widget]][npm]
4
4
 
5
5
  > Unified protobuf code generation for Go, TypeScript, C++, and Rust with WASM.
6
6
 
7
7
  [GoDoc]: https://godoc.org/github.com/aperturerobotics/common
8
8
  [GoDoc Widget]: https://godoc.org/github.com/aperturerobotics/common?status.svg
9
- [Go Report Card Widget]: https://goreportcard.com/badge/github.com/aperturerobotics/common
10
- [Go Report Card]: https://goreportcard.com/report/github.com/aperturerobotics/common
11
9
  [npm]: https://www.npmjs.com/package/@aptre/common
12
10
  [npm Widget]: https://img.shields.io/npm/v/@aptre/common.svg
13
11
 
@@ -209,9 +207,9 @@ Example:
209
207
  ### `aptre.languages`
210
208
 
211
209
  `languages` selects which output languages to generate. Supported values are
212
- `go`, `ts`, `cpp`, and `rust`. Omit it to keep the default behavior: generate
213
- Go, C++, and Rust when the project has a `go.mod`, plus TypeScript when the
214
- project has a `package.json`.
210
+ `go`, `ts`, `cpp`, `rust`, `csharp`, and `python`. C# and Python are opt-in.
211
+ Omit `languages` to preserve the existing default: generate Go, C++, and Rust
212
+ when the project has a `go.mod`, plus TypeScript when it has a `package.json`.
215
213
 
216
214
  The CLI flag takes precedence over `package.json`:
217
215
 
@@ -7,7 +7,7 @@ import { ProtoRpc } from 'starpc';
7
7
  * @generated from service example.Echoer
8
8
  */
9
9
  export declare const EchoerDefinition: {
10
- readonly typeName: "example.Echoer";
10
+ readonly typeName: 'example.Echoer';
11
11
  readonly methods: {
12
12
  /**
13
13
  * Echo returns the given message.
@@ -15,7 +15,7 @@ export declare const EchoerDefinition: {
15
15
  * @generated from rpc example.Echoer.Echo
16
16
  */
17
17
  readonly Echo: {
18
- readonly name: "Echo";
18
+ readonly name: 'Echo';
19
19
  readonly I: import("@aptre/protobuf-es-lite").MessageType<EchoMsg>;
20
20
  readonly O: import("@aptre/protobuf-es-lite").MessageType<EchoMsg>;
21
21
  readonly kind: MethodKind.Unary;
package/go.mod CHANGED
@@ -5,14 +5,14 @@ go 1.25.0
5
5
  require (
6
6
  github.com/aperturerobotics/abseil-cpp v0.0.0-20260131110040-4bb56e2f9017 // aperture-2
7
7
  github.com/aperturerobotics/cli v1.1.0
8
- github.com/aperturerobotics/go-protoc-gen-prost v0.0.0-20260329113538-218ccd8f20e0 // master
9
- github.com/aperturerobotics/go-protoc-wasi v0.0.0-20260329113540-600516012db3 // master
8
+ github.com/aperturerobotics/go-protoc-gen-prost v0.0.0-20260705010911-9f53feac967b // master
9
+ github.com/aperturerobotics/go-protoc-wasi v0.0.0-20260712054757-d8078c296c17 // master
10
10
  github.com/aperturerobotics/go-websocket v1.8.15-0.20260329113544-74dbfb8f11c6 // indirect
11
- github.com/aperturerobotics/json-iterator-lite v1.0.1-0.20251104042408-0c9eb8a3f726 // indirect
11
+ github.com/aperturerobotics/json-iterator-lite v1.1.0 // indirect
12
12
  github.com/aperturerobotics/protobuf v0.0.0-20260203024654-8201686529c4 // wasi
13
- github.com/aperturerobotics/protobuf-go-lite v0.14.0 // latest
14
- github.com/aperturerobotics/starpc v0.49.18 // master
15
- github.com/aperturerobotics/util v1.34.5 // indirect
13
+ github.com/aperturerobotics/protobuf-go-lite v0.16.0 // latest
14
+ github.com/aperturerobotics/starpc v0.49.21 // master
15
+ github.com/aperturerobotics/util v1.34.9 // indirect
16
16
  )
17
17
 
18
18
  require (
@@ -22,6 +22,6 @@ require (
22
22
  github.com/sirupsen/logrus v1.9.5-0.20260508084601-d4a50659cfd6 // indirect
23
23
  github.com/tetratelabs/wazero v1.12.0
24
24
  github.com/xrash/smetrics v0.0.0-20250705151800-55b8f293f342 // indirect
25
- golang.org/x/mod v0.37.0
26
- golang.org/x/sys v0.44.0 // indirect
25
+ golang.org/x/mod v0.38.0
26
+ golang.org/x/sys v0.47.0 // indirect
27
27
  )