Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add output variable to return path where repository has been cloned #1607

Open
kenorb opened this issue Feb 11, 2024 · 0 comments
Open

Add output variable to return path where repository has been cloned #1607

kenorb opened this issue Feb 11, 2024 · 0 comments

Comments

@kenorb
Copy link

kenorb commented Feb 11, 2024

Cloning location sometimes can be confusing and unpredictable and github.workspace not always works in all scenarios, e.g. #785 or when using reusable workflows (workflow call).

So I'm proposing definition of output variable which will return value of path where the repository was cloned.

Example usage:

on:
  workflow_call:
    # Map the workflow outputs to job outputs
    outputs:
      checkout_path:
        value: ${{ jobs.example_job.outputs.checkout_path }}

jobs:
  example_job:
    runs-on: ubuntu-latest
    outputs:
      checkout_path: ${{ steps.checkout_path.outputs.checkout_path }}
    steps:
      - id: checkout_path
        uses: actions/checkout@v4
@kenorb kenorb changed the title Add output to return path where repository has been cloned Add output variable to return path where repository has been cloned Feb 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant