@jakubmazanec/carson 0.3.0-next.dc4435e → 0.3.0-next.f3375f0

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/README.md CHANGED
@@ -33,7 +33,7 @@ npm install @jakubmazanec/carson @jakubmazanec/carson-templates -g
33
33
 
34
34
  #### Prerequisites
35
35
 
36
- - Node.js 16 or later
36
+ - Node.js 20 or later
37
37
 
38
38
  ## Usage
39
39
 
@@ -73,19 +73,19 @@ Take a look at this simplified example of a workspace:
73
73
  ```
74
74
  workspace/
75
75
  ├── .carson/
76
- │ ├── .snapshots
76
+ │ ├── workspace.snapshot
77
77
  │ └── workspace.json
78
78
  ├── packages/
79
79
  │ ├── foo/
80
80
  │ │ ├── .carson/
81
- │ │ │ ├── .snapshots
81
+ │ │ │ ├── project.snapshot
82
82
  │ │ │ └── project.json
83
83
  │ │ ├── src/
84
84
  │ │ │ └── main.js
85
85
  │ │ └── package.json
86
86
  │ └── bar/
87
87
  │ ├── .carson/
88
- │ │ ├── .snapshots
88
+ │ │ ├── project.snapshot
89
89
  │ │ └── project.json
90
90
  │ ├── src/
91
91
  │ │ └── main.js
@@ -1,3 +1,5 @@
1
- export { };
1
+ /**
2
+ * Carson template.
3
+ */ export { };
2
4
 
3
5
  //# sourceMappingURL=CarsonTemplate.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/template/CarsonTemplate.ts"],"sourcesContent":["import {type Template} from '@jakubmazanec/template';\n\nimport {type CarsonTemplateConfig} from './CarsonTemplateConfig.js';\nimport {type templateAttributesSchema} from './TemplateAttributes.js';\nimport {type templateDataSchema} from './TemplateData.js';\n\n/**\n * Carson template.\n */\nexport type CarsonTemplate = {\n /** Carson template name. */\n name: string;\n\n /** Carson template config. */\n config: CarsonTemplateConfig;\n\n /** Carson template files, actually instances of {@link Template}. */\n files: Array<Template<typeof templateAttributesSchema, typeof templateDataSchema>>;\n};\n"],"names":[],"mappings":"AAAA,WAkBE"}
1
+ {"version":3,"sources":["../../src/template/CarsonTemplate.ts"],"sourcesContent":["import {type Template} from '@jakubmazanec/template';\n\nimport {type CarsonTemplateConfig} from './CarsonTemplateConfig.js';\nimport {type templateAttributesSchema} from './TemplateAttributes.js';\nimport {type templateDataSchema} from './TemplateData.js';\n\n/**\n * Carson template.\n */\nexport type CarsonTemplate = {\n /** Carson template name. */\n name: string;\n\n /** Carson template config. */\n config: CarsonTemplateConfig;\n\n /** Carson template files, actually instances of {@link Template}. */\n files: Array<Template<typeof templateAttributesSchema, typeof templateDataSchema>>;\n};\n"],"names":[],"mappings":"AAMA;;CAEC,GACD,WASE"}
@@ -1,3 +1,5 @@
1
- export { };
1
+ /**
2
+ * A result of rendering a Carson template file.
3
+ */ export { };
2
4
 
3
5
  //# sourceMappingURL=TemplateRender.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/template/TemplateRender.ts"],"sourcesContent":["import {type TemplateRender as BaseTemplateRender} from '@jakubmazanec/template';\n\nimport {type templateAttributesSchema} from './TemplateAttributes.js';\nimport {type templateDataSchema} from './TemplateData.js';\n\n/**\n * A result of rendering a Carson template file.\n */\nexport type TemplateRender = BaseTemplateRender<\n typeof templateAttributesSchema,\n typeof templateDataSchema\n> & {\n template: {\n path: string;\n };\n};\n"],"names":[],"mappings":"AAAA,WAeE"}
1
+ {"version":3,"sources":["../../src/template/TemplateRender.ts"],"sourcesContent":["import {type TemplateRender as BaseTemplateRender} from '@jakubmazanec/template';\n\nimport {type templateAttributesSchema} from './TemplateAttributes.js';\nimport {type templateDataSchema} from './TemplateData.js';\n\n/**\n * A result of rendering a Carson template file.\n */\nexport type TemplateRender = BaseTemplateRender<\n typeof templateAttributesSchema,\n typeof templateDataSchema\n> & {\n template: {\n path: string;\n };\n};\n"],"names":[],"mappings":"AAKA;;CAEC,GACD,WAOE"}
@@ -1,3 +1,5 @@
1
- export { };
1
+ /**
2
+ * A {@link TemplateRender} collection.
3
+ */ export { };
2
4
 
3
5
  //# sourceMappingURL=TemplateRenders.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/template/TemplateRenders.ts"],"sourcesContent":["import {type TemplateRender} from './TemplateRender.js';\n\n/**\n * A {@link TemplateRender} collection.\n */\nexport type TemplateRenders = TemplateRender[];\n"],"names":[],"mappings":"AAAA,WAK+C"}
1
+ {"version":3,"sources":["../../src/template/TemplateRenders.ts"],"sourcesContent":["import {type TemplateRender} from './TemplateRender.js';\n\n/**\n * A {@link TemplateRender} collection.\n */\nexport type TemplateRenders = TemplateRender[];\n"],"names":[],"mappings":"AAEA;;CAEC,GACD,WAA+C"}
@@ -1,3 +1,5 @@
1
- export { };
1
+ /**
2
+ * {@link Project.create | Project.create} options parameter.
3
+ */ export { };
2
4
 
3
5
  //# sourceMappingURL=ProjectCreateOptions.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/workspace/ProjectCreateOptions.ts"],"sourcesContent":["import {type Workspace} from './Workspace.js';\n\n/**\n * {@link Project.create | Project.create} options parameter.\n */\nexport type ProjectCreateOptions<M extends boolean> = {\n templateId: string;\n workspace: Workspace<M>;\n projectPath: string;\n projectName: string;\n args: Record<string, unknown>;\n};\n"],"names":[],"mappings":"AAAA,WAWE"}
1
+ {"version":3,"sources":["../../src/workspace/ProjectCreateOptions.ts"],"sourcesContent":["import {type Workspace} from './Workspace.js';\n\n/**\n * {@link Project.create | Project.create} options parameter.\n */\nexport type ProjectCreateOptions<M extends boolean> = {\n templateId: string;\n workspace: Workspace<M>;\n projectPath: string;\n projectName: string;\n args: Record<string, unknown>;\n};\n"],"names":[],"mappings":"AAEA;;CAEC,GACD,WAME"}
@@ -1,3 +1,5 @@
1
- export { };
1
+ /**
2
+ * {@link Project.constructor | Project constructor} options parameter.
3
+ */ export { };
2
4
 
3
5
  //# sourceMappingURL=ProjectOptions.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/workspace/ProjectOptions.ts"],"sourcesContent":["import {type PackageJson} from '@jakubmazanec/zod-utils';\n\nimport {type ProjectConfig} from './ProjectConfig.js';\nimport {type ProjectError} from './ProjectError.js';\nimport {type Workspace} from './Workspace.js';\n\n/**\n * {@link Project.constructor | Project constructor} options parameter.\n */\nexport type ProjectOptions<M extends boolean> = {\n path: string;\n name?: string;\n config?: ProjectConfig;\n packageJson?: PackageJson;\n workspace: Workspace<M>;\n errors?: Array<InstanceType<typeof ProjectError>>;\n};\n"],"names":[],"mappings":"AAAA,WAgBE"}
1
+ {"version":3,"sources":["../../src/workspace/ProjectOptions.ts"],"sourcesContent":["import {type PackageJson} from '@jakubmazanec/zod-utils';\n\nimport {type ProjectConfig} from './ProjectConfig.js';\nimport {type ProjectError} from './ProjectError.js';\nimport {type Workspace} from './Workspace.js';\n\n/**\n * {@link Project.constructor | Project constructor} options parameter.\n */\nexport type ProjectOptions<M extends boolean> = {\n path: string;\n name?: string;\n config?: ProjectConfig;\n packageJson?: PackageJson;\n workspace: Workspace<M>;\n errors?: Array<InstanceType<typeof ProjectError>>;\n};\n"],"names":[],"mappings":"AAMA;;CAEC,GACD,WAOE"}
@@ -1,3 +1,5 @@
1
- export { };
1
+ /**
2
+ * Dependency is an external piece of software (e.g. a package) that is installed in a {@link Workspace | a workspace} and usually required by one or more of its {@link Project | projects}.
3
+ */ export { };
2
4
 
3
5
  //# sourceMappingURL=WorkspaceDependency.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/workspace/WorkspaceDependency.ts"],"sourcesContent":["import {type WorkspaceDependencyProject} from './WorkspaceDependencyProject.js';\n\n/**\n * Dependency is an external piece of software (e.g. a package) that is installed in a {@link Workspace | a workspace} and usually required by one or more of its {@link Project | projects}.\n */\nexport type WorkspaceDependency = {\n /** Dependency name. */\n name: string;\n\n /** List of SemVer version ranges of the dependency that are installed in the workspace. */\n versions: string[];\n\n /** List of exact versions of the dependency that are installed in the workspace. */\n exactVersions: string[];\n\n /** Collection of projects that require the dependency. */\n projects: WorkspaceDependencyProject[];\n};\n"],"names":[],"mappings":"AAAA,WAiBE"}
1
+ {"version":3,"sources":["../../src/workspace/WorkspaceDependency.ts"],"sourcesContent":["import {type WorkspaceDependencyProject} from './WorkspaceDependencyProject.js';\n\n/**\n * Dependency is an external piece of software (e.g. a package) that is installed in a {@link Workspace | a workspace} and usually required by one or more of its {@link Project | projects}.\n */\nexport type WorkspaceDependency = {\n /** Dependency name. */\n name: string;\n\n /** List of SemVer version ranges of the dependency that are installed in the workspace. */\n versions: string[];\n\n /** List of exact versions of the dependency that are installed in the workspace. */\n exactVersions: string[];\n\n /** Collection of projects that require the dependency. */\n projects: WorkspaceDependencyProject[];\n};\n"],"names":[],"mappings":"AAEA;;CAEC,GACD,WAYE"}
@@ -1,3 +1,5 @@
1
- export { };
1
+ /**
2
+ * {@link Workspace.constructor | Workspace constructor} options parameter.
3
+ */ export { };
2
4
 
3
5
  //# sourceMappingURL=WorkspaceOptions.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/workspace/WorkspaceOptions.ts"],"sourcesContent":["import {type PackageJson} from '@jakubmazanec/zod-utils';\n\nimport {type WorkspaceConfig} from './WorkspaceConfig.js';\nimport {type WorkspaceError} from './WorkspaceError.js';\nimport {type WorkspaceOptionsProject} from './WorkspaceOptionsProject.js';\nimport {type WorkspaceRepository} from './WorkspaceRepository.js';\n\n/**\n * {@link Workspace.constructor | Workspace constructor} options parameter.\n */\nexport type WorkspaceOptions<M extends boolean> = M extends true\n ? {\n path: string;\n isMultiProject?: M;\n projectGlobs?: string[];\n projects?: WorkspaceOptionsProject[];\n config?: WorkspaceConfig;\n packageJson?: PackageJson;\n repository?: WorkspaceRepository;\n errors?: Array<InstanceType<typeof WorkspaceError>>;\n }\n : {\n path: string;\n isMultiProject?: M;\n projects?: [WorkspaceOptionsProject];\n config?: WorkspaceConfig;\n repository?: WorkspaceRepository;\n errors?: Array<InstanceType<typeof WorkspaceError>>;\n };\n"],"names":[],"mappings":"AAAA,WA4BM"}
1
+ {"version":3,"sources":["../../src/workspace/WorkspaceOptions.ts"],"sourcesContent":["import {type PackageJson} from '@jakubmazanec/zod-utils';\n\nimport {type WorkspaceConfig} from './WorkspaceConfig.js';\nimport {type WorkspaceError} from './WorkspaceError.js';\nimport {type WorkspaceOptionsProject} from './WorkspaceOptionsProject.js';\nimport {type WorkspaceRepository} from './WorkspaceRepository.js';\n\n/**\n * {@link Workspace.constructor | Workspace constructor} options parameter.\n */\nexport type WorkspaceOptions<M extends boolean> = M extends true\n ? {\n path: string;\n isMultiProject?: M;\n projectGlobs?: string[];\n projects?: WorkspaceOptionsProject[];\n config?: WorkspaceConfig;\n packageJson?: PackageJson;\n repository?: WorkspaceRepository;\n errors?: Array<InstanceType<typeof WorkspaceError>>;\n }\n : {\n path: string;\n isMultiProject?: M;\n projects?: [WorkspaceOptionsProject];\n config?: WorkspaceConfig;\n repository?: WorkspaceRepository;\n errors?: Array<InstanceType<typeof WorkspaceError>>;\n };\n"],"names":[],"mappings":"AAOA;;CAEC,GACD,WAkBM"}
@@ -1,3 +1,5 @@
1
- export { };
1
+ /**
2
+ * Type alias for {@link WorkspaceOptions.projects | WorkspaceOptions.projects} property.
3
+ */ export { };
2
4
 
3
5
  //# sourceMappingURL=WorkspaceOptionsProject.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/workspace/WorkspaceOptionsProject.ts"],"sourcesContent":["import {type PackageJson} from '@jakubmazanec/zod-utils';\n\nimport {type ProjectConfig} from './ProjectConfig.js';\n\n/**\n * Type alias for {@link WorkspaceOptions.projects | WorkspaceOptions.projects} property.\n */\nexport type WorkspaceOptionsProject = {\n path: string;\n config?: ProjectConfig;\n packageJson?: PackageJson;\n};\n"],"names":[],"mappings":"AAAA,WAWE"}
1
+ {"version":3,"sources":["../../src/workspace/WorkspaceOptionsProject.ts"],"sourcesContent":["import {type PackageJson} from '@jakubmazanec/zod-utils';\n\nimport {type ProjectConfig} from './ProjectConfig.js';\n\n/**\n * Type alias for {@link WorkspaceOptions.projects | WorkspaceOptions.projects} property.\n */\nexport type WorkspaceOptionsProject = {\n path: string;\n config?: ProjectConfig;\n packageJson?: PackageJson;\n};\n"],"names":[],"mappings":"AAIA;;CAEC,GACD,WAIE"}
@@ -1,3 +1,5 @@
1
- export { };
1
+ /**
2
+ * Type alias for {@link Workspace.packageJson | Workspace.packageJson} property.
3
+ */ export { };
2
4
 
3
5
  //# sourceMappingURL=WorkspacePackageJson.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/workspace/WorkspacePackageJson.ts"],"sourcesContent":["import {type PackageJson} from '@jakubmazanec/zod-utils';\n\n/**\n * Type alias for {@link Workspace.packageJson | Workspace.packageJson} property.\n */\nexport type WorkspacePackageJson<M extends boolean> = M extends true ? PackageJson : null;\n"],"names":[],"mappings":"AAAA,WAK0F"}
1
+ {"version":3,"sources":["../../src/workspace/WorkspacePackageJson.ts"],"sourcesContent":["import {type PackageJson} from '@jakubmazanec/zod-utils';\n\n/**\n * Type alias for {@link Workspace.packageJson | Workspace.packageJson} property.\n */\nexport type WorkspacePackageJson<M extends boolean> = M extends true ? PackageJson : null;\n"],"names":[],"mappings":"AAEA;;CAEC,GACD,WAA0F"}
@@ -1,3 +1,5 @@
1
- export { }; // TODO: should be `M extends true ? Array<Project<M>> : [Project<M>?]`; change when this is fixed: https://github.com/microsoft/TypeScript/issues/54302
1
+ /**
2
+ * Type alias for {@link Workspace.projects | Workspace.projects} property.
3
+ */ export { }; // TODO: should be `M extends true ? Array<Project<M>> : [Project<M>?]`; change when this is fixed: https://github.com/microsoft/TypeScript/issues/54302
2
4
 
3
5
  //# sourceMappingURL=WorkspaceProjects.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/workspace/WorkspaceProjects.ts"],"sourcesContent":["import {type Project} from './Project.js';\n\n/**\n * Type alias for {@link Workspace.projects | Workspace.projects} property.\n */\nexport type WorkspaceProjects<M extends boolean> = Array<Project<M>>; // TODO: should be `M extends true ? Array<Project<M>> : [Project<M>?]`; change when this is fixed: https://github.com/microsoft/TypeScript/issues/54302\n"],"names":[],"mappings":"AAAA,WAKqE,CAAC,wJAAwJ"}
1
+ {"version":3,"sources":["../../src/workspace/WorkspaceProjects.ts"],"sourcesContent":["import {type Project} from './Project.js';\n\n/**\n * Type alias for {@link Workspace.projects | Workspace.projects} property.\n */\nexport type WorkspaceProjects<M extends boolean> = Array<Project<M>>; // TODO: should be `M extends true ? Array<Project<M>> : [Project<M>?]`; change when this is fixed: https://github.com/microsoft/TypeScript/issues/54302\n"],"names":[],"mappings":"AAEA;;CAEC,GACD,WAAqE,CAAC,wJAAwJ"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jakubmazanec/carson",
3
- "version": "0.3.0-next.dc4435e",
3
+ "version": "0.3.0-next.f3375f0",
4
4
  "description": "Tool for managing workspace and project configuration.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -31,13 +31,13 @@
31
31
  "typecheck": "tsc --project tsconfig.typecheck.json"
32
32
  },
33
33
  "dependencies": {
34
- "@jakubmazanec/args": "^1.0.0",
35
- "@jakubmazanec/cli": "^0.2.0",
36
- "@jakubmazanec/error": "^2.0.0",
37
- "@jakubmazanec/fs-utils": "^0.1.0",
38
- "@jakubmazanec/template": "^1.0.0",
39
- "@jakubmazanec/ts-utils": "^2.1.0",
40
- "@jakubmazanec/zod-utils": "^1.0.0",
34
+ "@jakubmazanec/args": "2.0.0-next.f3375f0",
35
+ "@jakubmazanec/cli": "0.3.0-next.f3375f0",
36
+ "@jakubmazanec/error": "3.0.0-next.f3375f0",
37
+ "@jakubmazanec/fs-utils": "0.2.0-next.f3375f0",
38
+ "@jakubmazanec/template": "2.0.0-next.f3375f0",
39
+ "@jakubmazanec/ts-utils": "3.0.0-next.f3375f0",
40
+ "@jakubmazanec/zod-utils": "2.0.0-next.f3375f0",
41
41
  "chalk": "^5.2.0",
42
42
  "diff": "^5.1.0",
43
43
  "fast-glob": "^3.2.11",
@@ -60,7 +60,7 @@
60
60
  "@types/fs-extra": "^9.0.13",
61
61
  "@types/lodash": "^4.14.195",
62
62
  "@types/micromatch": "^4.0.2",
63
- "@types/node": "^16.18.3",
63
+ "@types/node": "^20.8.5",
64
64
  "@types/react": "^18.0.26",
65
65
  "@types/semver": "^7.3.9",
66
66
  "@types/zen-observable": "^0.8.3",
@@ -76,8 +76,8 @@
76
76
  "optional": true
77
77
  }
78
78
  },
79
- "packageManager": "npm@8.19.4",
79
+ "packageManager": "npm@10.1.0",
80
80
  "engines": {
81
- "node": ">=16.20.0"
81
+ "node": "^20.8.0"
82
82
  }
83
83
  }