[PR #386] [MERGED] When running on Windows the correct path separator must be used #1432

Closed
opened 2026-03-01 21:51:09 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/nektos/act/pull/386
Author: @taliesins
Created: 10/8/2020
Status: Merged
Merged: 10/9/2020
Merged by: @cplee

Base: masterHead: fix-windows-path-problems


📝 Commits (5)

  • 5e4c6f1 When running on Windows the correct path separator must be used. filePath.join is OS aware, so when we want to use forward slash use path.join instead.
  • 8af2e4b When calculating relative folders on Windows for destination path on Linux, we need to change \ for /
  • ea76869 Reduce complexity by extracting methods
  • a728146 V1 does not point to a file that does not exist
  • 68f2296 Looks like something else is the cause of this test breaking. Last successful build is #371, builds after that are failing

📊 Changes

3 files changed (+35 additions, -17 deletions)

View changed files

📝 pkg/runner/run_context.go (+1 -1)
📝 pkg/runner/runner_test.go (+1 -1)
📝 pkg/runner/step_context.go (+33 -15)

📄 Description

…Path.join is OS aware, so when we want to use forward slash use path.join instead.

on windows docker cp should end with . when copying a directory
when running npm modules we should pass in path with all forward slashes

This fixes #331


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/nektos/act/pull/386 **Author:** [@taliesins](https://github.com/taliesins) **Created:** 10/8/2020 **Status:** ✅ Merged **Merged:** 10/9/2020 **Merged by:** [@cplee](https://github.com/cplee) **Base:** `master` ← **Head:** `fix-windows-path-problems` --- ### 📝 Commits (5) - [`5e4c6f1`](https://github.com/nektos/act/commit/5e4c6f129efec78b31e84738b8382c342f10cc7c) When running on Windows the correct path separator must be used. filePath.join is OS aware, so when we want to use forward slash use path.join instead. - [`8af2e4b`](https://github.com/nektos/act/commit/8af2e4b94af0414c8c2afe0df5baf9a9be58ecf1) When calculating relative folders on Windows for destination path on Linux, we need to change \ for / - [`ea76869`](https://github.com/nektos/act/commit/ea768698d8a34ed085367185b32a5f89669a0c88) Reduce complexity by extracting methods - [`a728146`](https://github.com/nektos/act/commit/a7281464925a5f6abc9e963921c3fdb143af0d12) V1 does not point to a file that does not exist - [`68f2296`](https://github.com/nektos/act/commit/68f22969f518fa9dfe097bf8d9781d761d487d2e) Looks like something else is the cause of this test breaking. Last successful build is #371, builds after that are failing ### 📊 Changes **3 files changed** (+35 additions, -17 deletions) <details> <summary>View changed files</summary> 📝 `pkg/runner/run_context.go` (+1 -1) 📝 `pkg/runner/runner_test.go` (+1 -1) 📝 `pkg/runner/step_context.go` (+33 -15) </details> ### 📄 Description …Path.join is OS aware, so when we want to use forward slash use path.join instead. on windows docker cp should end with \. when copying a directory when running npm modules we should pass in path with all forward slashes This fixes #331 --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-01 21:51:09 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/act#1432
No description provided.