Reputation: 3079
In Maven, I need to provide absolute path to a directory in my project. How can I get absolute path to the directory GitHub action is running in?
Upvotes: 48
Views: 76876
Reputation: 3079
As pointed out by @soltex, ${GITHUB_WORKSPACE}
points to the checkout directory.
Upvotes: 57
Reputation: 3802
In addition to the environment variable described by @Evgeny Bovykin, you can also use the ${{ ...}}
syntax with:
${{ github.workspace }}
See the documentation.
Upvotes: 30