1
0
mirror of https://github.com/tektoncd/catalog.git synced 2024-11-22 06:02:51 +00:00
catalog/task/prettier/0.1
PuneetPunamiya 5a3e5f630f Adds category field as an annotation as tekton.dev/categories
- Initially all tags were mapped to categories in Hub,
     for e.g. config.yaml: https://github.com/tektoncd/hub/blob/master/config.yaml,
     so whenever a new tag was added in a task it was mapped to a category called `others`.
     Hence before every release we had to manually map these new tags to some category,
     hence after the discussion in Catalog and Hub WG, a proposal was created for adding
     a category as an annotation.

   - PR to update the TEP-0003-Tekton Catalog Organization: https://github.com/tektoncd/community/pull/352

Signed-off-by: Puneet Punamiya <ppunamiy@redhat.com>
2021-07-26 13:15:08 +01:00
..
tests Add add_task helper function for tests 2020-10-07 17:51:55 +01:00
prettier.yaml Adds category field as an annotation as tekton.dev/categories 2021-07-26 13:15:08 +01:00
README.md Modifies prettier task according to the new reorg proposal 2020-07-10 22:06:57 +01:00

Prettier Tasks

This Task is for running Prettier code formatter against the provided source code in the Workspace. By default this Task will check the format of files in the root of your Workspace.

Workspaces

  • source: A workspace for this Task to fetch the source the code.

Parameters

  • args: Prettier arguments used to run Prettier. See Prettier CLI for the arguments. (default: --check .)
  • prettierImage: Prettier image used to run Prettier. (default: elnebuloso/prettier:latest)

Usage

The following pipeline uses the prettier-check Task to format the file build.yaml from catalog/golang. The pipeline has two tasks: the git-clone Task is the first task to clone the repository to the "shared-workspace"; the prettier-check Task runs after git-clone Task to format the source code.