Add workflows and configuration for syncing and linting subtrees

- Created .github/subtrees.json to define subtree repositories.
- Added linting workflow for subtrees.json in .github/workflows/lint-subtrees.yml.
- Implemented sync workflow for subtrees in .github/workflows/subtree.yml.
- Created subtrees.json and superprojects.json files in database, examples/c, examples/com, and examples/fortran directories.
- Added linting workflows for subtrees.json and superprojects.json in respective directories.
- Established sync workflows for subtrees in examples/c, examples/com, examples/fortran, and src directories.
- Configured subtrees.json and superprojects.json for src and src/phreeqcpp directories.
- Implemented linting workflows for subtrees.json and superprojects.json in src and src/phreeqcpp directories.
- Added common superprojects.json in src/phreeqcpp/common directory.
This commit is contained in:
Charlton, Scott R. 2025-08-06 16:46:25 -06:00
parent 6136c88a50
commit 4a0e162b91
43 changed files with 792 additions and 0 deletions

37
.github/subtrees.json vendored Normal file
View File

@ -0,0 +1,37 @@
[
{
"prefix": "src",
"url": "git@${CI_SERVER_HOST}:${GROUP}-subtrees/iphreeqc-src.git",
"repo": "usgs-coupled-subtrees/iphreeqc-src"
},
{
"prefix": "examples/c",
"url": "git@${CI_SERVER_HOST}:${GROUP}-subtrees/phreeqc-commanuscript-cgfinal-examples-c.git",
"repo": "usgs-coupled-subtrees/phreeqc-commanuscript-cgfinal-examples-c"
},
{
"prefix": "examples/com",
"url": "git@${CI_SERVER_HOST}:${GROUP}-subtrees/phreeqc-commanuscript-cgfinal-examples-com.git",
"repo": "usgs-coupled-subtrees/phreeqc-commanuscript-cgfinal-examples-com"
},
{
"prefix": "examples/fortran",
"url": "git@${CI_SERVER_HOST}:${GROUP}-subtrees/phreeqc-COMManuscript-CGfinal-examples-fortran.git",
"repo": "usgs-coupled-subtrees/phreeqc-COMManuscript-CGfinal-examples-fortran"
},
{
"prefix": "database",
"url": "git@${CI_SERVER_HOST}:${GROUP}-subtrees/phreeqc3-database.git",
"repo": "usgs-coupled-subtrees/phreeqc3-database"
},
{
"prefix": "phreeqc3-doc",
"url": "git@${CI_SERVER_HOST}:${GROUP}-subtrees/phreeqc3-doc.git",
"repo": "usgs-coupled-subtrees/phreeqc3-doc"
},
{
"prefix": "phreeqc3-examples",
"url": "git@${CI_SERVER_HOST}:${GROUP}-subtrees/phreeqc3-examples.git",
"repo": "usgs-coupled-subtrees/phreeqc3-examples"
}
]

19
.github/workflows/lint-subtrees.yml vendored Normal file
View File

@ -0,0 +1,19 @@
name: Lint subtrees.json
on:
pull_request:
paths:
- '.github/subtrees.json'
workflow_call:
workflow_dispatch:
jobs:
lint-subtrees:
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
steps:
- uses: usgs-coupled-subtrees/sync-subtrees-action/lint-subtrees/@main
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

37
.github/workflows/subtree.yml vendored Normal file
View File

@ -0,0 +1,37 @@
name: Sync Subtrees
on:
push:
branches:
- master
workflow_dispatch:
inputs:
dryRun:
description: 'If true, dont push any changes (for testing only).'
required: true
default: false
type: boolean
testMerge:
description: 'Run in test mode, pushing to a test branch.'
required: true
default: false
type: boolean
jobs:
sync-subtrees:
if: startsWith(github.repository, 'usgs-coupled-subtrees/')
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
GH_TOKEN: ${{ secrets.WORKFLOW_PAT }}
steps:
- name: Run sync-subtrees-action
uses: usgs-coupled-subtrees/sync-subtrees-action@main
with:
dryRun: ${{ inputs.dryRun }}
testMerge: ${{ inputs.testMerge }}
repository_name: ${{ github.event.repository.name }}
default_branch: ${{ github.event.repository.default_branch }}
run_number: ${{ github.run_number }}
ssh_private_key: ${{ secrets.SSH_PRIVATE_KEY }}

1
database/.github/subtrees.json vendored Normal file
View File

@ -0,0 +1 @@
[]

11
database/.github/superprojects.json vendored Normal file
View File

@ -0,0 +1,11 @@
{
"usgs-coupled-subtrees/phreeqc3-database": {
"superprojects": [
"usgs-coupled-subtrees/iphreeqc",
"usgs-coupled-subtrees/iphreeqccom",
"usgs-coupled-subtrees/phreeqcrm",
"usgs-coupled-subtrees/phreeqc3",
"usgs-coupled-subtrees/wphast"
]
}
}

View File

@ -0,0 +1,19 @@
name: Lint subtrees.json
on:
pull_request:
paths:
- '.github/subtrees.json'
workflow_call:
workflow_dispatch:
jobs:
lint-subtrees:
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
steps:
- uses: usgs-coupled-subtrees/sync-subtrees-action/lint-subtrees/@main
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

View File

@ -0,0 +1,20 @@
name: Lint superprojects.json
on:
pull_request:
paths:
- '.github/superprojects.json'
workflow_call:
workflow_dispatch:
jobs:
lint-superprojects:
runs-on: ubuntu-latest
steps:
- uses: usgs-coupled-subtrees/sync-subtrees-action/lint-superprojects/@main
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
# skip-repos: |
# - usgs-coupled-subtrees/iphreeqccom
# - usgs-coupled-subtrees/phreeqcrm-src

37
database/.github/workflows/subtree.yml vendored Normal file
View File

@ -0,0 +1,37 @@
name: Sync Subtrees
on:
push:
branches:
- master
workflow_dispatch:
inputs:
dryRun:
description: 'If true, dont push any changes (for testing only).'
required: true
default: false
type: boolean
testMerge:
description: 'Run in test mode, pushing to a test branch.'
required: true
default: false
type: boolean
jobs:
sync-subtrees:
if: startsWith(github.repository, 'usgs-coupled-subtrees/')
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
GH_TOKEN: ${{ secrets.WORKFLOW_PAT }}
steps:
- name: Run sync-subtrees-action
uses: usgs-coupled-subtrees/sync-subtrees-action@main
with:
dryRun: ${{ inputs.dryRun }}
testMerge: ${{ inputs.testMerge }}
repository_name: ${{ github.event.repository.name }}
default_branch: ${{ github.event.repository.default_branch }}
run_number: ${{ github.run_number }}
ssh_private_key: ${{ secrets.SSH_PRIVATE_KEY }}

1
examples/c/.github/subtrees.json vendored Normal file
View File

@ -0,0 +1 @@
[]

9
examples/c/.github/superprojects.json vendored Normal file
View File

@ -0,0 +1,9 @@
{
"usgs-coupled-subtrees/phreeqc-commanuscript-cgfinal-examples-c": {
"superprojects": [
"usgs-coupled-subtrees/iphreeqc",
"usgs-coupled-subtrees/iphreeqccom",
"usgs-coupled-subtrees/phreeqc"
]
}
}

View File

@ -0,0 +1,19 @@
name: Lint subtrees.json
on:
pull_request:
paths:
- '.github/subtrees.json'
workflow_call:
workflow_dispatch:
jobs:
lint-subtrees:
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
steps:
- uses: usgs-coupled-subtrees/sync-subtrees-action/lint-subtrees/@main
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

View File

@ -0,0 +1,16 @@
name: Lint superprojects.json
on:
pull_request:
paths:
- '.github/superprojects.json'
workflow_call:
workflow_dispatch:
jobs:
lint-superprojects:
runs-on: ubuntu-latest
steps:
- uses: usgs-coupled-subtrees/sync-subtrees-action/lint-superprojects/@main
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

View File

@ -0,0 +1,37 @@
name: Sync Subtrees
on:
push:
branches:
- master
workflow_dispatch:
inputs:
dryRun:
description: 'If true, dont push any changes (for testing only).'
required: true
default: false
type: boolean
testMerge:
description: 'Run in test mode, pushing to a test branch.'
required: true
default: false
type: boolean
jobs:
sync-subtrees:
if: startsWith(github.repository, 'usgs-coupled-subtrees/')
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
GH_TOKEN: ${{ secrets.WORKFLOW_PAT }}
steps:
- name: Run sync-subtrees-action
uses: usgs-coupled-subtrees/sync-subtrees-action@main
with:
dryRun: ${{ inputs.dryRun }}
testMerge: ${{ inputs.testMerge }}
repository_name: ${{ github.event.repository.name }}
default_branch: ${{ github.event.repository.default_branch }}
run_number: ${{ github.run_number }}
ssh_private_key: ${{ secrets.SSH_PRIVATE_KEY }}

1
examples/com/.github/subtrees.json vendored Normal file
View File

@ -0,0 +1 @@
[]

View File

@ -0,0 +1,9 @@
{
"usgs-coupled-subtrees/phreeqc-commanuscript-cgfinal-examples-com": {
"superprojects": [
"usgs-coupled-subtrees/iphreeqc",
"usgs-coupled-subtrees/iphreeqccom",
"usgs-coupled-subtrees/phreeqc"
]
}
}

View File

@ -0,0 +1,19 @@
name: Lint subtrees.json
on:
pull_request:
paths:
- '.github/subtrees.json'
workflow_call:
workflow_dispatch:
jobs:
lint-subtrees:
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
steps:
- uses: usgs-coupled-subtrees/sync-subtrees-action/lint-subtrees/@main
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

View File

@ -0,0 +1,16 @@
name: Lint superprojects.json
on:
pull_request:
paths:
- '.github/superprojects.json'
workflow_call:
workflow_dispatch:
jobs:
lint-superprojects:
runs-on: ubuntu-latest
steps:
- uses: usgs-coupled-subtrees/sync-subtrees-action/lint-superprojects/@main
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

View File

@ -0,0 +1,37 @@
name: Sync Subtrees
on:
push:
branches:
- master
workflow_dispatch:
inputs:
dryRun:
description: 'If true, dont push any changes (for testing only).'
required: true
default: false
type: boolean
testMerge:
description: 'Run in test mode, pushing to a test branch.'
required: true
default: false
type: boolean
jobs:
sync-subtrees:
if: startsWith(github.repository, 'usgs-coupled-subtrees/')
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
GH_TOKEN: ${{ secrets.WORKFLOW_PAT }}
steps:
- name: Run sync-subtrees-action
uses: usgs-coupled-subtrees/sync-subtrees-action@main
with:
dryRun: ${{ inputs.dryRun }}
testMerge: ${{ inputs.testMerge }}
repository_name: ${{ github.event.repository.name }}
default_branch: ${{ github.event.repository.default_branch }}
run_number: ${{ github.run_number }}
ssh_private_key: ${{ secrets.SSH_PRIVATE_KEY }}

View File

@ -0,0 +1 @@
[]

View File

@ -0,0 +1,9 @@
{
"usgs-coupled-subtrees/phreeqc-COMManuscript-CGfinal-examples-fortran": {
"superprojects": [
"usgs-coupled-subtrees/iphreeqc",
"usgs-coupled-subtrees/iphreeqccom",
"usgs-coupled-subtrees/phreeqc"
]
}
}

View File

@ -0,0 +1,19 @@
name: Lint subtrees.json
on:
pull_request:
paths:
- '.github/subtrees.json'
workflow_call:
workflow_dispatch:
jobs:
lint-subtrees:
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
steps:
- uses: usgs-coupled-subtrees/sync-subtrees-action/lint-subtrees/@main
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

View File

@ -0,0 +1,16 @@
name: Lint superprojects.json
on:
pull_request:
paths:
- '.github/superprojects.json'
workflow_call:
workflow_dispatch:
jobs:
lint-superprojects:
runs-on: ubuntu-latest
steps:
- uses: usgs-coupled-subtrees/sync-subtrees-action/lint-superprojects/@main
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

View File

@ -0,0 +1,37 @@
name: Sync Subtrees
on:
push:
branches:
- master
workflow_dispatch:
inputs:
dryRun:
description: 'If true, dont push any changes (for testing only).'
required: true
default: false
type: boolean
testMerge:
description: 'Run in test mode, pushing to a test branch.'
required: true
default: false
type: boolean
jobs:
sync-subtrees:
if: startsWith(github.repository, 'usgs-coupled-subtrees/')
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
GH_TOKEN: ${{ secrets.WORKFLOW_PAT }}
steps:
- name: Run sync-subtrees-action
uses: usgs-coupled-subtrees/sync-subtrees-action@main
with:
dryRun: ${{ inputs.dryRun }}
testMerge: ${{ inputs.testMerge }}
repository_name: ${{ github.event.repository.name }}
default_branch: ${{ github.event.repository.default_branch }}
run_number: ${{ github.run_number }}
ssh_private_key: ${{ secrets.SSH_PRIVATE_KEY }}

1
phreeqc3-doc/.github/subtrees.json vendored Normal file
View File

@ -0,0 +1 @@
[]

10
phreeqc3-doc/.github/superprojects.json vendored Normal file
View File

@ -0,0 +1,10 @@
{
"usgs-coupled-subtrees/phreeqc3-doc": {
"superprojects": [
"usgs-coupled-subtrees/iphreeqc",
"usgs-coupled-subtrees/iphreeqccom",
"usgs-coupled-subtrees/phast3-doc",
"usgs-coupled-subtrees/phreeqc3"
]
}
}

View File

@ -0,0 +1,19 @@
name: Lint subtrees.json
on:
pull_request:
paths:
- '.github/subtrees.json'
workflow_call:
workflow_dispatch:
jobs:
lint-subtrees:
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
steps:
- uses: usgs-coupled-subtrees/sync-subtrees-action/lint-subtrees/@main
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

View File

@ -0,0 +1,16 @@
name: Lint superprojects.json
on:
pull_request:
paths:
- '.github/superprojects.json'
workflow_call:
workflow_dispatch:
jobs:
lint-superprojects:
runs-on: ubuntu-latest
steps:
- uses: usgs-coupled-subtrees/sync-subtrees-action/lint-superprojects/@main
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

View File

@ -0,0 +1,37 @@
name: Sync Subtrees
on:
push:
branches:
- master
workflow_dispatch:
inputs:
dryRun:
description: 'If true, dont push any changes (for testing only).'
required: true
default: false
type: boolean
testMerge:
description: 'Run in test mode, pushing to a test branch.'
required: true
default: false
type: boolean
jobs:
sync-subtrees:
if: startsWith(github.repository, 'usgs-coupled-subtrees/')
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
GH_TOKEN: ${{ secrets.WORKFLOW_PAT }}
steps:
- name: Run sync-subtrees-action
uses: usgs-coupled-subtrees/sync-subtrees-action@main
with:
dryRun: ${{ inputs.dryRun }}
testMerge: ${{ inputs.testMerge }}
repository_name: ${{ github.event.repository.name }}
default_branch: ${{ github.event.repository.default_branch }}
run_number: ${{ github.run_number }}
ssh_private_key: ${{ secrets.SSH_PRIVATE_KEY }}

View File

@ -0,0 +1 @@
[]

View File

@ -0,0 +1,19 @@
name: Lint subtrees.json
on:
pull_request:
paths:
- '.github/subtrees.json'
workflow_call:
workflow_dispatch:
jobs:
lint-subtrees:
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
steps:
- uses: usgs-coupled-subtrees/sync-subtrees-action/lint-subtrees/@main
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

View File

@ -0,0 +1,37 @@
name: Sync Subtrees
on:
push:
branches:
- master
workflow_dispatch:
inputs:
dryRun:
description: 'If true, dont push any changes (for testing only).'
required: true
default: false
type: boolean
testMerge:
description: 'Run in test mode, pushing to a test branch.'
required: true
default: false
type: boolean
jobs:
sync-subtrees:
if: startsWith(github.repository, 'usgs-coupled-subtrees/')
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
GH_TOKEN: ${{ secrets.WORKFLOW_PAT }}
steps:
- name: Run sync-subtrees-action
uses: usgs-coupled-subtrees/sync-subtrees-action@main
with:
dryRun: ${{ inputs.dryRun }}
testMerge: ${{ inputs.testMerge }}
repository_name: ${{ github.event.repository.name }}
default_branch: ${{ github.event.repository.default_branch }}
run_number: ${{ github.run_number }}
ssh_private_key: ${{ secrets.SSH_PRIVATE_KEY }}

7
src/.github/subtrees.json vendored Normal file
View File

@ -0,0 +1,7 @@
[
{
"prefix": "phreeqcpp",
"url": "git@${CI_SERVER_HOST}:${GROUP}-subtrees/phreeqc3-src.git",
"repo": "usgs-coupled-subtrees/phreeqc3-src"
}
]

9
src/.github/superprojects.json vendored Normal file
View File

@ -0,0 +1,9 @@
{
"usgs-coupled-subtrees/iphreeqc-src": {
"superprojects": [
"usgs-coupled-subtrees/iphreeqc",
"usgs-coupled-subtrees/iphreeqccom",
"usgs-coupled-subtrees/phreeqcrm-src"
]
}
}

22
src/.github/workflows/lint-subtrees.yml vendored Normal file
View File

@ -0,0 +1,22 @@
# This workflow lints the subtrees.json file to ensure it is valid and up-to-date.
# It is triggered on pull requests that modify the subtrees.json file or can be run manually
# via the GitHub Actions UI.
name: Lint subtrees.json
on:
pull_request:
paths:
- '.github/subtrees.json'
workflow_call:
workflow_dispatch:
jobs:
lint-subtrees:
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
steps:
- uses: usgs-coupled-subtrees/sync-subtrees-action/lint-subtrees/@main
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

View File

@ -0,0 +1,16 @@
name: Lint superprojects.json
on:
pull_request:
paths:
- '.github/superprojects.json'
workflow_call:
workflow_dispatch:
jobs:
lint-superprojects:
runs-on: ubuntu-latest
steps:
- uses: usgs-coupled-subtrees/sync-subtrees-action/lint-superprojects/@main
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

37
src/.github/workflows/subtree.yml vendored Normal file
View File

@ -0,0 +1,37 @@
name: Sync Subtrees
on:
push:
branches:
- master
workflow_dispatch:
inputs:
dryRun:
description: 'If true, dont push any changes (for testing only).'
required: true
default: false
type: boolean
testMerge:
description: 'Run in test mode, pushing to a test branch.'
required: true
default: false
type: boolean
jobs:
sync-subtrees:
if: startsWith(github.repository, 'usgs-coupled-subtrees/')
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
GH_TOKEN: ${{ secrets.WORKFLOW_PAT }}
steps:
- name: Run sync-subtrees-action
uses: usgs-coupled-subtrees/sync-subtrees-action@main
with:
dryRun: ${{ inputs.dryRun }}
testMerge: ${{ inputs.testMerge }}
repository_name: ${{ github.event.repository.name }}
default_branch: ${{ github.event.repository.default_branch }}
run_number: ${{ github.run_number }}
ssh_private_key: ${{ secrets.SSH_PRIVATE_KEY }}

7
src/phreeqcpp/.github/subtrees.json vendored Normal file
View File

@ -0,0 +1,7 @@
[
{
"prefix": "common",
"url": "git@${CI_SERVER_HOST}:${GROUP}-subtrees/phreeqc3-src-common.git",
"repo": "usgs-coupled-subtrees/phreeqc3-src-common"
}
]

View File

@ -0,0 +1,8 @@
{
"usgs-coupled-subtrees/phreeqc3-src": {
"superprojects": [
"usgs-coupled-subtrees/iphreeqc-src",
"usgs-coupled-subtrees/phreeqc3"
]
}
}

View File

@ -0,0 +1,22 @@
# This workflow lints the subtrees.json file to ensure it is valid and up-to-date.
# It is triggered on pull requests that modify the subtrees.json file or can be run manually
# via the GitHub Actions UI.
name: Lint subtrees.json
on:
pull_request:
paths:
- '.github/subtrees.json'
workflow_call:
workflow_dispatch:
jobs:
lint-subtrees:
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
steps:
- uses: usgs-coupled-subtrees/sync-subtrees-action/lint-subtrees/@main
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

View File

@ -0,0 +1,37 @@
name: Sync Subtrees
on:
push:
branches:
- master
workflow_dispatch:
inputs:
dryRun:
description: 'If true, dont push any changes (for testing only).'
required: true
default: false
type: boolean
testMerge:
description: 'Run in test mode, pushing to a test branch.'
required: true
default: false
type: boolean
jobs:
sync-subtrees:
if: startsWith(github.repository, 'usgs-coupled-subtrees/')
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
GH_TOKEN: ${{ secrets.WORKFLOW_PAT }}
steps:
- name: Run sync-subtrees-action
uses: usgs-coupled-subtrees/sync-subtrees-action@main
with:
dryRun: ${{ inputs.dryRun }}
testMerge: ${{ inputs.testMerge }}
repository_name: ${{ github.event.repository.name }}
default_branch: ${{ github.event.repository.default_branch }}
run_number: ${{ github.run_number }}
ssh_private_key: ${{ secrets.SSH_PRIVATE_KEY }}

View File

@ -0,0 +1,7 @@
{
"usgs-coupled-subtrees/phreeqc3-src-common": {
"superprojects": [
"usgs-coupled-subtrees/phreeqc3-src"
]
}
}

View File

@ -0,0 +1,16 @@
name: Lint superprojects.json
on:
pull_request:
paths:
- '.github/superprojects.json'
workflow_call:
workflow_dispatch:
jobs:
lint-superprojects:
runs-on: ubuntu-latest
steps:
- uses: usgs-coupled-subtrees/sync-subtrees-action/lint-superprojects/@main
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}

View File

@ -0,0 +1,37 @@
name: Sync Subtrees
on:
push:
branches:
- master
workflow_dispatch:
inputs:
dryRun:
description: 'If true, dont push any changes (for testing only).'
required: true
default: false
type: boolean
testMerge:
description: 'Run in test mode, pushing to a test branch.'
required: true
default: false
type: boolean
jobs:
sync-subtrees:
if: startsWith(github.repository, 'usgs-coupled-subtrees/')
runs-on: ubuntu-latest
env:
CI_SERVER_HOST: github.com
GROUP: usgs-coupled
GH_TOKEN: ${{ secrets.WORKFLOW_PAT }}
steps:
- name: Run sync-subtrees-action
uses: usgs-coupled-subtrees/sync-subtrees-action@main
with:
dryRun: ${{ inputs.dryRun }}
testMerge: ${{ inputs.testMerge }}
repository_name: ${{ github.event.repository.name }}
default_branch: ${{ github.event.repository.default_branch }}
run_number: ${{ github.run_number }}
ssh_private_key: ${{ secrets.SSH_PRIVATE_KEY }}