0.3.17 • Published 5 days ago

@backstage/plugin-todo-backend v0.3.17

Weekly downloads
-
License
Apache-2.0
Repository
github
Last release
5 days ago

@backstage/plugin-todo-backend

Backend for the @backstage/plugin-todo plugin. Assists in scanning for and listing // TODO comments in source code repositories.

Installation

Install the @backstage/plugin-todo-backend package in your backend packages, and then integrate the plugin using the following default setup for src/plugins/todo.ts:

import { Router } from 'express';
import { CatalogClient } from '@backstage/catalog-client';
import {
  createRouter,
  TodoReaderService,
  TodoScmReader,
} from '@backstage/plugin-todo-backend';
import { PluginEnvironment } from '../types';

export default async function createPlugin({
  logger,
  reader,
  config,
  discovery,
}: PluginEnvironment): Promise<Router> {
  const todoReader = TodoScmReader.fromConfig(config, {
    logger,
    reader,
  });
  const catalogClient = new CatalogClient({ discoveryApi: discovery });
  const todoService = new TodoReaderService({
    todoReader,
    catalogClient,
  });

  return await createRouter({ todoService });
}

Scanned Files

The included TodoReaderService and TodoScmReader works by reading source code of to the entity that is being viewed. The location source code is determined by the value of the backstage.io/source-location annotation of the entity, and if that is missing it falls back to the backstage.io/managed-by-location annotation. Only url locations are currently supported, meaning locally configured file locations won't work. Also note that dot-files and folders are ignored.

Parser Configuration

The TodoScmReader accepts a TodoParser option, which can be used to configure your own parser. The default one is based on Leasot and supports a wide range of languages. You can add to the list of supported tags by configuring your own version of the built-in parser, for example:

import {
  TodoScmReader,
  createTodoParser,
} from '@backstage/plugin-todo-backend';

// ...

const todoReader = TodoScmReader.fromConfig(config, {
  logger,
  reader,
  parser: createTodoParser({
    additionalTags: ['NOTE', 'XXX'],
  }),
});
0.3.17

9 days ago

0.3.16

11 days ago

0.3.16-next.1

18 days ago

0.3.16-next.0

25 days ago

0.3.15

1 month ago

0.3.14

1 month ago

0.3.13

1 month ago

0.3.12

1 month ago

0.3.12-next.2

2 months ago

0.3.12-next.1

2 months ago

0.3.11

2 months ago

0.3.11-next.0

2 months ago

0.3.9

2 months ago

0.3.10

2 months ago

0.3.8

2 months ago

0.3.8-next.3

2 months ago

0.3.8-next.2

3 months ago

0.3.8-next.1

3 months ago

0.3.8-next.0

3 months ago

0.3.7

3 months ago

0.3.7-next.2

4 months ago

0.3.7-next.1

4 months ago

0.3.7-next.0

4 months ago

0.3.6

4 months ago

0.3.6-next.3

5 months ago

0.3.6-next.2

5 months ago

0.3.6-next.1

5 months ago

0.2.0-next.2

9 months ago

0.2.0-next.1

9 months ago

0.2.0-next.0

9 months ago

0.3.3-next.0

7 months ago

0.3.3-next.1

7 months ago

0.3.4-next.2

7 months ago

0.3.6-next.0

5 months ago

0.3.0-next.3

8 months ago

0.2.3-next.2

8 months ago

0.2.3-next.1

8 months ago

0.1.44

9 months ago

0.3.0

7 months ago

0.3.5

5 months ago

0.3.2

7 months ago

0.3.1

7 months ago

0.3.4

6 months ago

0.3.3

7 months ago

0.3.5-next.2

6 months ago

0.3.5-next.0

6 months ago

0.3.5-next.1

6 months ago

0.2.2-next.0

8 months ago

0.2.1

8 months ago

0.2.0

9 months ago

0.2.2

8 months ago

0.1.44-next.0

10 months ago

0.1.43-next.2

11 months ago

0.1.43

10 months ago

0.1.42-next.1

12 months ago

0.1.43-next.0

11 months ago

0.1.43-next.1

11 months ago

0.1.42

12 months ago

0.1.42-next.0

1 year ago

0.1.41-next.3

1 year ago

0.1.41

1 year ago

0.1.40-next.1

1 year ago

0.1.40-next.2

1 year ago

0.1.40-next.0

1 year ago

0.1.41-next.2

1 year ago

0.1.41-next.1

1 year ago

0.1.41-next.0

1 year ago

0.1.40

1 year ago

0.1.39

1 year ago

0.1.39-next.0

1 year ago

0.1.39-next.1

1 year ago

0.1.39-next.2

1 year ago

0.1.37-next.1

1 year ago

0.1.37-next.2

1 year ago

0.1.38

1 year ago

0.1.37

1 year ago

0.1.35-next.0

2 years ago

0.1.35-next.1

1 year ago

0.1.37-next.0

1 year ago

0.1.36-next.3

1 year ago

0.1.36-next.2

1 year ago

0.1.36-next.1

1 year ago

0.1.36-next.0

1 year ago

0.1.34

2 years ago

0.1.35

1 year ago

0.1.36

1 year ago

0.1.34-next.0

2 years ago

0.1.34-next.1

2 years ago

0.1.34-next.2

2 years ago

0.1.33-next.0

2 years ago

0.1.33-next.2

2 years ago

0.1.33-next.1

2 years ago

0.1.33

2 years ago

0.1.32-next.0

2 years ago

0.1.31-next.0

2 years ago

0.1.31-next.2

2 years ago

0.1.31-next.1

2 years ago

0.1.30

2 years ago

0.1.31

2 years ago

0.1.32

2 years ago

0.1.30-next.0

2 years ago

0.1.30-next.1

2 years ago

0.1.30-next.2

2 years ago

0.1.29-next.0

2 years ago

0.1.29-next.1

2 years ago

0.1.29

2 years ago

0.1.27

2 years ago

0.1.28

2 years ago

0.1.26

2 years ago

0.1.28-next.0

2 years ago

0.1.28-next.2

2 years ago

0.1.28-next.1

2 years ago

0.1.26-next.0

2 years ago

0.1.25

2 years ago

0.1.21-next.0

2 years ago

0.1.20

2 years ago

0.1.21

2 years ago

0.1.22

2 years ago

0.1.23

2 years ago

0.1.24

2 years ago

0.1.16

2 years ago

0.1.17

2 years ago

0.1.18

2 years ago

0.1.19

2 years ago

0.1.15

2 years ago

0.1.19-next.0

2 years ago

0.1.20-next.0

2 years ago

0.1.14

2 years ago

0.1.13

3 years ago

0.1.12

3 years ago

0.1.11

3 years ago

0.1.10

3 years ago

0.1.9

3 years ago

0.1.8

3 years ago

0.1.7

3 years ago

0.1.6

3 years ago

0.1.4

3 years ago

0.1.5

3 years ago

0.1.3

3 years ago

0.1.2

3 years ago

0.1.1

3 years ago

0.1.0

3 years ago