diff --git a/.github/codecov.yml b/.github/codecov.yml index a15de165d0..6450a704bb 100644 --- a/.github/codecov.yml +++ b/.github/codecov.yml @@ -14,11 +14,15 @@ coverage: # Since Backstage is a mono repo, flags here help in getting the code coverage of individual packages. # Documentation: https://docs.codecov.io/docs/flags flags: - core: + core-app-api: paths: - - packages/core/ + - packages/core-app-api/ carryforward: true - core-api: + core-components: paths: - - packages/core-api/ + - packages/core-components/ + carryforward: true + core-plugin-api: + paths: + - packages/core-plugin-api/ carryforward: true diff --git a/.github/workflows/chromatic-storybook-test.yml b/.github/workflows/chromatic-storybook-test.yml index 89df848c76..d189236987 100644 --- a/.github/workflows/chromatic-storybook-test.yml +++ b/.github/workflows/chromatic-storybook-test.yml @@ -4,8 +4,7 @@ on: paths: - '.github/workflows/chromatic-storybook-test.yml' - 'packages/storybook/**' - - 'packages/core/src/components/**' - - 'packages/core/src/layout/**' + - 'packages/core-components/src/**' jobs: chromatic: diff --git a/.github/workflows/master.yml b/.github/workflows/master.yml index 75e26d52d3..daac9a535d 100644 --- a/.github/workflows/master.yml +++ b/.github/workflows/master.yml @@ -119,8 +119,9 @@ jobs: yarn lerna -- run test -- --coverage bash <(curl -s https://codecov.io/bash) # Upload code coverage for some specific flags. Also see .codecov.yml - bash <(curl -s https://codecov.io/bash) -f packages/core/coverage/* -F core - bash <(curl -s https://codecov.io/bash) -f packages/core-api/coverage/* -F core-api + bash <(curl -s https://codecov.io/bash) -f packages/core-app-api/coverage/* -F core-app-api + bash <(curl -s https://codecov.io/bash) -f packages/core-components/coverage/* -F core-components + bash <(curl -s https://codecov.io/bash) -f packages/core-plugin-api/coverage/* -F core-plugin-api env: BACKSTAGE_TEST_DATABASE_POSTGRES13_CONNECTION_STRING: postgresql://postgres:postgres@localhost:${{ job.services.postgres13.ports[5432] }} BACKSTAGE_TEST_DATABASE_POSTGRES9_CONNECTION_STRING: postgresql://postgres:postgres@localhost:${{ job.services.postgres9.ports[5432] }} diff --git a/.github/workflows/microsite-with-storybook-deploy.yml b/.github/workflows/microsite-with-storybook-deploy.yml index cf571ef4e8..e8886b7d6b 100644 --- a/.github/workflows/microsite-with-storybook-deploy.yml +++ b/.github/workflows/microsite-with-storybook-deploy.yml @@ -7,7 +7,7 @@ on: paths: - '.github/workflows/microsite-with-storybook-deploy.yml' - 'packages/storybook/**' - - 'packages/core/src/**' + - 'packages/core-components/src/**' - 'microsite/**' - 'docs/**' diff --git a/docs/auth/oauth.md b/docs/auth/oauth.md index 4209b81279..bbab943dd1 100644 --- a/docs/auth/oauth.md +++ b/docs/auth/oauth.md @@ -14,7 +14,7 @@ to various third party APIs. There are occasions when the user wants to perform actions towards third party services that require authorization via OAuth. Backstage provides standardized [Utility APIs](../api/utility-apis.md) such as the -[GoogleAuthApi](https://github.com/backstage/backstage/blob/master/packages/core-api/src/apis/definitions/auth.ts) +[GoogleAuthApi](https://github.com/backstage/backstage/blob/master/packages/core-plugin-api/src/apis/definitions/auth.ts) for that use-case. Backstage also includes a set of implementations of these APIs that integrate with the [auth-backend](https://github.com/backstage/backstage/tree/master/plugins/auth-backend) @@ -59,7 +59,7 @@ easier to make authenticated requests inside a plugin. The following describes the OAuth flow implemented by the [auth-backend](https://github.com/backstage/backstage/tree/master/plugins/auth-backend) and -[DefaultAuthConnector](https://github.com/backstage/backstage/blob/master/packages/core-api/src/lib/AuthConnector/DefaultAuthConnector.ts) +[DefaultAuthConnector](https://github.com/backstage/backstage/blob/master/packages/core-app-api/src/lib/AuthConnector/DefaultAuthConnector.ts) in `@backstage/core-api`. Component and APIs can request Access or ID Tokens from any available Auth diff --git a/docs/getting-started/create-an-app.md b/docs/getting-started/create-an-app.md index 2e568664d9..fed8d101e0 100644 --- a/docs/getting-started/create-an-app.md +++ b/docs/getting-started/create-an-app.md @@ -147,7 +147,7 @@ globs. For example: "packages": [ "packages/*", "plugins/*", - "../backstage/packages/core", // New path added to work on @backstage/core + "../backstage/packages/core-plugin-api", // New path added to work on @backstage/core-plugin-api ], ``` diff --git a/docs/getting-started/project-structure.md b/docs/getting-started/project-structure.md index 55a92da571..1d5d58c2c9 100644 --- a/docs/getting-started/project-structure.md +++ b/docs/getting-started/project-structure.md @@ -127,18 +127,17 @@ are separated out into their own folder, see further down. used by the backend, we chose to separate `config` and `config-loader` into two different packages. -- [`core/`](https://github.com/backstage/backstage/tree/master/packages/core) - +- [`core-app-api/`](https://github.com/backstage/backstage/tree/master/packages/core-app-api) - + This package contains the core APIs that are used to wire together Backstage + apps. + +- [`core-components/`](https://github.com/backstage/backstage/tree/master/packages/core-components) - This package contains our visual React components, some of which you can find in [plugin examples](https://backstage.io/storybook/?path=/story/plugins-examples--plugin-with-data). - Apart from that it re-exports everything from [`core-api`] so that users only - need to rely on one package. -- [`core-api/`](https://github.com/backstage/backstage/tree/master/packages/core-api) - - This package contains APIs and definitions of such. It is it's own package - because we needed to split our `test-utils` package. It's an implementation - detail that we try to hide from our users, and no one should have to depend on - it directly. +- [`core-plugin-api/`](https://github.com/backstage/backstage/tree/master/packages/core-plugin-api) - + This package contains the core APIs that are used to build Backstage plugins. - [`create-app/`](https://github.com/backstage/backstage/tree/master/packages/create-app) - An CLI to specifically scaffold a new Backstage App. It does so by using a diff --git a/docs/overview/stability-index.md b/docs/overview/stability-index.md index 29b9be14b6..a05be0e1eb 100644 --- a/docs/overview/stability-index.md +++ b/docs/overview/stability-index.md @@ -106,16 +106,6 @@ Used to load in static configuration, mainly for use by the CLI and Stability: `1`. Mainly intended for internal use. -### `core` [GitHub](https://github.com/backstage/backstage/tree/master/packages/core/) - -The `@backstage/core` and `@backstage/core-api` packages are being phased out -and replaced by other `@backstage/core-*` packages. They are still in use but -will not receive any breaking changes. - -### `core-api` [GitHub](https://github.com/backstage/backstage/tree/master/packages/core-api/) - -Stability: See `@backstage/core` above - ### `core-app-api` [GitHub](https://github.com/backstage/backstage/tree/master/packages/core-app-api/) The APIs used exclusively in the app, such as `createApp` and the system icons. diff --git a/packages/core-components/src/components/WarningPanel/WarningPanel.stories.tsx b/packages/core-components/src/components/WarningPanel/WarningPanel.stories.tsx index d88e190910..bab831e905 100644 --- a/packages/core-components/src/components/WarningPanel/WarningPanel.stories.tsx +++ b/packages/core-components/src/components/WarningPanel/WarningPanel.stories.tsx @@ -43,7 +43,7 @@ export const Children = () => ( used to hide/expose stack traces for warnings, like this example:
SyntaxError: Error transforming - /home/user/github/backstage/packages/core/src/components/WarningPanel/WarningPanel.stories.tsx: + /home/user/github/backstage/packages/core-components/src/components/WarningPanel/WarningPanel.stories.tsx: Unexpected token (42:16) at unexpected (/home/user/github/backstage/node_modules/sucrase/dist/parser/traverser/util.js:83:15) at tsParseMaybeAssignWithJSX diff --git a/scripts/api-extractor.ts b/scripts/api-extractor.ts index 3238166e05..3660c72932 100644 --- a/scripts/api-extractor.ts +++ b/scripts/api-extractor.ts @@ -74,8 +74,6 @@ const SKIPPED_PACKAGES = [ 'packages/techdocs-cli', // TODO(Rugvip): Enable these once `import * as ...` and `import()` PRs have landed, #1796 & #1916. - 'packages/core', - 'packages/core-api', 'packages/core-components', 'plugins/catalog', 'plugins/catalog-backend',