https://github.com/jdhitsolutions/PSSessionExport
A PowerShell proof-of-concept module to export and import a PowerShell console session.
https://github.com/jdhitsolutions/PSSessionExport
Last synced: 4 months ago
JSON representation
A PowerShell proof-of-concept module to export and import a PowerShell console session.
- Host: GitHub
- URL: https://github.com/jdhitsolutions/PSSessionExport
- Owner: jdhitsolutions
- License: other
- Created: 2021-03-26T14:40:05.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2022-07-18T15:16:50.000Z (over 2 years ago)
- Last Synced: 2024-11-21T03:39:40.228Z (5 months ago)
- Language: PowerShell
- Size: 1.08 MB
- Stars: 11
- Watchers: 4
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: changelog.md
- License: License.txt
Awesome Lists containing this project
- jimsghstars - jdhitsolutions/PSSessionExport - A PowerShell proof-of-concept module to export and import a PowerShell console session. (PowerShell)
README
# PSSessionExport
This is a demonstration module created in response to an Iron Scripter PowerShell [Challenge](https://ironscripter.us/a-powershell-session-challenge-2/). The goal is to export as much of a PowerShell working console session to a file and then import the saved data in a new PowerShell console session. It is unlikely to reach 100% compatibility, but this module tries to get as close as possible.
It is assumed you will be exporting and importing into the same PowerShell major version, i.e 5 or 7. If you attempt to import across versions, you will get an error.
## Export
You can export the current session to an XML file. You will have to specify if you want to include exporting existing PSSessions and/or CimSessions.

In a new PowerShell session, you can get information about the export.

The module includes functions to import individual items such as Aliases or PSDrives, but it is expected you will import the entire session.

Additional background information on this module can be found at .
## To Do
The project isn't 100% complete. These items should be addressed:
- PSReadline Options and keyhandlers
- CIMSession Options
- PowerShell 7 Experimental Features
- Export custom format data. This should be added from module imports. But there may be stand-alone formats.
- Export custom type. Maybe use the [PSTypeExtensionTools](https://github.com/jdhitsolutions/PSTypeExtensionTools) module and let the user specify what type extensions to export. Anything that was extended by a module should be already be taken care of.
- Help documentation