synapse-compiler 0.0.0-stage → 0.2.2

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.
@@ -0,0 +1,19 @@
1
+ import type { CheckerPlugin } from '../types';
2
+ export interface CppPluginOptions {
3
+ /** 컴파일러 실행 파일 (기본값: 'g++') */
4
+ readonly compiler?: string;
5
+ /** C++ 표준 버전 (기본값: 'c++17') */
6
+ readonly std?: string;
7
+ /** C/C++ 소스 루트 디렉터리 (기본값: '.') */
8
+ readonly sourceDir?: string;
9
+ /** 추가 인클루드 경로 배열 */
10
+ readonly includeDirs?: readonly string[];
11
+ /** 추가 컴파일러 플래그 */
12
+ readonly extraArgs?: readonly string[];
13
+ /** 특정 진입점 소스 파일 배열 (미지정 시 sourceDir 내 C++ 파일 자동 탐색) */
14
+ readonly targetFiles?: readonly string[];
15
+ }
16
+ /**
17
+ * C/C++ 네이티브 커널 및 알고리즘 구문 검사 플러그인 (@synapse/plugin-cpp)
18
+ */
19
+ export declare function cppChecker(options?: CppPluginOptions): CheckerPlugin;
@@ -0,0 +1,13 @@
1
+ import type { CheckerPlugin } from '../types';
2
+ export interface CsharpPluginOptions {
3
+ /** 검증할 .NET 프로젝트/솔루션 경로 (기본값: '.') */
4
+ readonly projectPath?: string;
5
+ /** 빌드 구성 (기본값: 'Release') */
6
+ readonly configuration?: 'Debug' | 'Release';
7
+ /** 추가 dotnet CLI 플래그 */
8
+ readonly extraArgs?: readonly string[];
9
+ }
10
+ /**
11
+ * C# .NET 솔루션 및 프로젝트 정적 검증 플러그인 (@synapse/plugin-csharp)
12
+ */
13
+ export declare function csharpChecker(options?: CsharpPluginOptions): CheckerPlugin;
@@ -0,0 +1,15 @@
1
+ import type { CheckerPlugin } from '../types';
2
+ export interface GoPluginOptions {
3
+ /** Go 모듈 루트 디렉터리 (기본값: '.') */
4
+ readonly moduleDir?: string;
5
+ /** 정적 분석 대상 패키지 (기본값: './...') */
6
+ readonly targetPackage?: string;
7
+ /** 검증 명령 (기본값: 'vet') */
8
+ readonly checkCommand?: 'vet' | 'build';
9
+ /** 추가 go CLI 플래그 */
10
+ readonly extraArgs?: readonly string[];
11
+ }
12
+ /**
13
+ * Go 패키지 및 고루틴 정적 무결성 검증 플러그인 (@synapse/plugin-go)
14
+ */
15
+ export declare function goChecker(options?: GoPluginOptions): CheckerPlugin;
@@ -0,0 +1,16 @@
1
+ import type { CheckerPlugin } from '../types';
2
+ export interface JavaPluginOptions {
3
+ /** Java 소스 코드 루트 디렉터리 (기본값: './services/gateway' 또는 '.') */
4
+ readonly sourceDir?: string;
5
+ /** 바이트코드 출력 대상 디렉터리 (기본값: './target/java-classes') */
6
+ readonly outputDir?: string;
7
+ /** 특정 진입점 소스 파일 배열 (미지정 시 sourceDir 내 Java 파일 자동 탐색) */
8
+ readonly targetFiles?: readonly string[];
9
+ /** 추가 javac 아규먼트 */
10
+ readonly javacArgs?: readonly string[];
11
+ }
12
+ /**
13
+ * Project Synapse 공식 Java 언어 플러그인 (@synapse/plugin-java)
14
+ * javac 컴파일러를 통한 정적 타입 무결성 및 바이트코드 컴파일 검증
15
+ */
16
+ export declare function javaChecker(options?: JavaPluginOptions): CheckerPlugin;
@@ -0,0 +1,12 @@
1
+ import type { CheckerPlugin } from '../types';
2
+ export interface NativeBinaryTarget {
3
+ readonly path: string;
4
+ readonly expectedArchitecture?: 'x64' | 'arm64';
5
+ }
6
+ export interface NativePluginOptions {
7
+ readonly targets: readonly NativeBinaryTarget[];
8
+ }
9
+ /**
10
+ * 네이티브 바이너리 & 리소스 무결성 검사 플러그인 (@synapse/plugin-native)
11
+ */
12
+ export declare function nativeChecker(options: NativePluginOptions): CheckerPlugin;
@@ -0,0 +1,8 @@
1
+ import type { CheckerPlugin } from '../types';
2
+ export interface NsisPluginOptions {
3
+ readonly templatePath: string;
4
+ }
5
+ /**
6
+ * Windows NSIS 인스톨러 템플릿 검사 플러그인 (@synapse/plugin-nsis)
7
+ */
8
+ export declare function nsisChecker(options: NsisPluginOptions): CheckerPlugin;
@@ -0,0 +1,21 @@
1
+ import type { CheckerPlugin } from '../types';
2
+ export interface PythonPluginOptions {
3
+ /** Python 인터프리터 경로 (기본값: 'python') */
4
+ readonly pythonBin?: string;
5
+ /** Python 소스 루트 디렉터리 (기본값: '.') */
6
+ readonly sourceDir?: string;
7
+ /** 검증할 특정 파이썬 파일 목록 (미지정 시 자동 탐색) */
8
+ readonly targetFiles?: readonly string[];
9
+ /**
10
+ * 검증 모드 (기본값: 'fast')
11
+ * - 'fast': -S(site.py 초기화 생략), -B(디스크 쓰기 방지), compile() 인메모리 컴파일로 30ms대 초고속 AST/구문 무결성 검증
12
+ * - 'py_compile': 표준 py_compile 모듈 기반 컴파일
13
+ */
14
+ readonly mode?: 'fast' | 'py_compile';
15
+ /** 추가 파이썬 컴파일 플래그 */
16
+ readonly extraArgs?: readonly string[];
17
+ }
18
+ /**
19
+ * Python 바이트코드 구문 및 AST 무결성 검증 플러그인 (@synapse/plugin-python)
20
+ */
21
+ export declare function pythonChecker(options?: PythonPluginOptions): CheckerPlugin;
@@ -0,0 +1,9 @@
1
+ import type { CheckerPlugin } from '../types';
2
+ export interface RustPluginOptions {
3
+ readonly workspaceDir?: string;
4
+ readonly allTargets?: boolean;
5
+ }
6
+ /**
7
+ * Rust Cargo 워크스페이스 검사 플러그인 (@synapse/plugin-rust)
8
+ */
9
+ export declare function rustChecker(options?: RustPluginOptions): CheckerPlugin;
@@ -0,0 +1,12 @@
1
+ import type { CheckerPlugin } from '../types';
2
+ export interface SchemaTarget {
3
+ readonly path: string;
4
+ readonly validator?: (parsed: unknown) => string | null;
5
+ }
6
+ export interface SchemaPluginOptions {
7
+ readonly targets: readonly SchemaTarget[];
8
+ }
9
+ /**
10
+ * 대용량 데이터 및 설정 스키마 검사 플러그인 (@synapse/plugin-schema)
11
+ */
12
+ export declare function schemaChecker(options: SchemaPluginOptions): CheckerPlugin;
@@ -0,0 +1,10 @@
1
+ import type { CheckerPlugin } from '../types';
2
+ export interface SveltePluginOptions {
3
+ readonly tsconfig?: string;
4
+ readonly threshold?: 'warning' | 'error';
5
+ readonly appDir?: string;
6
+ }
7
+ /**
8
+ * Svelte 5 & TypeScript 정적 검사 플러그인 (@synapse/plugin-svelte)
9
+ */
10
+ export declare function svelteChecker(options?: SveltePluginOptions): CheckerPlugin;
@@ -0,0 +1,23 @@
1
+ import type { CheckerPlugin } from '../types';
2
+ export interface TypescriptPluginOptions {
3
+ /**
4
+ * 검증 도구 및 아키텍처 선택:
5
+ * - 'hybrid' (권장): 네이티브 Rust Oxc 0.1s Fast-Abort + 공식 tsc 증분 시맨틱 동시 병렬 융합
6
+ * - 'tsc': 100% 순수 TypeScript 공식 컴파일러 (무의존성)
7
+ * - 'tsrs': 네이티브 Rust Oxc 단독 가속 모드
8
+ * @default 'hybrid'
9
+ */
10
+ readonly tool?: 'hybrid' | 'tsc' | 'tsrs';
11
+ /** tsconfig.json 파일 경로 (기본값: './tsconfig.json') */
12
+ readonly tsconfig?: string;
13
+ /** 네이티브 tsrs 실행 파일 경로 (미지정 시 자동 탐색) */
14
+ readonly tsrsPath?: string;
15
+ /** 추가 CLI 플래그 */
16
+ readonly extraArgs?: readonly string[];
17
+ }
18
+ /**
19
+ * TypeScript 정적 타입 및 구문 검사 플러그인 (@synapse/plugin-typescript)
20
+ * 2개 조합 하이브리드 융합 엔진 탑재:
21
+ * 네이티브 0.1s Fast-Abort 게이트 + 순수 tsc 증분 시맨틱 캐시의 동시 병렬 경합
22
+ */
23
+ export declare function typescriptChecker(options?: TypescriptPluginOptions): CheckerPlugin;
@@ -0,0 +1,72 @@
1
+ /**
2
+ * 프로젝트 시냅스(Project Synapse) 프레임워크 핵심 타입 시스템
3
+ */
4
+ export type CheckStatus = 'success' | 'warning' | 'error' | 'skipped';
5
+ export interface DiagnosticItem {
6
+ readonly file?: string;
7
+ readonly line?: number;
8
+ readonly column?: number;
9
+ readonly message: string;
10
+ readonly severity: 'error' | 'warning';
11
+ }
12
+ export interface CheckResult {
13
+ readonly name: string;
14
+ readonly title: string;
15
+ readonly status: CheckStatus;
16
+ readonly durationMs: number;
17
+ readonly details: string;
18
+ readonly diagnostics?: readonly DiagnosticItem[];
19
+ }
20
+ export interface SynapseContext {
21
+ readonly rootDir: string;
22
+ readonly options: SynapseOptions;
23
+ }
24
+ export interface CheckerPlugin {
25
+ readonly name: string;
26
+ readonly title: string;
27
+ readonly triggers: readonly string[];
28
+ readonly check: (ctx: SynapseContext) => Promise<CheckResult>;
29
+ }
30
+ export interface BuildTrack {
31
+ readonly name: string;
32
+ readonly command: readonly string[];
33
+ readonly cwd?: string;
34
+ readonly sources?: readonly string[];
35
+ readonly artifacts?: readonly string[];
36
+ }
37
+ export interface PackageConfig {
38
+ readonly framework?: 'tauri' | 'custom';
39
+ readonly targets?: readonly string[];
40
+ readonly compression?: 'zlib' | 'bzip2' | 'lzma' | 'off';
41
+ readonly tauriConfPath?: string;
42
+ }
43
+ export interface SignConfig {
44
+ readonly privateKeyPath: string;
45
+ readonly targetInstaller?: string;
46
+ readonly passwordEnv?: string;
47
+ }
48
+ export interface SynapseConfig {
49
+ readonly rootDir?: string;
50
+ readonly aiMemory?: {
51
+ readonly enabled?: boolean;
52
+ readonly smartSkipping?: boolean;
53
+ };
54
+ readonly plugins: readonly CheckerPlugin[];
55
+ readonly buildTracks?: readonly BuildTrack[];
56
+ readonly package?: PackageConfig;
57
+ readonly sign?: SignConfig;
58
+ }
59
+ export interface SynapseOptions {
60
+ readonly mode: 'smart' | 'all';
61
+ readonly agentMode: boolean;
62
+ readonly compactMode: boolean;
63
+ readonly watch: boolean;
64
+ readonly interactive?: boolean;
65
+ readonly force?: boolean;
66
+ }
67
+ export interface CausalDecision {
68
+ readonly runAll: boolean;
69
+ readonly activePluginNames: ReadonlySet<string>;
70
+ readonly reason: string;
71
+ readonly modifiedFiles: readonly string[];
72
+ }
package/package.json CHANGED
@@ -1,6 +1,43 @@
1
1
  {
2
2
  "name": "synapse-compiler",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
3
+ "version": "0.2.2",
4
+ "description": "Blazing-fast polyglot compiler & incremental verification engine for 10 languages and systems",
5
+ "type": "module",
6
+ "main": "dist/index.js",
7
+ "types": "dist/index.d.ts",
8
+ "bin": {
9
+ "synapse": "./dist/cli.js",
10
+ "synapse-compiler": "./dist/cli.js"
11
+ },
12
+ "files": [
13
+ "dist",
14
+ "README.md",
15
+ "LICENSE"
16
+ ],
17
+ "publishConfig": {
18
+ "access": "public"
19
+ },
20
+ "scripts": {
21
+ "build:bundle": "bun build cli.ts --outfile dist/cli.js --target bun && bun build index.ts --outfile dist/index.js --target bun",
22
+ "build:types": "tsc -p tsconfig.build.json",
23
+ "build": "bun run build:bundle && bun run build:types",
24
+ "prepublishOnly": "bun run build"
25
+ },
26
+ "repository": {
27
+ "type": "git",
28
+ "url": "git+https://github.com/minseokk77/synapse-kit.git",
29
+ "directory": "compiler"
30
+ },
31
+ "keywords": [
32
+ "compiler",
33
+ "verification",
34
+ "polyglot",
35
+ "monorepo",
36
+ "rust",
37
+ "svelte",
38
+ "typescript",
39
+ "bun"
40
+ ],
41
+ "author": "Vesper",
42
+ "license": "MIT"
43
+ }