> For the complete CircleCI developer hub index, see [llms.txt](https://circleci.com/developer/llms.txt)

# butterflynetwork/git-submodule-changes

An orb for detecting git submodule changes. The `git log -p --first-parent --merges -1` command is ran and the output text is searched for the `Submodule ` string. For each occurrence detected a line is created in a specific ouptut parameter file.
Ex. A repository contains two git submodules: sub-project-1 and sub-project-2. The last push had changes to the sub-project-2. The git-submodule-changes orb will generate a file containing the following content `{"sub-project-2": "true"}``.


## Commands

### set-parameters

Generates a set of pipeline parameters at `output-path`.


| Parameter | Type | Default | Description |
|---|---|---|---|
| `output-path` | string | /tmp/pipeline-parameters.json | Path to save the generated parameters to.
 |

## Jobs

### continue-with-changed

Continues a pipeline in the `setup` state based with static config and a set of pipeline parameters based detected git submodule changes.


| Parameter | Type | Default | Description |
|---|---|---|---|
| `circleci_domain` | string | circleci.com | The domain of the CircleCI installation - defaults to circleci.com. (Only necessary for CircleCI Server users) |
| `config-path` | string | .circleci/continue_config.yml | The location of the config to continue the pipeline with.
 |
| `resource_class` | string | small | Resource class to use |
| `workspace_path` | string |  | Path to attach the workspace to |

## Executors

### default

This is a sample executor using Docker and Python.


| Parameter | Type | Default | Description |
|---|---|---|---|
| `tag` | string | 3.10 | Pick a specific circleci/python image variant: https://hub.docker.com/r/cimg/python/tags
 |

## Examples

### example

Continue a pipeline from the setup phase with pipeline parameters generated from the detected git submodule changes.


```yaml
version: '2.1'
orbs:
  git-submodule-changes: butterflynetwork/git-submodule-changes@0.0.1
workflows:
  generate-config:
    jobs:
      - git-submodule-changes/continue-with-changed:
          config-path: .circleci/continue-config.yml
```