---
title: "GitHub Output"
description: "commit TenXObject field/template values to GitHub"
source: "https://github.com/log-10x/modules/tree/main/pipelines/run/modules/output/event/github/module.yaml"
icon: "material/github"

---
Write [TenXObject](https://doc.log10x.com/api/js/#TenXObject "Provide structured, reflective access to log/trace events read from input(s).") instance values to a remote file on GitHub.

This output allows pipelines to dynamically generate [YAML](https://doc.log10x.com/config/yaml/) configuration and text [lookup](https://doc.log10x.com/api/js/#TenXLookup "Load and query the values of text lookup tables (.csv, .tsv) and geoIP DB files (.mmdb).") files.

Subsequent pipeline instances can [pull](https://doc.log10x.com/config/github/) generated files from GitHub to guide their execution.

!!! tenx-cloud "Availability"

    This implementation is only available by default in the 10x Engine [Compiler](https://doc.log10x.com/engine/flavors/#compiler) flavor to reduce the footprint of the [Runtime](https://doc.log10x.com/engine/flavors/#runtime) flavor. 

## :material-wrench-outline: Config Files

To configure the GitHub output module, [:material-cog: Edit](https://doc.log10x.com/config/app/#module-config "Learn how to edit app and module configurations") these files.  

Below is the default configuration from: [github/config.yaml](https://github.dev/log-10x/config/blob/main/pipelines/run/output/event/github/config.yaml "github/config.yaml"){target="\_blank"} (<span class="tenx-tooltip" data-tooltip="The config file below contains required fields to activate this module, marked with &#10071;">** Required Fields*</span>).  
  
<div class="edit-options">
    <a class="md-button tenx-edit-online-button" data-tooltip="Edit online on github.dev" href="https://github.dev/log-10x/config/blob/main/pipelines/run/output/event/github/config.yaml" target="_blank" rel="noopener noreferrer">
        <span class="twemoji" style="margin-right: 0.3rem;">
            <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
                <path d="M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12"></path>
            </svg>
        </span> Edit Online
    </a>
    <button class="md-button tenx-config.yaml0-edit-button" data-tooltip="Edit configuration file" data-dialog-id="config-yaml0-dialog">
        <span style="margin-right: 0.3rem;">
            <span class="twemoji">
                <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
                    <path d="M20.71,7.04C21.1,6.65 21.1,6 20.71,5.63L18.37,3.29C18,2.9 17.35,2.9 16.96,3.29L15.12,5.12L18.87,8.87M3,17.25V21H6.75L17.81,9.93L14.06,6.18L3,17.25Z"></path>
                </svg>
            </span>
        </span>Edit Locally
    </button>
</div>

<dialog id="config-yaml0-dialog" class="md-dialog md-dialog--editor">
    <div class="editor-dialog-wrapper">
        <div class="editor-dialog-header">
            <span class="editor-dialog-title">Edit config.yaml Locally</span>
            <div class="editor-header-actions">
                <button class="editor-toolbar-btn yaml-editor-locations" data-tooltip="Save">
                    <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M5 20h14v-2H5v2m14-9h-4V3H9v8H5l7 7 7-7Z"></path></svg>
                </button>
                <button class="editor-toolbar-btn yaml-editor-reset" data-tooltip="Reset to default">
                    <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M12.5 8c-2.65 0-5.05 1-6.9 2.6L2 7v9h9l-3.62-3.62c1.39-1.16 3.16-1.88 5.12-1.88 3.54 0 6.55 2.31 7.6 5.5l2.37-.78C21.08 11.03 17.15 8 12.5 8z"></path></svg>
                </button>
                <button class="editor-toolbar-btn yaml-editor-copy" data-tooltip="Copy to clipboard">
                    <svg class="icon-copy" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M19 21H8V7h11m0-2H8a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h11a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2m-3-4H4a2 2 0 0 0-2 2v14h2V3h12V1Z"></path></svg>
                    <svg class="icon-check" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" style="display:none;"><path fill="currentColor" d="M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"></path></svg>
                </button>
                <span class="header-divider"></span>
                <button class="editor-toolbar-btn yaml-editor-fullscreen" data-tooltip="Fullscreen">
                    <svg class="icon-maximize" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M5,5H10V7H7V10H5V5M14,5H19V10H17V7H14V5M17,14H19V19H14V17H17V14M10,17V19H5V14H7V17H10Z"></path></svg>
                    <svg class="icon-minimize" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" style="display:none;"><path fill="currentColor" d="M5,16H8V19H10V14H5V16M14,14V19H16V16H19V14H14M16,5V8H19V10H14V5H16M10,5V10H5V8H8V5H10Z"></path></svg>
                </button>
                <span class="header-divider"></span>
                <button class="editor-toolbar-btn editor-dialog-close" onclick="closeDialog('config-yaml0-dialog')" data-tooltip="Close">
                    <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="currentColor" d="M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z"></path></svg>
                </button>
            </div>
        </div>
        <div class="editor-dialog-content">
            <div class="yaml-editor-container"></div>
        </div>
        <div class="yaml-editor-statusbar">
            <span class="yaml-editor-status"></span>
        </div>
    </div>
    <!-- Locations Popup -->
    <div class="locations-popup" style="display: none;">
        <div class="locations-popup-content">
            <div class="locations-popup-header">
                <span class="locations-header-label">Download and save to:</span>
                <button class="locations-popup-close" aria-label="Close">
                    <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="16" height="16">
                        <path fill="currentColor" d="M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z"></path>
                    </svg>
                </button>
            </div>
            <ul class="locations-list">
                <li>
                    <span class="location-label">Linux / Docker / macOS
                        <span class="help-icon" data-tooltip="Default system location. The engine automatically reads configs from here at startup. Best for production deployments.">
                            <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="12" height="12"><path fill="currentColor" d="M11 18h2v-2h-2v2m1-16A10 10 0 0 0 2 12a10 10 0 0 0 10 10 10 10 0 0 0 10-10A10 10 0 0 0 12 2m0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8m0-14a4 4 0 0 0-4 4h2a2 2 0 0 1 2-2 2 2 0 0 1 2 2c0 2-3 1.75-3 5h2c0-2.25 3-2.5 3-5a4 4 0 0 0-4-4Z"/></svg>
                        </span>
                    </span>
                    <div class="location-path-row">
                        <code class="default-path location-path" data-tooltip=""
                            data-copy-osx="/etc/log10x/config/run/output/event/github/config.yaml"
                            data-copy-nix="/etc/log10x/config/run/output/event/github/config.yaml"
                            data-copy-win="C:\log10x\configs/run/output/event/github/config.yaml"></code>
                        <button class="copy-btn" data-tooltip="Copy path">
                            <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="14" height="14">
                                <path fill="currentColor" d="M19 21H8V7h11m0-2H8a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h11a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2m-3-4H4a2 2 0 0 0-2 2v14h2V3h12V1Z"></path>
                            </svg>
                        </button>
                    </div>
                </li>
                <li>
                    <span class="location-label">Custom directory
                        <span class="help-icon" data-tooltip="Set TENX_CONFIG environment variable to point to a custom config directory. Useful when you want configs in a non-standard location.">
                            <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="12" height="12"><path fill="currentColor" d="M11 18h2v-2h-2v2m1-16A10 10 0 0 0 2 12a10 10 0 0 0 10 10 10 10 0 0 0 10-10A10 10 0 0 0 12 2m0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8m0-14a4 4 0 0 0-4 4h2a2 2 0 0 1 2-2 2 2 0 0 1 2 2c0 2-3 1.75-3 5h2c0-2.25 3-2.5 3-5a4 4 0 0 0-4-4Z"/></svg>
                        </span>
                    </span>
                    <div class="location-path-row">
                        <code class="location-path" data-tooltip="$TENX_CONFIG/run/output/event/github/config.yaml">$TENX_CONFIG/run/output/event/github/config.yaml</code>
                        <button class="copy-btn" data-tooltip="Copy path">
                            <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="14" height="14">
                                <path fill="currentColor" d="M19 21H8V7h11m0-2H8a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h11a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2m-3-4H4a2 2 0 0 0-2 2v14h2V3h12V1Z"></path>
                            </svg>
                        </button>
                    </div>
                </li>
                <li>
                    <span class="location-label">Within cloned repo
                        <span class="help-icon" data-tooltip="First run: git clone github.com/log-10x/config. Then save the file to this path within the cloned folder. Use for version control.">
                            <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="12" height="12"><path fill="currentColor" d="M11 18h2v-2h-2v2m1-16A10 10 0 0 0 2 12a10 10 0 0 0 10 10 10 10 0 0 0 10-10A10 10 0 0 0 12 2m0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8m0-14a4 4 0 0 0-4 4h2a2 2 0 0 1 2-2 2 2 0 0 1 2 2c0 2-3 1.75-3 5h2c0-2.25 3-2.5 3-5a4 4 0 0 0-4-4Z"/></svg>
                        </span>
                    </span>
                    <div class="location-path-row">
                        <code class="location-path" data-tooltip="./pipelines/run/output/event/github/config.yaml">./pipelines/run/output/event/github/config.yaml</code>
                        <button class="copy-btn" data-tooltip="Copy path">
                            <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="14" height="14">
                                <path fill="currentColor" d="M19 21H8V7h11m0-2H8a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h11a2 2 0 0 0 2-2V7a2 2 0 0 0-2-2m-3-4H4a2 2 0 0 0-2 2v14h2V3h12V1Z"></path>
                            </svg>
                        </button>
                    </div>
                </li>
            </ul>
            <div class="locations-popup-footer">
                <button class="locations-download-btn" title="Download config file">
                    <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="14" height="14">
                        <path fill="currentColor" d="M5 20h14v-2H5v2m14-9h-4V3H9v8H5l7 7 7-7Z"></path>
                    </svg>
                    <span>Download</span>
                </button>
            </div>
        </div>
    </div>
</dialog>

<template class="tenx-config-schema" data-encoding="base64">ewogICJ0eXBlIiA6ICJvYmplY3QiLAogICJwcm9wZXJ0aWVzIiA6IHsKICAgICJpbmNsdWRlIiA6IHsKICAgICAgInR5cGUiIDogImFycmF5IiwKICAgICAgIml0ZW1zIiA6IHsKICAgICAgICAidHlwZSIgOiAic3RyaW5nIgogICAgICB9CiAgICB9LAogICAgInRlbngiIDogewogICAgICAidHlwZSIgOiAic3RyaW5nIgogICAgfSwKICAgICJnaXRodWJPdXRwdXQiIDogewogICAgICAidHlwZSIgOiAiYXJyYXkiLAogICAgICAiaXRlbXMiIDogewogICAgICAgICJ0eXBlIiA6ICJvYmplY3QiLAogICAgICAgICJhZGRpdGlvbmFsUHJvcGVydGllcyIgOiBmYWxzZSwKICAgICAgICAicHJvcGVydGllcyIgOiB7CiAgICAgICAgICAidG9rZW4iIDogewogICAgICAgICAgICAidHlwZSIgOiBbCiAgICAgICAgICAgICAgInN0cmluZyIsCiAgICAgICAgICAgICAgIm51bGwiCiAgICAgICAgICAgIF0sCiAgICAgICAgICAgICJtYXJrZG93bkRlc2NyaXB0aW9uIiA6ICJHaXRIdWIgQVBJIGF1dGggdG9rZW5cblxuU3BlY2lmaWVzIHRoZSBHaXRIdWIgQVBJIHdpdGggd2hpY2ggdG8gYXV0aGVudGljYXRlLiBUbyBsZWFybiBtb3JlIHNlZSBbR2l0SHViIHRva2Vuc10oaHR0cHM6Ly9kb2NzLmdpdGh1Yi5jb20vZW4vYXV0aGVudGljYXRpb24va2VlcGluZy15b3VyLWFjY291bnQtYW5kLWRhdGEtc2VjdXJlL21hbmFnaW5nLXlvdXItcGVyc29uYWwtYWNjZXNzLXRva2VucykuIgogICAgICAgICAgfSwKICAgICAgICAgICJyZXBvIiA6IHsKICAgICAgICAgICAgInR5cGUiIDogWwogICAgICAgICAgICAgICJzdHJpbmciLAogICAgICAgICAgICAgICJudWxsIgogICAgICAgICAgICBdLAogICAgICAgICAgICAibWFya2Rvd25EZXNjcmlwdGlvbiIgOiAiTmFtZSBvZiB0YXJnZXQgcmVwb1xuXG5TcGVjaWZpZXMgdGhlIG5hbWUgb2YgdGhlIHRhcmdldCByZXBvIChlLmcuLCB1c2VyL3JlcG8pIgogICAgICAgICAgfSwKICAgICAgICAgICJicmFuY2giIDogewogICAgICAgICAgICAidHlwZSIgOiBbCiAgICAgICAgICAgICAgInN0cmluZyIsCiAgICAgICAgICAgICAgIm51bGwiCiAgICAgICAgICAgIF0sCiAgICAgICAgICAgICJtYXJrZG93bkRlc2NyaXB0aW9uIiA6ICJUYXJnZXQgYnJhbmNoIGludG8gd2hpY2ggdG8gY29tbWl0XG5cblNwZWNpZmllcyB0aGUgbmFtZSBvZiB0aGUgdGFyZ2V0IHJlcG8gYnJhbmNoIChEZWZhdWx0OiByZXBvIGRlZmF1bHQgYnJhbmNoKSIsCiAgICAgICAgICAgICJkZWZhdWx0IiA6ICJyZXBvIGRlZmF1bHQgYnJhbmNoIgogICAgICAgICAgfSwKICAgICAgICAgICJwYXRoIiA6IHsKICAgICAgICAgICAgInR5cGUiIDogWwogICAgICAgICAgICAgICJzdHJpbmciLAogICAgICAgICAgICAgICJudWxsIgogICAgICAgICAgICBdLAogICAgICAgICAgICAibWFya2Rvd25EZXNjcmlwdGlvbiIgOiAiUGF0aCBvZiBhcnRpZmFjdCB3aXRoaW4gdGhlIHRhcmdldCByZXBvIHRvIHVwZGF0ZVxuXG5TcGVjaWZpZXMgdGhlIHBhdGggd2l0aGluIHRoZSB0YXJnZXQgW3JlcG9dKGh0dHBzOi8vZG9jLmxvZzEweC5jb20vcnVuL291dHB1dC9ldmVudC9naXRodWIvI2dpdGh1Ym91dHB1dHJlcG9uYW1lKSBhbmQgW2JyYW5jaF0oaHR0cHM6Ly9kb2MubG9nMTB4LmNvbS9ydW4vb3V0cHV0L2V2ZW50L2dpdGh1Yi8jZ2l0aHVib3V0cHV0YnJhbmNobmFtZSkgdG8gdXBkYXRlLiIKICAgICAgICAgIH0sCiAgICAgICAgICAiaGVhZGVyIiA6IHsKICAgICAgICAgICAgInR5cGUiIDogWwogICAgICAgICAgICAgICJzdHJpbmciLAogICAgICAgICAgICAgICJudWxsIgogICAgICAgICAgICBdLAogICAgICAgICAgICAibWFya2Rvd25EZXNjcmlwdGlvbiIgOiAiSGVhZGVyIHZhbHVlIHRvIHdyaXRlIHRvIG91dHB1dFxuXG5TcGVjaWZpZXMgYXMgaGVhZGVyIHZhbHVlIHRvIHdyaXRlIHRvIHRoZSB0YXJnZXQgW3BhdGhdKGh0dHBzOi8vZG9jLmxvZzEweC5jb20vcnVuL291dHB1dC9ldmVudC9naXRodWIvI2dpdGh1Ym91dHB1dGZpbGVuYW1lKS4gVGhpcyB2YWx1ZSBjYW4gc3BlY2lmeSBhIGhlYWRlciByb3cgd2hlbiBlbWl0dGluZyBhIC5jc3YvLnRzdiBsb29rdXAgZmlsZSBvciBhIGhlYWRlciBjb21tZW50IHZhbHVlIGZvciBhIC55YW1sIGZpbGUuIgogICAgICAgICA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8tZ2VuZXJhdGVkIG1lc3NhZ2UiCiAgICAgICAgICB9LAogICAgICAgICAgInNxdWFzaE1lcmdlIiA6IHsKICAgICAgICAgICAgInR5cGUiIDogWwogICAgICAgICAgICAgICJib29sZWFuIiwKICAgICAgICAgICAgICAic3RyaW5nIiwKICAgICAgICAgICAgICAibnVsbCIKICAgICAgICAgICAgXSwKICAgICAgICAgICAgIm1hcmtkb3duRGVzY3JpcHRpb24iIDogIlVzZSBzcXVhc2ggbWVyZ2Ugd2hlbiBtZXJnaW5nIHB1bGwgcmVxdWVzdHNcblxuU3BlY2lmaWVzIHdoZXRoZXIgdG8gdXNlIHNxdWFzaCBtZXJnZSAodHJ1ZSkgb3IgcmVndWxhciBtZXJnZSAoZmFsc2UpIHdoZW4gbWVyZ2luZyB0aGUgcHVsbCByZXF1ZXN0LiBTcXVhc2ggbWVyZ2UgY29tYmluZXMgYWxsIGNvbW1pdHMgaW50byBhIHNpbmdsZSBjb21taXQsIHJlc3VsdGluZyBpbiBhIGNsZWFuZXIgY29tbWl0IGhpc3RvcnkuIFRoaXMgaXMgdXNlZnVsIGZvciBhdXRvbWF0ZWQgY29tbWl0cyB0aGF0IHJ1biBmcmVxdWVudGx5IChlLmcuLCBHaXRPcHMgcG9saWN5IHVwZGF0ZXMpLiAoQWNjZXB0cyBib29sZWFuIG9yIHN0cmluZyB3aXRoICQ9IHByZWZpeCBmb3IgcnVudGltZSBldmFsdWF0aW9uKSAoRGVmYXVsdDogZmFsc2UpIiwKICAgICAgICAgICAgImRlZmF1bHQiIDogZmFsc2UKICAgICAgICAgIH0sCiAgICAgICAgICAiZmllbGRzIiA6IHsKICAgICAgICAgICAgInR5cGUiIDogWwogICAgICAgICAgICAgICJhcnJheSIsCiAgICAgICAgICAgICAgInN0cmluZyIsCiAgICAgICAgICAgICAgIm51bGwiCiAgICAgICAgICAgIF0sCiAgICAgICAgICAgICJtYXJrZG93bkRlc2NyaXB0aW9uIiA6ICJMaXN0IG9mIFRlblhPYmplY3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gICJ0eXBlIiA6IFsKICAgICAgICAgICAgICAic3RyaW5nIiwKICAgICAgICAgICAgICAibnVsbCIKICAgICAgICAgICAgXSwKICAgICAgICAgICAgIm1hcmtkb3duRGVzY3JpcHRpb24iIDogIlRoZSBvdXRwdXQgZm9ybWF0IGluIHdoaWNoIHRvIGVuY29kZSBUZW5YT2JqZWN0IHZhbHVlcy4gUG9zc2libGUgdmFsdWVzOltqc29uLCBkZWxpbWl0ZWRdXG5cblNwZWNpZmllcyBob3cgdG8gZW5jb2RlIFtnaXRodWJPdXRwdXRGaWVsZHNdKGh0dHBzOi8vZG9jLmxvZzEweC5jb20vcnVuL291dHB1dC9ldmVudC9naXRodWIvI2dpdGh1Ym91dHB1dGZpZWxkcykgdmFsdWVzIHRvIHRoaXMgb3V0cHV0LiBQb3NzaWJsZSB2YWx1ZXM6IC0gKipqc29uKio6IGZvcm1hdHMgbmFtZXMgYW5kIHZhbHVlcyBmb3IgdGhlIGN1cnJlbnQgVGVuWE9iamVjdCBhczoge1wiZmllbGRcIjpcInN0clwiLFwiZmllbGQyXCI6MSwgXCJmaWVsZDNcIjogdHJ1ZX0gLSAqKmRlbGltaXRlZCoqOiBmb3JtYXRzIHZhbHVlcyBmb3IgdGhlIGN1cnJlbnQgVGVuWE9iamVjdCBhczogXCJzdHJcIiwxLHRydWUgICAgVGhlICdnaXRodWJPdXRwdXRFbmNvZGVEZWxpbWl0ZXInIGFyZ3VtZW50IGRldGVybWluZXMgdGhlIHNlcGFyYXRvciB0byB1c2UuIChEZWZhdWx0OiBkZWxpbWl0ZWQpIiwKICAgICAgICAgICAgImRlZmF1bHQiIDogImRlbGltaXRlZCIKICAgICAgICAgIH0sCiAgICAgICAgICAiZW5jb2RlZExpbmVQcmVmaXgiIDogewogICAgICAgICAgICAidHlwZSIgOiBbCiAgICAgICAgICAgICAgInN0cmluZyIsCiAgICAgICAgICAgICAgIm51bGwiCiAgICAgICAgICAgIF0sCiAgICAgICAgICAgICJtYXJrZG93bkRlc2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ICAgICAgICB9CiAgICAgICAgfSwKICAgICAgICAicmVxdWlyZWQiIDogWwogICAgICAgICAgInRva2VuIiwKICAgICAgICAgICJyZXBvIiwKICAgICAgICAgICJwYXRoIgogICAgICAgIF0KICAgICAgfQogICAgfQogIH0sCiAgImFkZGl0aW9uYWxQcm9wZXJ0aWVzIiA6IHRydWUKfQ==</template>

```yaml
# 🔟❎ 'run' GitHub output configuration

# Write TenXObjects instance values to a remote file on GitHub.
# To learn more see https://doc.log10x.com/run/output/event/github/

# Set the 10x pipeline to 'run'
tenx: run

# =============================== Dependencies ================================

include:
  - run/modules/output/event/github

# ============================== Output Options ===============================

# Multiple GitHub outputs can be defined below
githubOutput:

  # ---------------------------- GitHub Options -------------------------------

    # 'authToken' specifies the GitHub API with which to authenticate
  - token: $=yield TenXEnv.get("GH_TOKEN")

    # 'repo' specifies the name of the target repo (e.g., user/repo)
    repo: null # (❗ REQUIRED)

    # 'branch' specifies the target branch into which to commit. Default to main repo branch.
    branch: null

    # 'path' specifies the path of artifact within the target repo to update.
    path: null

    # 'header' specifies as header value to write to the output file (e.g., lookup columns row, YAML comments)
    header: null

    # 'message'  specifies a commit message for this update
    message: null

    # 'pullRequestBody' specifies the body of the pull request used to commit and merge the target file
    pullRequestBody: null

    # 'squashMerge' specifies whether to use squash merge (true) or regular merge (false) when merging pull requests
    #  Squash merge combines all commits into one, keeping commit history clean. Useful for frequent automated commits.
    squashMerge: false

    # --------------------------- Encoding Options ----------------------------

    # 'filter' sets a JavaScript expression that TenXObjects must evaluate as truthy to write to the output.
    #  To learn more see https://doc.log10x.com/run/output/receive/#filter-expressions
    filter: isObject

    # 'fields' defines the fields to write for each TenXObject sent to this output.
    #  To learn more see https://doc.log10x.com/run/output/stream/#outputfields

    fields:
      - encode()

    # 'encodeType' specifies how 'fields' are encoded to output. Possible values: [json,delimited].
    #  To learn more see https://doc.log10x.com/run/output/event/outputStream/#outputstreamencodetype
    encodeType: json
```

## :material-menu: Options

Specify the options below to [configure](/config "configure") multiple GitHub output:

|Name|Description|Category|
|---|---|---|
|[githubOutputToken](#githuboutputtoken "GitHub API auth token")|GitHub API auth token|Github|
|[githubOutputRepo](#githuboutputrepo "name of target repo")|Name of target repo|Github|
|[githubOutputBranch](#githuboutputbranch "target branch into which to commit")|Target branch into which to commit|Github|
|[githubOutputPath](#githuboutputpath "path of artifact within the target repo to update")|Path of artifact within the target repo to update|Github|
|[githubOutputHeader](#githuboutputheader "header value to write to output")|Header value to write to output|Github|
|[githubOutputMessage](#githuboutputmessage "commit message for target file")|Commit message for target file|Github|
|[githubOutputPullRequestBody](#githuboutputpullrequestbody "pull request message for target file")|Pull request message for target file|Github|
|[githubOutputSquashMerge](#githuboutputsquashmerge "use squash merge when merging pull requests")|Use squash merge when merging pull requests|Github|
|[githubOutputFields](#githuboutputfields "list of TenXObject field names to encode")|List of TenXObject field names to encode|Encoding|
|[githubOutputFilter](#githuboutputfilter "a JavaScript expression an TenXObject must evaluate as 'truthy' against to be written to this output")|A JavaScript expression an TenXObject must evaluate as 'truthy' against to be written to this output|Encoding|
|[githubOutputEncodeType](#githuboutputencodetype "the output format in which to encode TenXObject values. Possible values:[json, delimited]")|The output format in which to encode TenXObject values. Possible values:\[json, delimited\]|Encoding|
|[githubOutputEncodedLinePrefix](#githuboutputencodedlineprefix "the line prefix prepended to the encoded event if 'githubOutputEncodeType' is 'delimited'")|The line prefix prepended to the encoded event if 'githubOutputEncodeType' is 'delimited'|Encoding|
|[githubOutputEncodeDelimiter](#githuboutputencodedelimiter "the delimiter placed between key and values pairs if 'githubOutputEncodeType' is 'delimited'")|The delimiter placed between key and values pairs if 'githubOutputEncodeType' is 'delimited'|Encoding|

### Github

#### :material-menu-right-outline:**`githubOutputToken`**

GitHub API auth token.

|Type|Required|Category|
|---|---|---|
|String|✔|Github|

Specifies the GitHub API with which to authenticate.
To learn more see [GitHub tokens](https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/managing-your-personal-access-tokens){target="\_blank"}.


#### :material-menu-right-outline:**`githubOutputRepo`**

Name of target repo.

|Type|Required|Category|
|---|---|---|
|String|✔|Github|

Specifies the name of the target repo (e.g., user/repo).


#### :material-menu-right-outline:**`githubOutputBranch`**

Target branch into which to commit.

|Type|Default|Category|
|---|---|---|
|String|repo default branch|Github|

Specifies the name of the target repo branch.


#### :material-menu-right-outline:**`githubOutputPath`**

Path of artifact within the target repo to update.

|Type|Required|Category|
|---|---|---|
|String|✔|Github|

Specifies the path within the target [repo](https://doc.log10x.com/run/output/event/github/#githuboutputreponame) and [branch](https://doc.log10x.com/run/output/event/github/#githuboutputbranchname) to update.


#### :material-menu-right-outline:**`githubOutputHeader`**

Header value to write to output.

|Type|Default|Category|
|---|---|---|
|String|""|Github|

Specifies as header value to write to the target [path](https://doc.log10x.com/run/output/event/github/#githuboutputfilename). This value
can specify a header row when emitting a .csv/.tsv lookup file or a header comment value for a .yaml file.


#### :material-menu-right-outline:**`githubOutputMessage`**

Commit message for target file.

|Type|Default|Category|
|---|---|---|
|String|auto-generated message|Github|

Specifies a commit message for this update.


#### :material-menu-right-outline:**`githubOutputPullRequestBody`**

Pull request message for target file.

|Type|Default|Category|
|---|---|---|
|String|auto-generated message|Github|

Specifies the body of the pull request used to commit and merge the target [file](https://doc.log10x.com/run/output/event/github/#githuboutputfilename) to
the destination [branch](https://doc.log10x.com/run/output/event/github/#githuboutputbranchname).


#### :material-menu-right-outline:**`githubOutputSquashMerge`**

Use squash merge when merging pull requests.

|Type|Default|Category|
|---|---|---|
|Boolean|false|Github|

Specifies whether to use squash merge (true) or regular merge (false) when merging the pull request.
Squash merge combines all commits into a single commit, resulting in a cleaner commit history.
This is useful for automated commits that run frequently (e.g., GitOps policy updates).


### Encoding

#### :material-menu-right-outline:**`githubOutputFields`**

List of TenXObject field names to encode.

|Type|Default|Category|
|---|---|---|
|List|\[\]|Encoding|

Specifies a list of TenXObject intrinsic/calculated/extracted field names to extract and write to the output.


#### :material-menu-right-outline:**`githubOutputFilter`**

A JavaScript expression an TenXObject must evaluate as 'truthy' against to be written to this output.

|Type|Default|Category|
|---|---|---|
|String|""|Encoding|

Specifies a JavaScript expression that an TenXObject must evaluate as truthy to write its
instance/template field values to this output.

For example, to only emit [timestamped](https://doc.log10x.com/api/js/#TenXBaseObject+timestamped "Return true if length of timestamp is greater than 0") TenXObjects, specify:

```yaml
githubOutputFilter: this.timestamped
```


#### :material-menu-right-outline:**`githubOutputEncodeType`**

The output format in which to encode TenXObject values. Possible values:\[json, delimited\].

|Type|Default|Category|
|---|---|---|
|String|delimited|Encoding|

Specifies how to encode [githubOutputFields](https://doc.log10x.com/run/output/event/github/#githuboutputfields "list of TenXObject field names to encode") values to this output. Possible values:

- **json**: formats names and values for the current TenXObject as: {"field":"str","field2":1, "field3": true}
- **delimited**: formats values for the current TenXObject as: "str",1,true
  The 'githubOutputEncodeDelimiter' argument determines the separator to use.


#### :material-menu-right-outline:**`githubOutputEncodedLinePrefix`**

The line prefix prepended to the encoded event if 'githubOutputEncodeType' is 'delimited'.

|Type|Default|Category|
|---|---|---|
|String||Encoding|

Sets the char which is prepended to the emitted TenXObject field values when [githubOutputEncodeType](https://doc.log10x.com/run/output/event/github/#githuboutputencodetype "the output format in which to encode TenXObject values. Possible values:[json, delimited]") is `delimited`.


#### :material-menu-right-outline:**`githubOutputEncodeDelimiter`**

The delimiter placed between key and values pairs if 'githubOutputEncodeType' is 'delimited'.

|Type|Default|Category|
|---|---|---|
|String| |Encoding|

Sets the char delimiter to separate TenXObject field values when [githubOutputEncodeType](https://doc.log10x.com/run/output/event/github/#githuboutputencodetype "the output format in which to encode TenXObject values. Possible values:[json, delimited]") is 'delimited'.


<br/>:material-github: This module is defined in [github/module.yaml](https://github.com/log-10x/modules/tree/main/pipelines/run/modules/output/event/github/module.yaml "github/module.yaml"){target="\_blank"}.

