-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1380 from polywrap/pileks/patch-0.9.3/add-migrati…
…on-warnings [Patch 0.9.3] - Add logging to migration actions
- Loading branch information
Showing
52 changed files
with
264 additions
and
75 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
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
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
7 changes: 5 additions & 2 deletions
7
packages/cli/src/lib/manifest/migrate/migrateAppProjectManifest.ts
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,15 +1,18 @@ | ||
import { migrateAnyManifest } from "./migrateAnyManifest"; | ||
|
||
import { migrateAppManifest } from "@polywrap/polywrap-manifest-types-js"; | ||
import { ILogger } from "@polywrap/logging-js"; | ||
|
||
export function migrateAppProjectManifest( | ||
manifestString: string, | ||
to: string | ||
to: string, | ||
logger?: ILogger | ||
): string { | ||
return migrateAnyManifest( | ||
manifestString, | ||
"AppManifest", | ||
migrateAppManifest, | ||
to | ||
to, | ||
logger | ||
); | ||
} |
7 changes: 5 additions & 2 deletions
7
packages/cli/src/lib/manifest/migrate/migrateBuildExtensionManifest.ts
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,15 +1,18 @@ | ||
import { migrateAnyManifest } from "./migrateAnyManifest"; | ||
|
||
import { migrateBuildManifest } from "@polywrap/polywrap-manifest-types-js"; | ||
import { ILogger } from "@polywrap/logging-js"; | ||
|
||
export function migrateBuildExtensionManifest( | ||
manifestString: string, | ||
to: string | ||
to: string, | ||
logger?: ILogger | ||
): string { | ||
return migrateAnyManifest( | ||
manifestString, | ||
"BuildManifest", | ||
migrateBuildManifest, | ||
to | ||
to, | ||
logger | ||
); | ||
} |
7 changes: 5 additions & 2 deletions
7
packages/cli/src/lib/manifest/migrate/migrateDeployExtensionManifest.ts
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,15 +1,18 @@ | ||
import { migrateAnyManifest } from "./migrateAnyManifest"; | ||
|
||
import { migrateDeployManifest } from "@polywrap/polywrap-manifest-types-js"; | ||
import { ILogger } from "@polywrap/logging-js"; | ||
|
||
export function migrateDeployExtensionManifest( | ||
manifestString: string, | ||
to: string | ||
to: string, | ||
logger?: ILogger | ||
): string { | ||
return migrateAnyManifest( | ||
manifestString, | ||
"DeployManifest", | ||
migrateDeployManifest, | ||
to | ||
to, | ||
logger | ||
); | ||
} |
7 changes: 5 additions & 2 deletions
7
packages/cli/src/lib/manifest/migrate/migrateInfraExtensionManifest.ts
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,15 +1,18 @@ | ||
import { migrateAnyManifest } from "./migrateAnyManifest"; | ||
|
||
import { migrateInfraManifest } from "@polywrap/polywrap-manifest-types-js"; | ||
import { ILogger } from "@polywrap/logging-js"; | ||
|
||
export function migrateInfraExtensionManifest( | ||
manifestString: string, | ||
to: string | ||
to: string, | ||
logger?: ILogger | ||
): string { | ||
return migrateAnyManifest( | ||
manifestString, | ||
"InfraManifest", | ||
migrateInfraManifest, | ||
to | ||
to, | ||
logger | ||
); | ||
} |
7 changes: 5 additions & 2 deletions
7
packages/cli/src/lib/manifest/migrate/migrateMetaExtensionManifest.ts
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,15 +1,18 @@ | ||
import { migrateAnyManifest } from "./migrateAnyManifest"; | ||
|
||
import { migrateMetaManifest } from "@polywrap/polywrap-manifest-types-js"; | ||
import { ILogger } from "@polywrap/logging-js"; | ||
|
||
export function migrateMetaExtensionManifest( | ||
manifestString: string, | ||
to: string | ||
to: string, | ||
logger?: ILogger | ||
): string { | ||
return migrateAnyManifest( | ||
manifestString, | ||
"MetaManifest", | ||
migrateMetaManifest, | ||
to | ||
to, | ||
logger | ||
); | ||
} |
7 changes: 5 additions & 2 deletions
7
packages/cli/src/lib/manifest/migrate/migratePluginProjectManifest.ts
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,15 +1,18 @@ | ||
import { migrateAnyManifest } from "./migrateAnyManifest"; | ||
|
||
import { migratePluginManifest } from "@polywrap/polywrap-manifest-types-js"; | ||
import { ILogger } from "@polywrap/logging-js"; | ||
|
||
export function migratePluginProjectManifest( | ||
manifestString: string, | ||
to: string | ||
to: string, | ||
logger?: ILogger | ||
): string { | ||
return migrateAnyManifest( | ||
manifestString, | ||
"PluginManifest", | ||
migratePluginManifest, | ||
to | ||
to, | ||
logger | ||
); | ||
} |
7 changes: 5 additions & 2 deletions
7
packages/cli/src/lib/manifest/migrate/migratePolywrapProjectManifest.ts
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,15 +1,18 @@ | ||
import { migrateAnyManifest } from "./migrateAnyManifest"; | ||
|
||
import { migratePolywrapManifest } from "@polywrap/polywrap-manifest-types-js"; | ||
import { ILogger } from "@polywrap/logging-js"; | ||
|
||
export function migratePolywrapProjectManifest( | ||
manifestString: string, | ||
to: string | ||
to: string, | ||
logger?: ILogger | ||
): string { | ||
return migrateAnyManifest( | ||
manifestString, | ||
"PolywrapManifest", | ||
migratePolywrapManifest, | ||
to | ||
to, | ||
logger | ||
); | ||
} |
10 changes: 8 additions & 2 deletions
10
packages/cli/src/lib/manifest/migrate/migrateTestExtensionManifest.ts
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,12 +1,18 @@ | ||
import { migrateAnyManifest } from "./migrateAnyManifest"; | ||
|
||
import { migratePolywrapWorkflow } from "@polywrap/polywrap-manifest-types-js"; | ||
import { ILogger } from "@polywrap/logging-js"; | ||
|
||
export function migrateWorkflow(manifestString: string, to: string): string { | ||
export function migrateWorkflow( | ||
manifestString: string, | ||
to: string, | ||
logger?: ILogger | ||
): string { | ||
return migrateAnyManifest( | ||
manifestString, | ||
"PolywrapWorkflow", | ||
migratePolywrapWorkflow, | ||
to | ||
to, | ||
logger | ||
); | ||
} |
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
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,8 @@ | ||
# @polywrap/logging-js | ||
|
||
An interface to which Loggers within the Polywrap Toolchain must conform. | ||
|
||
Contains: | ||
|
||
- `ILogger.ts` - the logger interface | ||
- `LogLevel.ts` - the log levels supported by the logger |
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,28 @@ | ||
{ | ||
"name": "@polywrap/logging-js", | ||
"description": "Polywrap Core Logging Interface", | ||
"version": "0.9.3", | ||
"license": "MIT", | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/polywrap/monorepo.git" | ||
}, | ||
"main": "build/index.js", | ||
"files": [ | ||
"build" | ||
], | ||
"scripts": { | ||
"build": "rimraf ./build && tsc --project tsconfig.build.json", | ||
"lint": "eslint --color -c ../../../.eslintrc.js src/" | ||
}, | ||
"dependencies": { | ||
}, | ||
"devDependencies": { | ||
"rimraf": "3.0.2", | ||
"typescript": "4.1.6" | ||
}, | ||
"gitHead": "7346adaf5adb7e6bbb70d9247583e995650d390a", | ||
"publishConfig": { | ||
"access": "public" | ||
} | ||
} |
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,9 @@ | ||
import { LogLevel } from "./LogLevel"; | ||
|
||
export interface ILogger { | ||
log(message: string, level: LogLevel): void; | ||
debug(message: string): void; | ||
info(message: string): void; | ||
warn(message: string): void; | ||
error(message: string): void; | ||
} |
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,6 @@ | ||
export enum LogLevel { | ||
DEBUG, | ||
INFO, | ||
WARN, | ||
ERROR, | ||
} |
Oops, something went wrong.