Skip to content

@stephansama actions / do-not-track-polyfill

๐Ÿ•ต๏ธโ€โ™‚๏ธ Do Not Track Polyfill โ€‹

๐Ÿงช Test do not track (False)๐Ÿงช Test do not track (True)

A simple GitHub Action that conditionally disables telemetry by setting opt-out environment variables for several popular vendors. It ensures your workflow respects privacy-focused settings by preemptively opting out of analytics, usage reporting, and tracking features โ€” if the relevant tools support them.


โœจ Features โ€‹

  • Adds common telemetry-related environment variables (e.g., ASTRO_TELEMETRY_DISABLED, etc.)
  • Helps opt out of analytics, error reporting, and tracking

๐Ÿš€ Usage โ€‹

Add the action to your workflow before any steps that might invoke telemetry aware tools

example-do-not-track-polyfill.yml

yaml
name: do-not-track-polyfill example
on:
  workflow_dispatch:
jobs:
  example:
    runs-on: ubuntu-latest
    if: ${{github.event.workflow_run.conclusion != 'success'}}
    steps:
      - uses: stephansama/actions/do-not-track-polyfill@v1

๐ŸŒฑ What It Does โ€‹

This action conditionally sets additional environment variables to disable telemetry for popular platforms such as:

  • AstroJS
  • Storybook
  • Vercel

You can also customize which flags are set (see below).


โš™๏ธ Inputs โ€‹

NameDefaultDescriptionRequired
additionalundefinedAdditional telemetry providers to blockfalse
yaml
- uses: stephansama/actions/do-not-track-polyfill-action@v1
  with:
      additional: |
     TEST=https://test.com

๐Ÿ”’ Why Use This? โ€‹

  • Allows you to turn on and off
  • Prevents telemetry from bloating CI logs or triggering network requests

Functions โ€‹

FunctionDescription

getTelemetryEnvironments

โ€

parseAdditionalEnvironments

โ€

Released under MIT license