[PR #38] [MERGED] Reintroduced: Allow variables in $ScriptBlock #15

Closed
opened 2026-03-03 13:56:48 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/KelvinTegelaar/RunAsUser/pull/38
Author: @Qumoo
Created: 3/20/2024
Status: Merged
Merged: 4/18/2024
Merged by: @KelvinTegelaar

Base: masterHead: master


📝 Commits (1)

  • d54d4c3 Reintroduced variable expansion, but with switch to prevent breaking older scripts

📊 Changes

1 file changed (+12 additions, -3 deletions)

View changed files

📝 Public/Invoke-AsCurrentUser.ps1 (+12 -3)

📄 Description

This reintroduces variables in ScriptBlocks (as seen in #12 ) but also introduces a new switch -ExpandStringVariables that needs to be set to not break compatibility with older scripts.


🔄 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/KelvinTegelaar/RunAsUser/pull/38 **Author:** [@Qumoo](https://github.com/Qumoo) **Created:** 3/20/2024 **Status:** ✅ Merged **Merged:** 4/18/2024 **Merged by:** [@KelvinTegelaar](https://github.com/KelvinTegelaar) **Base:** `master` ← **Head:** `master` --- ### 📝 Commits (1) - [`d54d4c3`](https://github.com/KelvinTegelaar/RunAsUser/commit/d54d4c3dc4e4ff022ede01d1a3540778909bbb41) Reintroduced variable expansion, but with switch to prevent breaking older scripts ### 📊 Changes **1 file changed** (+12 additions, -3 deletions) <details> <summary>View changed files</summary> 📝 `Public/Invoke-AsCurrentUser.ps1` (+12 -3) </details> ### 📄 Description This reintroduces variables in ScriptBlocks (as seen in #12 ) but also introduces a new switch -ExpandStringVariables that needs to be set to not break compatibility with older scripts. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-03 13:56:48 +03:00
Sign in to join this conversation.
No labels
pull-request
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/RunAsUser#15
No description provided.