1. packtracker/report@2.3.0

packtracker/report@2.3.0

Partner
Sections
Send webpack bundle stats to packtracker for analysis.
Created: July 5, 2019Version Published: May 28, 2020Releases: 11
Org Usage:
< 25

Orb Quick Start Guide

Use CircleCI version 2.1 at the top of your .circleci/config.yml file.

1 version: 2.1

Add the orbs stanza below your version, invoking the orb:

1 2 orbs: report: packtracker/report@2.3.0

Use report elements in your existing workflows and jobs.

Opt-in to use of uncertified orbs on your organization’s Security settings page.

Usage Examples

simple

Simplest use case, leveraging default webpack config location and root project path.

1 2 3 4 5 6 7 version: 2.1 orbs: packtracker: packtracker/report@x.y.z workflows: packtracker: jobs: - packtracker/report

custom_webpack_config_path

Custom webpack config location (for example Ruby on Rails).

1 2 3 4 5 6 7 8 version: 2.1 orbs: packtracker: packtracker/report@x.y.z workflows: packtracker: jobs: - packtracker/report: webpack_config: ./config/webpack/production.js

custom_nested_config_path

Custom project path, useful for monorepo situations.

1 2 3 4 5 6 7 8 version: 2.1 orbs: packtracker: packtracker/report@x.y.z workflows: packtracker: jobs: - packtracker/report: project_root: ./packages/internal_package

custom_resource_class

Custom resource class if your build is running out of memory.

1 2 3 4 5 6 7 8 version: 2.1 orbs: packtracker: packtracker/report@x.y.z workflows: packtracker: jobs: - packtracker/report: selected_resource_class: medium+

exclude_some_assets_from_reporting

Custom resource class if your build is running out of memory.

1 2 3 4 5 6 7 8 version: 2.1 orbs: packtracker: packtracker/report@x.y.z workflows: packtracker: jobs: - packtracker/report: exclude_assets: main|pack

Jobs

report

This job reports your webpack bundle stats to the packtracker.io service. For this job to be able to authenticate with the packtracker service, you must additionally add the `PT_PROJECT_TOKEN` environment variable to your CircleCI project configuration. The project token can be found in the packtracker project settings.

Show job Source
PARAMETER
DESCRIPTION
REQUIRED
DEFAULT
TYPE
selected_resource_class
Resource class to be used for the executor
No
medium
enum
project_root
The path to the directory containing your package.json
No
''
string
webpack_config
The path to your webpack configuration file (if present)
No
./webpack.config.js
string
exclude_assets
Compiled as RegExp and passed as the [excludeAssets configuration in the webpack stats config](https://webpack.js.org/configuration/stats/#stats) (only available to webpack version 3.5.0+)
No
''
string

Executors

reporter

Show executor Source
PARAMETER
DESCRIPTION
REQUIRED
DEFAULT
TYPE
selected_resource_class
Resource class to be used for the executor
No
medium
enum

Orb Source

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 # This code is licensed from CircleCI to the user under the MIT license. # See here for details: https://circleci.com/developer/orbs/licensing version: 2.1 description: Send webpack bundle stats to packtracker for analysis. display: source_url: https://github.com/packtracker/report home_url: https://packtracker.io/ executors: reporter: resource_class: << parameters.selected_resource_class >> docker: - image: packtracker/report:2.3.0 parameters: selected_resource_class: description: Resource class to be used for the executor type: enum default: medium enum: [small, medium, medium+, large, xlarge, 2xlarge, 2xlarge+] jobs: report: description: | This job reports your webpack bundle stats to the packtracker.io service. For this job to be able to authenticate with the packtracker service, you must additionally add the `PT_PROJECT_TOKEN` environment variable to your CircleCI project configuration. The project token can be found in the packtracker project settings. parameters: selected_resource_class: description: Resource class to be used for the executor type: enum default: medium enum: [small, medium, medium+, large, xlarge, 2xlarge, 2xlarge+] project_root: description: The path to the directory containing your package.json type: string default: "" webpack_config: description: The path to your webpack configuration file (if present) type: string default: "./webpack.config.js" exclude_assets: description: Compiled as RegExp and passed as the [excludeAssets configuration in the webpack stats config](https://webpack.js.org/configuration/stats/#stats) (only available to webpack version 3.5.0+) type: string default: "" environment: PT_EXCLUDE_ASSETS: << parameters.exclude_assets >> PT_PROJECT_ROOT: << parameters.project_root >> WEBPACK_CONFIG_PATH: << parameters.webpack_config >> executor: name: reporter selected_resource_class: << parameters.selected_resource_class >> steps: - checkout - run: name: "Reporting to packtracker.io" command: /entrypoint.sh examples: simple: description: Simplest use case, leveraging default webpack config location and root project path. usage: version: 2.1 orbs: packtracker: packtracker/report@x.y.z workflows: packtracker: jobs: - packtracker/report custom_webpack_config_path: description: Custom webpack config location (for example Ruby on Rails). usage: version: 2.1 orbs: packtracker: packtracker/report@x.y.z workflows: packtracker: jobs: - packtracker/report: webpack_config: "./config/webpack/production.js" custom_nested_config_path: description: Custom project path, useful for monorepo situations. usage: version: 2.1 orbs: packtracker: packtracker/report@x.y.z workflows: packtracker: jobs: - packtracker/report: project_root: "./packages/internal_package" custom_resource_class: description: Custom resource class if your build is running out of memory. usage: version: 2.1 orbs: packtracker: packtracker/report@x.y.z workflows: packtracker: jobs: - packtracker/report: selected_resource_class: medium+ exclude_some_assets_from_reporting: description: Custom resource class if your build is running out of memory. usage: version: 2.1 orbs: packtracker: packtracker/report@x.y.z workflows: packtracker: jobs: - packtracker/report: exclude_assets: "main|pack"
Developer Updates
Get tips to optimize your builds
Or join our research panel and give feedback
By submitting this form, you are agreeing to ourTerms of UseandPrivacy Policy.