Skip to content

Git Deploy Action

Actions
Sync current repository to a remote repository on GitHub, GitLab, AWS CodeCommit, etc
v1.1
Latest
Star (1)

GitHub Action build status

Git Repository Sync Action

This action pushes all commits in the branch that this action is run on into any remote git repository.

Check out a sample workflow.

Usage

Be sure to run the actions/checkout action in a step before this action so that the git repository is initialized.

- uses: actions/checkout@v3
  with:
    fetch-depth: 0
    ref: main
- uses: ayr-ton/[email protected]
  with:
    # The SSH private key for SSH connection to the target repository.
    # We strongly recommend saving this value as a GitHub Secret and using deploy
    # keys within the target repository
    ssh_private_key: ${{ secrets.SSH_PRIVATE_KEY }}
    # The SSH-based URL to the target repository
    target_repo_url: [email protected]:ayr-ton/git-deploy-action-test.git
    # The branch to push to the target repository, mandatory
    target_branch: main

Notes

Inspired by the following actions which may be more suitable for your workflow, e.g. syncing any source repository and branch to any destination, or copying all branches.

TODO

  • Support for the pull_request event

License

The scripts and documentation in this project are released under the MIT License

Git Deploy Action is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.

About

Sync current repository to a remote repository on GitHub, GitLab, AWS CodeCommit, etc
v1.1
Latest

Git Deploy Action is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.