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 support to customize working directory #1493

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

accodev
Copy link

@accodev accodev commented Sep 21, 2023

Allow the users to customize the working directory where the commands of the action will be executed, e.g.: c:, /home/user, etc.
This is to allow the users to switch to a different mount point (for example github hosted windows runners offer quite a bit of space but the checkout process happens on d:, where the space is only 14GB).
Sometimes it is not feasible to copy the repository after cloning it because:

@accodev accodev requested a review from a team as a code owner September 21, 2023 15:12
@dasigvr
Copy link

dasigvr commented Sep 22, 2023

Yes! This is badly needed in our use case.

@accodev
Copy link
Author

accodev commented Oct 12, 2023

Any chance this could get a review?

@interifter
Copy link

@ericsciple this would be awesome to get added

@accodev accodev marked this pull request as draft November 24, 2023 19:31
@accodev accodev marked this pull request as ready for review November 24, 2023 19:31
@accodev accodev requested a review from a team as a code owner November 24, 2023 19:31
Copy link

@pdxjohnny pdxjohnny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@snps-midhunn
Copy link

Hello,
Is there any update on when we can expect this to be part of the official release? We are very much in need of this feature too.

@Rsnipeu
Copy link

Rsnipeu commented Dec 27, 2023

Merge

Copy link

@Rsnipeu Rsnipeu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Copy link

@Rsnipeu Rsnipeu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Merge

Copy link

@Pospelove Pospelove left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Go gogo gog

@WiehanVanNiekerk
Copy link

Is there any tracking regarding this PR?

Copy link

@WiehanVanNiekerk WiehanVanNiekerk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks all good for me. Do you know if we can get this in? We need this for our enterprise org repo's workflows.

@WiehanVanNiekerk
Copy link

@WiehanVanNiekerk
Copy link

@jww3 Please can you assist

@interifter
Copy link

Related/possible duplicate issues:

#955
actions/runner#1676 (Where I believe this should actually be solved, as this is where the workspace-related code is - see https://github.com/actions/runner/blob/main/src/Runner.Worker/TrackingConfig.cs#L20)
https://github.com/orgs/community/discussions/118587

Let user override $GITHUB_WORKSPACE as default working directory

Defaults to undefined, the original behaviour is maintained
Add working-directory input parameter
Add working-directory
Not needed (working-directory option is used internally)
Remove path.sep during comparison with repositoryPath
(did not take in account root folders)
Updated and added more unit tests
Updated dist/index.js
@accodev accodev force-pushed the feature/customizable-working-dir branch from 4cd8c93 to 8461fff Compare April 25, 2024 15:56
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

Successfully merging this pull request may close these issues.

None yet

8 participants