Skip to content

Simple powershell functions to convert from and to json. Very lightweight, will be supported with every powershell version. No dependences.

Notifications You must be signed in to change notification settings

double-o-z/Powershell-JSON-Lightweight-Serializer-Deserializer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 

Repository files navigation

Powershell-JSON-Lightweight-Serializer-Deserializer

Simple powershell functions to convert from and to json. Very lightweight, will be supported with every powershell version. No dependencies. Can convert any json data to powershell data structure.

Example usage:

$JSON = Get-Content .\data.json -Encoding utf8

Convert from json to powershell data structure (Deserialize):

$a = $JSON | ConvertFrom-JSON-Stable $a.GetType().Name

Hashtable

$a[0].prop += 1

Convert from powershell data structure to json (Serialize):

$b = $a | ConvertTo-JSON-Stable

Set-Content -Path .\data.json -Value $b -Encoding utf8

About

Simple powershell functions to convert from and to json. Very lightweight, will be supported with every powershell version. No dependences.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published