Skip to content

Conversation

@daniel-carr-3000
Copy link
Contributor

Description

This PR fixes #531 where the environment variables were not being passed to cmd on Windows.

Motivation and Context

It breaks some of the functionality of being able to run custom shell commands in the preprocessor.

How Has This Been Tested?

I've tested to verify that when using the COMMIT_SHA environment variable in the traditional cmd fashion %COMMIT_SHA% that it is now properly available to shell commands.

Tested on Windows 11.

Screenshots / Logs (if applicable)

Types of Changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation (no code change)
  • Refactor (refactoring production code)
  • Other

Checklist:

  • My code follows the code style of this project.
  • I have updated the documentation accordingly.
  • I have formatted the code with rustfmt.
  • I checked the lints with clippy.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@daniel-carr-3000 daniel-carr-3000 requested a review from orhun as a code owner March 4, 2024 16:59
@welcome
Copy link

welcome bot commented Mar 4, 2024

Thanks for opening this pull request! Please check out our contributing guidelines! ⛰️

@codecov-commenter
Copy link

codecov-commenter commented Mar 4, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 41.14%. Comparing base (8f8e221) to head (705f6b1).
Report is 344 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #532   +/-   ##
=======================================
  Coverage   41.14%   41.14%           
=======================================
  Files          15       15           
  Lines        1038     1038           
=======================================
  Hits          427      427           
  Misses        611      611           
Flag Coverage Δ
unit-tests 41.14% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
Owner

@orhun orhun left a comment

Choose a reason for hiding this comment

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

Thank you for the fix!

@orhun orhun changed the title fix: Adds environment variables for replace_command in Windows fix(command): add missing environment variables for Windows Mar 4, 2024
@orhun orhun merged commit 9722784 into orhun:main Mar 4, 2024
@welcome
Copy link

welcome bot commented Mar 4, 2024

Congrats on merging your first pull request! ⛰️

@daniel-carr-3000 daniel-carr-3000 deleted the env-windows branch March 4, 2024 18:22
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.

Environment Variables aren't set for replace_command in Windows

3 participants