Skip to content

Conversation

@JustinGrote
Copy link
Contributor

@JustinGrote JustinGrote commented Apr 2, 2025

PR Summary

Implements an updated devcontainer specification for quickly bootstrapping the PowerShell development environment.

Screen.Recording.2025-05-10.001357.mp4

Users can use this devcontainer locally, or develop in Github Codespaces (free minutes for Github users).

  • Updated to official .NET SDK Devcontainer (the team no longer supports PowerShell containers)
  • Lifecycle scripts all written in PowerShell for easy updates/maintenance!
  • Auto-Installs current .NET SDK per the global.json in the repository, reducing churn
  • Bootstraps the environment per the current linux development documentation spec
  • Supports Hot Reload Debug for SMA! (Modules not supported yet)
  • Prebuilds in GitHub Codespaces for rapid access

Additional Setup Necessary by PowerShell Team

  1. Codespace prebuilds must be enabled in the PowerShell repository. This enables a bot that performs the prebuilds and uploads them. As PowerShell is an open public project, there is no storage cost to these images.

As this is developer tooling only, this is a low impact/low risk PR.

Demonstration

You can test this PR by going to Codespace Creation for the upstream branch.

You can also demo a more typical user experience by:

  1. Go to https://github.com/JustinGrote/_PR-PowerShell/tree/feature/devcontainer
  2. Hit comma (,) on your keyboard or click + on the codespaces menu
    image

PR Context

I, as a PowerShell contributor or someone new to PowerShell development, want to at a click of a button have an environment where I can immediately start building, testing, and contributing to PowerShell, whether that is local to my own machine, in Github Codespaces, or anywhere that devcontainers are supported.

PR Checklist

@JustinGrote JustinGrote changed the title New Devcontainer Configuration Update Devcontainer Configuration Apr 3, 2025
@iSazonov iSazonov added the CL-BuildPackaging Indicates that a PR should be marked as a build or packaging change in the Change Log label Apr 3, 2025
@microsoft-github-policy-service microsoft-github-policy-service bot added the Review - Needed The PR is being reviewed label Apr 16, 2025
@JustinGrote
Copy link
Contributor Author

@iSazonov friendly bump, this has sat idle for 30 days. Is there a particular team/WG I should be petitioning?

@iSazonov iSazonov added the Area-Maintainers-Build specific to affecting the build label May 6, 2025
@iSazonov
Copy link
Collaborator

iSazonov commented May 6, 2025

@TravisEz13 Is MSFT team interested in creating the development container?

@microsoft-github-policy-service microsoft-github-policy-service bot removed the Review - Needed The PR is being reviewed label May 6, 2025
@JustinGrote
Copy link
Contributor Author

JustinGrote commented May 6, 2025

@TravisEz13 Is MSFT team interested in creating the development container?

To be clear, there's nothing the team has to "create", it's already done by the dotnet team.

If you are referring to the prebuilds, it's just a toggle setting on the Powershell repo, and it's optional but makes the initial startup time of the devcontainer faster.

EDIT: Friendly Bump. @iSazonov and @TravisEz13 this is development tooling and does not affect the build process or anyone not using devcontainer (probably basically everyone but me 🙂), and the existing devcontainer config is way out of date and non-functional anyways, so this should be a pretty low barrier merge.

@iSazonov
Copy link
Collaborator

iSazonov commented May 8, 2025

@bergmeister Could you please review?

@JustinGrote JustinGrote force-pushed the feature/devcontainer branch from 4ee9ec5 to ac66cf5 Compare May 8, 2025 20:20
@JustinGrote JustinGrote requested review from a team and jshigetomi as code owners May 8, 2025 21:11
@JustinGrote
Copy link
Contributor Author

  • Incoporated @iSazonov feedback (thank you as always!)
  • Updated/Fixed/Rearranged some related developer documentation, if you want me to split this off into a separate PR, let me know.
  • Fixed some edge cases I found when going through a bunch of development testing in various environments
  • Updated the build task Start-PSPester to explicity only install/load Pester 4.2-4.99, and unload Pester 5 if present.

Copy link
Collaborator

@iSazonov iSazonov left a comment

Choose a reason for hiding this comment

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

@JustinGrote I see too many unrelated changes. Please move them to other PRs to keep the PR as small as possible.

@JustinGrote JustinGrote requested a review from iSazonov May 9, 2025 15:19
@iSazonov
Copy link
Collaborator

iSazonov commented May 9, 2025

@JustinGrote I have no experience working with dev containers so we need more reviewers.
Also please move docs and other unrelated to dev container changes to separate PRs.

@JustinGrote JustinGrote force-pushed the feature/devcontainer branch from 3c62181 to be68dc3 Compare May 9, 2025 19:22
@JustinGrote JustinGrote force-pushed the feature/devcontainer branch from be68dc3 to cacde42 Compare May 9, 2025 19:31
@JustinGrote
Copy link
Contributor Author

@iSazonov unrelated changes moved to PRs (the vscode task changes are relevant to the devcontainer).

@jshigetomi @bergmeister request re-review. Also if there isn't a lot of interest in maintaining this section, is it possible I could be added to CODEOWNERS for it? It doesn't affect the build process in any way, it's purely developer tooling configuration.

@microsoft-github-policy-service microsoft-github-policy-service bot added Waiting on Author The PR was reviewed and requires changes or comments from the author before being accept and removed Waiting on Author The PR was reviewed and requires changes or comments from the author before being accept labels May 9, 2025
@microsoft-github-policy-service microsoft-github-policy-service bot added the Waiting on Author The PR was reviewed and requires changes or comments from the author before being accept label May 20, 2025
@JustinGrote
Copy link
Contributor Author

Still active.

@microsoft-github-policy-service microsoft-github-policy-service bot added Waiting on Author The PR was reviewed and requires changes or comments from the author before being accept and removed Waiting on Author The PR was reviewed and requires changes or comments from the author before being accept Stale labels Jun 4, 2025
@JustinGrote
Copy link
Contributor Author

Still active

@microsoft-github-policy-service microsoft-github-policy-service bot added Waiting on Author The PR was reviewed and requires changes or comments from the author before being accept and removed Waiting on Author The PR was reviewed and requires changes or comments from the author before being accept Stale labels Jun 23, 2025
@JustinGrote
Copy link
Contributor Author

Still active.

@microsoft-github-policy-service microsoft-github-policy-service bot added Waiting on Author The PR was reviewed and requires changes or comments from the author before being accept and removed Waiting on Author The PR was reviewed and requires changes or comments from the author before being accept Stale labels Jul 14, 2025
@JustinGrote
Copy link
Contributor Author

Still active

@microsoft-github-policy-service microsoft-github-policy-service bot added Waiting on Author The PR was reviewed and requires changes or comments from the author before being accept and removed Waiting on Author The PR was reviewed and requires changes or comments from the author before being accept Stale labels Aug 4, 2025
@JustinGrote
Copy link
Contributor Author

Still active

@microsoft-github-policy-service microsoft-github-policy-service bot added Waiting on Author The PR was reviewed and requires changes or comments from the author before being accept and removed Waiting on Author The PR was reviewed and requires changes or comments from the author before being accept Stale labels Aug 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area-Maintainers-Build specific to affecting the build CL-BuildPackaging Indicates that a PR should be marked as a build or packaging change in the Change Log Waiting on Author The PR was reviewed and requires changes or comments from the author before being accept

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants