Skip to content

Commit

Permalink
feat(changeset): new release
Browse files Browse the repository at this point in the history
  • Loading branch information
accezar committed Mar 10, 2024
1 parent 42a8266 commit 1f198a6
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 31 deletions.
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Backstage.io Dependency Checker Plugin
# Backstage.io Library Check Plugin

This plugin helps you explore project dependencies by offering insights and visualizing current, latest, and upcoming versions for your entire organization.
This plugin helps you explore project dependency libraries by offering insights and visualizing current, latest, and upcoming versions for your entire organization.

### Initial support:

Expand Down Expand Up @@ -42,25 +42,25 @@ If you have any suggestions for files/languages, please feel welcome to file an
- Integrates seamlessly with the Backstage.io platform, enhancing overall project management and development environment.

5. **Code Occurrences:**
- Search for occurrences of the dependency in project files **(initial support only for GitHub Code Search)** ⚠️
- Search for occurrences of the library in project files **(initial support only for GitHub Code Search)** ⚠️

## Setup

Find [installation instructions](./docs/setup.md) in our documentation.

## Examples

Entity dependencies list:
Entity libraries list:

![Dependencies list](./docs/images/plugin_entity_tab-dependencies.png)
![Libraries list](./docs/images/plugin_entity_tab-libraries.png)

![Dependencies list](./docs/images/plugin_entity_tab-choose-descriptor.png)
![Libraries list](./docs/images/plugin_entity_tab-choose-descriptor.png)

![Dependencies list](./docs/images/plugin_entity_tab-occurrances.png)
![Libraries list](./docs/images/plugin_entity_tab-occurrances.png)

![Dependencies list](./docs/images/plugin_entity_tab-code-search.png)
![Libraries list](./docs/images/plugin_entity_tab-code-search.png)

![Dependencies overview](./docs/images/plugin_page-overview.png)
![Libraries overview](./docs/images/plugin_page-overview.png)


## License
Expand Down
24 changes: 12 additions & 12 deletions docs/backend.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,28 +4,28 @@
Add the plugin to your backend app:

```bash
cd packages/backend && yarn add @anakz/backstage-plugin-dependency-check-backend
cd packages/backend && yarn add @anakz/backstage-plugin-library-check-backend
```

Create new file at packages/backend/src/plugins/dependencyCheck.ts:
Create new file at packages/backend/src/plugins/libraryCheck.ts:

```ts

// packages/backend/src/plugins/dependencyCheck.ts
// packages/backend/src/plugins/libraryCheck.ts

import { PluginEnvironment } from '../types';
import { Router } from 'express';
import {
DatabaseDependencyCheckStore,
DatabaseLibraryCheckStore,
createRouter,
} from '@anakz/backstage-plugin-dependency-check-backend';
} from '@anakz/backstage-plugin-library-check-backend';

export default async function createPlugin({
logger,
database,
config,
}: PluginEnvironment): Promise<Router> {
const db = await DatabaseDependencyCheckStore.create({
const db = await DatabaseLibraryCheckStore.create({
database: database,
});
return await createRouter({
Expand All @@ -48,7 +48,7 @@ builder.addEntityProvider(
// add a new provider entry, configure the schedule frequency as you wish
// initialDelay must be up to 15s to avoid conflicts

DependencyCheckProvider.fromConfig({
LibraryCheckProvider.fromConfig({
config: env.config,
envId: 'production',
logger: env.logger,
Expand All @@ -74,11 +74,11 @@ builder.addEntityProvider(
builder.addProcessor(
// ...

DependencyCheckProcessor.fromConfig(env.config, {
LibraryCheckProcessor.fromConfig(env.config, {
reader: env.reader,
logger: env.logger,
}),
DependencyCheckGlobalUpdateProcessor.fromConfig(env.config, {
LibraryCheckUpdaterProcessor.fromConfig(env.config, {
reader: env.reader,
logger: env.logger,
}),
Expand All @@ -92,11 +92,11 @@ builder.addEntityProvider(
Now add the plugin to your packages/backend/src/index.ts:

```ts
import dependencyCheck from './plugins/dependencyCheck';
import libraryCheck from './plugins/libraryCheck';

// ...
const dependencyCheckEnv = useHotMemoize(module, () => createEnv('dependencyCheck'));
const libraryCheckEnv = useHotMemoize(module, () => createEnv('libraryCheck'));

// ...
apiRouter.use('/dependency-check', await dependencyCheck(dependencyCheckEnv));
apiRouter.use('/library-check', await libraryCheck(libraryCheckEnv));
```
20 changes: 10 additions & 10 deletions docs/frontend.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,22 @@
Add the plugin to your frontend app:

```bash
cd packages/app && yarn add @anakz/backstage-plugin-dependency-check
cd packages/app && yarn add @anakz/backstage-plugin-library-check
```

Expose the main plugin page:

```ts
// packages/app/src/App.tsx

import { DependencyCheckIndexPage } from '@anakz/backstage-plugin-dependency-check';
import { LibraryCheckIndexPage } from '@anakz/backstage-plugin-library-check';

// ...

const AppRoutes = () => (
<FlatRoutes>
// ...
<Route path="/dependency-check" element={<DependencyCheckIndexPage />} />
<Route path="/library-check" element={<LibraryCheckIndexPage />} />
// ...
</FlatRoutes>
);
Expand All @@ -34,7 +34,7 @@ Add it to sidebar:

<SidebarItem
icon={ExtensionIcon}
to="dependency-check"
to="library-check"
text="Libraries"
/>

Expand All @@ -47,21 +47,21 @@ Expose the entity plugin tab:
// packages/app/src/components/catalog/EntityPage.tsx

import {
DependencyCheckPage,
useIsProjectDependenciesAvailable,
} from '@anakz/backstage-plugin-dependency-check';
LibraryCheckPage,
useIsProjectLibrariesAvailable,
} from '@anakz/backstage-plugin-library-check';

// ...

const serviceEntityPage = (
// ...

<EntityLayout.Route
path="/dependency-check"
path="/library-check"
title="Libraries"
if={useIsProjectDependenciesAvailable}
if={useIsProjectLibrariesAvailable}
>
<DependencyCheckPage />
<LibraryCheckPage />
</EntityLayout.Route>

// ...
Expand Down
Binary file modified docs/images/plugin_page-overview.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 1f198a6

Please sign in to comment.