How to find UDID of your iphone without installing any third party app on Mac M1 or Mac M2

 Ever wondered on how to check the UDID of your iphone without installing any third party app in a mac using Apple Silicon chip? Here are the steps you should follow: Connect your iphone with USB Open Apple Music app and you should see your device there Next, click on the iphone label and you should see the UDID

How to minify JSON in powershell?

 Recently, I had a requirement to minify json using powershell and I learnt that it is pretty simple and thought of adding it to my blog as well so that it can serve as future notes for me as well.

Here is my sample JSON

[
  {
    "name": "gaurav",
    "age": "32",
    "id": 1
  },
  {
    "name": "sunny",
    "age": "35",
    "id": 2
  }
]

Here is the powershell script:
$report = Get-Content './report.json' | Out-String
$minifiedJSON = (ConvertFrom-Json $report) | ConvertTo-Json -Compress;
Write-Host $minifiedJSON;
$minifiedJSON | Out-File -FilePath '.\minified.json'
Here is the output:
[{"name":"gaurav","age":"32","id":1},{"name":"sunny","age":"35","id":2}]