[{"data":1,"prerenderedAt":1820},["Reactive",2],{"navigation":3,"/posts/automate-developer-machine":204,"/posts/automate-developer-machine-surround":1795},[4,192,200],{"title":5,"_path":6,"children":7,"icon":191},"Blog","/posts",[8,11,14,17,20,23,26,29,32,35,38,41,44,47,50,53,56,59,62,65,68,71,74,77,80,83,86,89,92,95,98,101,104,107,110,113,116,119,122,125,128,131,134,137,140,143,146,149,152,155,158,161,164,167,170,173,176,179,182,185,188],{"title":9,"_path":10},"Testing your API with REST Client","/posts/testing-your-api-with-rest-client",{"title":12,"_path":13},"HTML templating in Xamarin","/posts/html-templating-in-xamarin",{"title":15,"_path":16},"Goodbye Azure Portal, Welcome Azure CLI","/posts/welcome-azure-cli",{"title":18,"_path":19},"Coming across Gitpod","/posts/gitpod",{"title":21,"_path":22},"Handle token retrieval while querying an API","/posts/delegating-handler",{"title":24,"_path":25},"Clean up your local git branches.","/posts/cleaning-git-branches",{"title":27,"_path":28},"Automate configuration of Teams Tab SSO with PowerShell.","/posts/teams-sso-powershell",{"title":30,"_path":31},"How to do a technology watch? - Part 1","/posts/technology-watch-part1",{"title":33,"_path":34},"How to do a technology watch? - Part 2","/posts/technology-watch-part2",{"title":36,"_path":37},"You almost no longer need Key Vault references for Azure Functions.","/posts/azure-functions-custom-configuration",{"title":39,"_path":40},"How to do a technology watch? - Part 3","/posts/technology-watch-part3",{"title":42,"_path":43},"Forget DevOps, the future is already here!","/posts/devops-future",{"title":45,"_path":46},"Week 9, 2021 - Tips I learned this week","/posts/w09-2021-tips-learned-this-week",{"title":48,"_path":49},"Week 12, 2021 - Tips I learned this week","/posts/w12-2021-tips-learned-this-week",{"title":51,"_path":52},"Week 14, 2021 - Tips I learned this week","/posts/w14-2021-tips-learned-this-week",{"title":54,"_path":55},"Once upon a time in .NET","/posts/once-upon-a-time-in-dotnet",{"title":57,"_path":58},"Install your applications with winget","/posts/winget-import",{"title":60,"_path":61},"Customize your applications when installing them with winget","/posts/winget-override",{"title":63,"_path":64},"Week 22, 2021 - Tips I learned this week","/posts/w22-2021-tips-learned-this-week",{"title":66,"_path":67},"How to connect to an Azure SQL Database from C# using Azure AD","/posts/sqlclient-active-directory-authent",{"title":69,"_path":70},"Producing packages for Windows Package Manager","/posts/wingetcreate",{"title":72,"_path":73},"4 tips about GitHub Actions environment variables and contexts","/posts/github-actions-var-and-context",{"title":75,"_path":76},"AzureWebJobsStorage, the secret you don't need in your Function App.","/posts/azure-functions-without-azurewebjobsstorage",{"title":78,"_path":79},"ASP.NET Core - Lost in configuration","/posts/lost-in-configuration",{"title":81,"_path":82},"Week 39, 2021 - Tips I learned this week","/posts/w39-2021-tips-learned-this-week",{"title":84,"_path":85},"Week 41, 2021 - Tips I learned this week","/posts/w41-2021-tips-learned-this-week",{"title":87,"_path":88},"Migrating and open-sourcing my blog","/posts/migrating-blog",{"title":90,"_path":91},"Week 45, 2021 - Tips I learned this week","/posts/w45-2021-tips-learned-this-week",{"title":93,"_path":94},"Organize your GitHub stars with Astral","/posts/astral",{"title":96,"_path":97},"Pulumi with an Azure Blob Storage backend","/posts/pulumi-azure-backend",{"title":99,"_path":100},"IaC Hot Reload with Pulumi Watch","/posts/pulumi-watch",{"title":102,"_path":103},"Week 2, 2022 - Tips I learned this week","/posts/w02-2022-tips-learned-this-week",{"title":105,"_path":106},"Week 3, 2022 - Tips I learned this week","/posts/w03-2022-tips-learned-this-week",{"title":108,"_path":109},"Week 5, 2022 - Tips I learned this week","/posts/w05-2022-tips-learned-this-week",{"title":111,"_path":112},"How to provision an Azure SQL Database with Active Directory authentication","/posts/sqldatabase-active-directory-authent",{"title":114,"_path":115},"Why will I choose Pulumi over Terraform for my next project?","/posts/pulumi-vs-terraform",{"title":117,"_path":118},"Week 19, 2022 - Tips I learned this week","/posts/w19-2022-tips-learned-this-week",{"title":120,"_path":121},"Week 20, 2022 - Tips I learned this week","/posts/w20-2022-tips-learned-this-week",{"title":123,"_path":124},"Keeping secrets secure when using API Clients","/posts/http-clients-secrets",{"title":126,"_path":127},"What made me want to be a developer?","/posts/be-a-developer",{"title":129,"_path":130},"What can we do when stuck with a programming problem?","/posts/get-unstuck",{"title":132,"_path":133},"How did I automate the setup of my developer Windows laptop?","/posts/automate-developer-machine",{"title":135,"_path":136},"Discussion about API clients","/posts/http-clients",{"title":138,"_path":139},"Week 46, 2022 - Tips I learned this week","/posts/w46-2022-tips-learned-this-week",{"title":141,"_path":142},"When Pulumi met Nuke: a .NET love story","/posts/when-pulumi-met-nuke",{"title":144,"_path":145},"A year of learning and sharing - Dev Retro 2022","/posts/2022-retro",{"title":147,"_path":148},"Perform Dynamic Execution of an npm Package","/posts/pnpm-dlx",{"title":150,"_path":151},"Manage multiple Node.js versions","/posts/pnpm-env",{"title":153,"_path":154},"Introducing the Vue.js CI/CD series","/posts/vuecicd-introduction",{"title":156,"_path":157},"Execute commands using your project dependencies","/posts/pnpm-exec",{"title":159,"_path":160},"Vue.js CI/CD: Continuous Integration","/posts/vuecicd-ci",{"title":162,"_path":163},"Who is using pnpm?","/posts/pnpm-who-is-using",{"title":165,"_path":166},"Create an Azure-Ready GitHub Repository using Pulumi","/posts/azure-ready-github-repository",{"title":168,"_path":169},"Deploying to Azure from Azure DevOps without secrets","/posts/ado-workload-identity-federation",{"title":171,"_path":172},"Effortlessly Configure GitHub Repositories for Azure Deployment via OIDC","/posts/scripting-azure-ready-github-repository",{"title":174,"_path":175},"Playing with the .NET 8 Web API template","/posts/playing-with-dotnet8",{"title":177,"_path":178},"Another year of sharing and learning - Dev Retro 2023","/posts/2023-retro",{"title":180,"_path":181},"Week 4, 2024 - Tips I learned this week","/posts/w04-2024-tips-learned-this-week",{"title":183,"_path":184},"Using dependency injection with Azure .NET SDK","/posts/azure-sdk-di",{"title":186,"_path":187},"Having Fun With IT Event Calendars","/posts/it-event-calendars",{"title":189,"_path":190},"Call your Azure AD B2C protected API with authenticated HTTP requests from your JetBrains IDE","/posts/http-clients-oauth2","i-heroicons-newspaper",{"title":193,"_path":194,"children":195,"icon":199},"Goodies","/goodies",[196],{"title":197,"_path":198},"My Git Cheat Sheet","/goodies/gitcheatsheet","i-heroicons-gift-solid",{"title":201,"_path":202,"icon":203},"About","/about","i-heroicons-user-circle-solid",{"_path":133,"_dir":205,"_draft":206,"_partial":206,"_locale":207,"title":132,"description":208,"lead":209,"date":210,"badge":211,"image":213,"tags":215,"body":221,"_type":1790,"_id":1791,"_source":1792,"_file":1793,"_extension":1794},"posts",false,"","In this article, I talked about my latest project: how I built a script to automate the setup of my developer machine using Boxstarter, Chocolatey, Winget, and PowerShell... and how I learned a few things along the way.","A git repository, 2 packages managers, a little bit of scripting, and here is my new environment ready","2022-09-02T00:00:00.000Z",{"label":212},"Tooling",{"src":214},"/images/laptop_2.jpg",[216,217,218,219,220],"development box setup","PowerShell","winget","package manager","tooling",{"type":222,"children":223,"toc":1777},"root",[224,231,238,243,248,260,265,290,296,301,326,358,380,410,419,429,449,454,585,597,603,610,632,637,654,660,665,674,679,684,768,776,781,795,809,815,838,877,882,1152,1175,1180,1228,1236,1242,1247,1438,1458,1464,1469,1478,1483,1533,1545,1622,1627,1632,1638,1643,1665,1679,1684,1711,1725,1731,1743,1748,1753,1766,1771],{"type":225,"tag":226,"props":227,"children":228},"element","p",{},[229],{"type":230,"value":208},"text",{"type":225,"tag":232,"props":233,"children":235},"h2",{"id":234},"context",[236],{"type":230,"value":237},"Context",{"type":225,"tag":226,"props":239,"children":240},{},[241],{"type":230,"value":242},"You have probably already faced this situation when you get a new personal or professional laptop, and you have to reinstall all the software you are using daily on this machine. Usually, you lose a few hours to a day to set up your developer environment and not everything is exactly as it was on your previous laptop because you always forget some things.",{"type":225,"tag":226,"props":244,"children":245},{},[246],{"type":230,"value":247},"It's not even only about installing software but also configuring your environment to meet your habits. And that's important because a properly configured developer environment with the right tools is what makes you productive in your everyday developer life.",{"type":225,"tag":226,"props":249,"children":250},{},[251],{"type":225,"tag":252,"props":253,"children":259},"img",{"alt":254,"className":255,"src":258},"A collection of office supplies laid out on a table.",[256,257],"rounded-lg","mx-auto","/posts/images/automate_developer_machine_tool.jpg",[],{"type":225,"tag":226,"props":261,"children":262},{},[263],{"type":230,"value":264},"A lot of people have solved this issue by scripting their developer environment setup, and I decided it was time for me to do the same. And believe me, it was not for the beauty of having everything automatically installed but to stop wasting my time each time I change or reinstall my laptop.",{"type":225,"tag":226,"props":266,"children":267},{},[268,270,279,281,288],{"type":230,"value":269},"Please note that what I did to setup my developer machine was inspired by the ",{"type":225,"tag":271,"props":272,"children":276},"a",{"href":273,"rel":274},"https://github.com/Microsoft/windows-dev-box-setup-scripts",[275],"nofollow",[277],{"type":230,"value":278},"Windows Dev Box setup scripts",{"type":230,"value":280}," GitHub repository and other repositories using boxstarter (check ",{"type":225,"tag":271,"props":282,"children":285},{"href":283,"rel":284},"https://github.com/laurentkempe/Cacao",[275],[286],{"type":230,"value":287},"Laurent Kempé's repository",{"type":230,"value":289}," for instance) to install their Windows environment.",{"type":225,"tag":232,"props":291,"children":293},{"id":292},"how-does-it-work",[294],{"type":230,"value":295},"How does it work?",{"type":225,"tag":226,"props":297,"children":298},{},[299],{"type":230,"value":300},"There are many ways to automate the setup of a developer machine. Before choosing one, I had a few requirements/preferences:",{"type":225,"tag":302,"props":303,"children":304},"ul",{},[305,311,316,321],{"type":225,"tag":306,"props":307,"children":308},"li",{},[309],{"type":230,"value":310},"installation of my machine should be simple to script and run",{"type":225,"tag":306,"props":312,"children":313},{},[314],{"type":230,"value":315},"no need to pre-install some software before launching the installation of my environment",{"type":225,"tag":306,"props":317,"children":318},{},[319],{"type":230,"value":320},"avoid manual steps or user interaction during the installation",{"type":225,"tag":306,"props":322,"children":323},{},[324],{"type":230,"value":325},"be able easily to share some software configurations between laptops",{"type":225,"tag":226,"props":327,"children":328},{},[329,331,338,340,347,349,356],{"type":230,"value":330},"Because of these requirements, I chose to use ",{"type":225,"tag":271,"props":332,"children":335},{"href":333,"rel":334},"https://boxstarter.org/",[275],[336],{"type":230,"value":337},"Boxstarter",{"type":230,"value":339},". It has several interesting features (check the ",{"type":225,"tag":271,"props":341,"children":344},{"href":342,"rel":343},"https://boxstarter.org/whyboxstarter",[275],[345],{"type":230,"value":346},"website",{"type":230,"value":348},") but the one I like the most is you can launch your installation process directly by ",{"type":225,"tag":271,"props":350,"children":353},{"href":351,"rel":352},"https://boxstarter.org/weblauncher",[275],[354],{"type":230,"value":355},"clicking on a link",{"type":230,"value":357},". You just need an URL like this one:",{"type":225,"tag":359,"props":360,"children":364},"pre",{"className":361,"code":362,"language":363,"meta":207,"style":207},"language-http shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","https://boxstarter.org/package/nr/url?{urlToYourInstallationScript}\n","http",[365],{"type":225,"tag":366,"props":367,"children":368},"code",{"__ignoreMap":207},[369],{"type":225,"tag":370,"props":371,"children":374},"span",{"class":372,"line":373},"line",1,[375],{"type":225,"tag":370,"props":376,"children":378},{"style":377},"--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8",[379],{"type":230,"value":362},{"type":225,"tag":226,"props":381,"children":382},{},[383,385,391,393,400,402,408],{"type":230,"value":384},"The ",{"type":225,"tag":366,"props":386,"children":388},{"className":387},[],[389],{"type":230,"value":390},"{urlToYourInstallationScript}",{"type":230,"value":392}," part is the URL where is stored your installation script. I put mine in a ",{"type":225,"tag":271,"props":394,"children":397},{"href":395,"rel":396},"https://github.com/TechWatching/dotfiles/blob/main/boxstarter.ps1",[275],[398],{"type":230,"value":399},"public GitHub repository",{"type":230,"value":401}," called ",{"type":225,"tag":366,"props":403,"children":405},{"className":404},[],[406],{"type":230,"value":407},"dotfiles",{"type":230,"value":409},".",{"type":225,"tag":226,"props":411,"children":412},{},[413],{"type":225,"tag":252,"props":414,"children":418},{"alt":415,"className":416,"src":417},"Boxstarter website.",[256,257],"/posts/images/automate_developer_machine_boxstarter.png",[],{"type":225,"tag":420,"props":421,"children":423},"callout",{"icon":422},"i-heroicons-chat-bubble-left-20-solid",[424],{"type":225,"tag":226,"props":425,"children":426},{},[427],{"type":230,"value":428},"Boxstarter was a nice discovery, I barely scratched the surface but it can do interesting things like remote installations.",{"type":225,"tag":226,"props":430,"children":431},{},[432,434,440,442,447],{"type":230,"value":433},"In this repository, I also put different scripts (to separate the different steps instead of having one big installation script file), some config files I wanted to use in my setup (my ",{"type":225,"tag":366,"props":435,"children":437},{"className":436},[],[438],{"type":230,"value":439},".gitconfig",{"type":230,"value":441}," file for instance), and a readme with some explanations and the link to launch the installation. I did not reinvent the wheel as it's more or less how the ",{"type":225,"tag":271,"props":443,"children":445},{"href":273,"rel":444},[275],[446],{"type":230,"value":278},{"type":230,"value":448}," work.",{"type":225,"tag":226,"props":450,"children":451},{},[452],{"type":230,"value":453},"Because I wanted to share some software configurations between laptops (or between installations), using a GitHub repository is interesting. The first thing my setup script does is to install Git, then it clones this repository to have access to the other scripts and configuration files.",{"type":225,"tag":359,"props":455,"children":459},{"className":456,"code":457,"language":458,"meta":207,"style":207},"language-powershell shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","# Install git and clone repository containing scripts and config files\nchoco install -y git --params \"/GitOnlyOnPath /NoShellIntegration /WindowsTerminal\"\nRefreshEnv\ngit clone https://github.com/TechWatching/dotfiles.git \"$env:USERPROFILE\\dotfiles\"\n","powershell",[460],{"type":225,"tag":366,"props":461,"children":462},{"__ignoreMap":207},[463,472,518,527],{"type":225,"tag":370,"props":464,"children":465},{"class":372,"line":373},[466],{"type":225,"tag":370,"props":467,"children":469},{"style":468},"--shiki-light:#90A4AE;--shiki-default:#546E7A;--shiki-dark:#676E95;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[470],{"type":230,"value":471},"# Install git and clone repository containing scripts and config files\n",{"type":225,"tag":370,"props":473,"children":475},{"class":372,"line":474},2,[476,481,487,492,497,502,507,513],{"type":225,"tag":370,"props":477,"children":478},{"style":377},[479],{"type":230,"value":480},"choco install ",{"type":225,"tag":370,"props":482,"children":484},{"style":483},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF",[485],{"type":230,"value":486},"-",{"type":225,"tag":370,"props":488,"children":489},{"style":377},[490],{"type":230,"value":491},"y git ",{"type":225,"tag":370,"props":493,"children":494},{"style":483},[495],{"type":230,"value":496},"--",{"type":225,"tag":370,"props":498,"children":499},{"style":377},[500],{"type":230,"value":501},"params ",{"type":225,"tag":370,"props":503,"children":504},{"style":483},[505],{"type":230,"value":506},"\"",{"type":225,"tag":370,"props":508,"children":510},{"style":509},"--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D",[511],{"type":230,"value":512},"/GitOnlyOnPath /NoShellIntegration /WindowsTerminal",{"type":225,"tag":370,"props":514,"children":515},{"style":483},[516],{"type":230,"value":517},"\"\n",{"type":225,"tag":370,"props":519,"children":521},{"class":372,"line":520},3,[522],{"type":225,"tag":370,"props":523,"children":524},{"style":377},[525],{"type":230,"value":526},"RefreshEnv\n",{"type":225,"tag":370,"props":528,"children":530},{"class":372,"line":529},4,[531,536,541,547,552,557,561,566,571,576,581],{"type":225,"tag":370,"props":532,"children":533},{"style":377},[534],{"type":230,"value":535},"git clone https:",{"type":225,"tag":370,"props":537,"children":538},{"style":483},[539],{"type":230,"value":540},"//",{"type":225,"tag":370,"props":542,"children":544},{"style":543},"--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF",[545],{"type":230,"value":546},"github.com",{"type":225,"tag":370,"props":548,"children":549},{"style":483},[550],{"type":230,"value":551},"/",{"type":225,"tag":370,"props":553,"children":554},{"style":377},[555],{"type":230,"value":556},"TechWatching",{"type":225,"tag":370,"props":558,"children":559},{"style":483},[560],{"type":230,"value":551},{"type":225,"tag":370,"props":562,"children":563},{"style":377},[564],{"type":230,"value":565},"dotfiles.git ",{"type":225,"tag":370,"props":567,"children":568},{"style":483},[569],{"type":230,"value":570},"\"$",{"type":225,"tag":370,"props":572,"children":573},{"style":377},[574],{"type":230,"value":575},"env:USERPROFILE",{"type":225,"tag":370,"props":577,"children":578},{"style":509},[579],{"type":230,"value":580},"\\dotfiles",{"type":225,"tag":370,"props":582,"children":583},{"style":483},[584],{"type":230,"value":517},{"type":225,"tag":226,"props":586,"children":587},{},[588,590,596],{"type":230,"value":589},"The scripts are written in ",{"type":225,"tag":271,"props":591,"children":594},{"href":592,"rel":593},"https://docs.microsoft.com/en-us/powershell/",[275],[595],{"type":230,"value":217},{"type":230,"value":409},{"type":225,"tag":232,"props":598,"children":600},{"id":599},"installing-software",[601],{"type":230,"value":602},"Installing software",{"type":225,"tag":604,"props":605,"children":607},"h3",{"id":606},"package-managers",[608],{"type":230,"value":609},"Package managers",{"type":225,"tag":226,"props":611,"children":612},{},[613,615,622,624,631],{"type":230,"value":614},"The easiest way to automate installing, upgrading, and configuring software is to use package managers. There are several available on Windows but I chose to use ",{"type":225,"tag":271,"props":616,"children":619},{"href":617,"rel":618},"https://docs.microsoft.com/en-us/windows/package-manager/",[275],[620],{"type":230,"value":621},"Windows Package Manager",{"type":230,"value":623}," and ",{"type":225,"tag":271,"props":625,"children":628},{"href":626,"rel":627},"https://chocolatey.org/",[275],[629],{"type":230,"value":630},"Chocolatey",{"type":230,"value":409},{"type":225,"tag":226,"props":633,"children":634},{},[635],{"type":230,"value":636},"Windows Package Manager (aka winget) is relatively new so has fewer features and packages available than other package managers like Chocolatey. However it's very promising, it's getting better every day, it's built-in Windows, and above all, it supports installing Microsoft Store apps. So I chose to use winget by default and fallback to Chocolatey when a package I needed was not available or not up-to-date in winget.",{"type":225,"tag":420,"props":638,"children":639},{"icon":422},[640],{"type":225,"tag":226,"props":641,"children":642},{},[643,645,652],{"type":230,"value":644},"I learned a few things about winget while starting to use it. You can find my articles talking about it ",{"type":225,"tag":271,"props":646,"children":649},{"href":647,"rel":648},"https://www.techwatching.dev/tags/winget/",[275],[650],{"type":230,"value":651},"here",{"type":230,"value":653}," if you are interested.",{"type":225,"tag":604,"props":655,"children":657},{"id":656},"installing-integrated-development-environments-ides",[658],{"type":230,"value":659},"Installing Integrated Development Environments (IDEs)",{"type":225,"tag":226,"props":661,"children":662},{},[663],{"type":230,"value":664},"Visual Studio has been my main IDE for a while, but I have been started recently to use more and more Rider as well. Both are nice IDEs with many features particularly well suited for .NET development which is what I mostly do. I have been a Visual Studio Code long-time user too, mostly using it as a text editor or for front development. I also use vscode to work with Azure because it has nice extensions for a lot of Azure services.",{"type":225,"tag":226,"props":666,"children":667},{},[668],{"type":225,"tag":252,"props":669,"children":673},{"alt":670,"className":671,"src":672},"Visual Studio logo.",[256,257],"/posts/images/automate_developer_machine_visualstudio.jpg",[],{"type":225,"tag":226,"props":675,"children":676},{},[677],{"type":230,"value":678},"You probably want to customize your Visual Studio installation to only include the workloads, components, and language packs you are using. You can specify them as parameters in the winget or chocolatey install command but that's a bit cumbersome. The easiest way is to export your configuration from the Visual Studio installer.",{"type":225,"tag":226,"props":680,"children":681},{},[682],{"type":230,"value":683},"You can then install Visual Studio with this kind of command:",{"type":225,"tag":359,"props":685,"children":687},{"className":456,"code":686,"language":458,"meta":207,"style":207},"winget install -e -h --id Microsoft.VisualStudio.2022.Enterprise --silent --override \"--wait --quiet --addProductLang En-us --config .vsconfig\"\n",[688],{"type":225,"tag":366,"props":689,"children":690},{"__ignoreMap":207},[691],{"type":225,"tag":370,"props":692,"children":693},{"class":372,"line":373},[694,699,703,708,712,717,721,726,732,737,741,746,750,755,759,764],{"type":225,"tag":370,"props":695,"children":696},{"style":377},[697],{"type":230,"value":698},"winget install ",{"type":225,"tag":370,"props":700,"children":701},{"style":483},[702],{"type":230,"value":486},{"type":225,"tag":370,"props":704,"children":705},{"style":377},[706],{"type":230,"value":707},"e ",{"type":225,"tag":370,"props":709,"children":710},{"style":483},[711],{"type":230,"value":486},{"type":225,"tag":370,"props":713,"children":714},{"style":377},[715],{"type":230,"value":716},"h ",{"type":225,"tag":370,"props":718,"children":719},{"style":483},[720],{"type":230,"value":496},{"type":225,"tag":370,"props":722,"children":723},{"style":377},[724],{"type":230,"value":725},"id Microsoft.VisualStudio.",{"type":225,"tag":370,"props":727,"children":729},{"style":728},"--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C",[730],{"type":230,"value":731},"2022.",{"type":225,"tag":370,"props":733,"children":734},{"style":377},[735],{"type":230,"value":736},"Enterprise ",{"type":225,"tag":370,"props":738,"children":739},{"style":483},[740],{"type":230,"value":496},{"type":225,"tag":370,"props":742,"children":743},{"style":377},[744],{"type":230,"value":745},"silent ",{"type":225,"tag":370,"props":747,"children":748},{"style":483},[749],{"type":230,"value":496},{"type":225,"tag":370,"props":751,"children":752},{"style":377},[753],{"type":230,"value":754},"override ",{"type":225,"tag":370,"props":756,"children":757},{"style":483},[758],{"type":230,"value":506},{"type":225,"tag":370,"props":760,"children":761},{"style":509},[762],{"type":230,"value":763},"--wait --quiet --addProductLang En-us --config .vsconfig",{"type":225,"tag":370,"props":765,"children":766},{"style":483},[767],{"type":230,"value":517},{"type":225,"tag":420,"props":769,"children":770},{"icon":422},[771],{"type":225,"tag":226,"props":772,"children":773},{},[774],{"type":230,"value":775},"I did not know before trying to automate Visual Studio installation that you could specify parameters to its installer on the command line but that's very useful.",{"type":225,"tag":226,"props":777,"children":778},{},[779],{"type":230,"value":780},"I don't export Visual Studio settings or extensions as most of them can be synchronized through the personalization account (you just have to sign in to Visual Studio with the same account).",{"type":225,"tag":226,"props":782,"children":783},{},[784,786,793],{"type":230,"value":785},"In a similar way, I use ",{"type":225,"tag":271,"props":787,"children":790},{"href":788,"rel":789},"https://code.visualstudio.com/docs/editor/settings-sync",[275],[791],{"type":230,"value":792},"vscode built-in settings synchronization",{"type":230,"value":794}," to share my setup (extensions, settings, keybindings) across machines so I don't have to do a custom installation.",{"type":225,"tag":226,"props":796,"children":797},{},[798,800,807],{"type":230,"value":799},"There is a Rider package available on chocolatey but it is not always up-to-date and I prefer to use the JetBrains ToolBox application to manage the installation and update of my JetBrains tools. Unfortunately, JetBrains ToolBox does not currently have a CLI to automate the installation of Rider and other useful .NET tools (there is an ",{"type":225,"tag":271,"props":801,"children":804},{"href":802,"rel":803},"https://youtrack.jetbrains.com/issue/TBX-653/toolbox-cli",[275],[805],{"type":230,"value":806},"issue",{"type":230,"value":808}," opened though if you want to vote) so I only automated the installation of JetBrains ToolBox and will have to install it Rider manually from it.",{"type":225,"tag":604,"props":810,"children":812},{"id":811},"tools-i-need",[813],{"type":230,"value":814},"Tools I need",{"type":225,"tag":226,"props":816,"children":817},{},[818,820,827,829,836],{"type":230,"value":819},"Of course, git is a must-have. I use ",{"type":225,"tag":271,"props":821,"children":824},{"href":822,"rel":823},"https://github.com/coreybutler/nvm-windows",[275],[825],{"type":230,"value":826},"NVM for windows",{"type":230,"value":828}," to manage multiple installations of node.js on my laptop, and ",{"type":225,"tag":271,"props":830,"children":833},{"href":831,"rel":832},"https://pnpm.io/",[275],[834],{"type":230,"value":835},"pnpm",{"type":230,"value":837}," is my preferred package manager for Node.js.",{"type":225,"tag":226,"props":839,"children":840},{},[841,843,849,850,857,859,866,868,875],{"type":230,"value":842},"There are 2 shells I like to use (both of them are cross-platform): ",{"type":225,"tag":271,"props":844,"children":847},{"href":845,"rel":846},"https://docs.microsoft.com/en-us/powershell/scripting/overview",[275],[848],{"type":230,"value":217},{"type":230,"value":623},{"type":225,"tag":271,"props":851,"children":854},{"href":852,"rel":853},"https://www.nushell.sh/",[275],[855],{"type":230,"value":856},"Nushell",{"type":230,"value":858},". I use ",{"type":225,"tag":271,"props":860,"children":863},{"href":861,"rel":862},"https://ohmyposh.dev/",[275],[864],{"type":230,"value":865},"Oh My Posh",{"type":230,"value":867}," to configure an enhanced prompt for both shells. ",{"type":225,"tag":271,"props":869,"children":872},{"href":870,"rel":871},"https://docs.microsoft.com/en-us/windows/terminal/",[275],[873],{"type":230,"value":874},"Windows Terminal",{"type":230,"value":876}," is my go-to terminal.",{"type":225,"tag":226,"props":878,"children":879},{},[880],{"type":230,"value":881},"As I work mainly on cloud projects, there are some Azure tools I need on my laptop:",{"type":225,"tag":359,"props":883,"children":885},{"className":456,"code":884,"language":458,"meta":207,"style":207},"winget install -e -h --id Microsoft.AzureCLI\nwinget install -e -h --id Microsoft.AzureCosmosEmulator\nwinget install -e -h --id Microsoft.AzureDataStudio\nwinget install -e -h --id Microsoft.azure-iot-explorer\nwinget install -e -h --id Microsoft.AzureStorageExplorer\nwinget install -e -h --id Pulumi.Pulumi\nwinget install -e -h --id Microsoft.AzureFunctionsCoreTools\n# Azurite can be installed through vscode extension or as a global npm package\n# pnpm add -g azurite\n",[886],{"type":225,"tag":366,"props":887,"children":888},{"__ignoreMap":207},[889,921,953,985,1035,1068,1101,1134,1143],{"type":225,"tag":370,"props":890,"children":891},{"class":372,"line":373},[892,896,900,904,908,912,916],{"type":225,"tag":370,"props":893,"children":894},{"style":377},[895],{"type":230,"value":698},{"type":225,"tag":370,"props":897,"children":898},{"style":483},[899],{"type":230,"value":486},{"type":225,"tag":370,"props":901,"children":902},{"style":377},[903],{"type":230,"value":707},{"type":225,"tag":370,"props":905,"children":906},{"style":483},[907],{"type":230,"value":486},{"type":225,"tag":370,"props":909,"children":910},{"style":377},[911],{"type":230,"value":716},{"type":225,"tag":370,"props":913,"children":914},{"style":483},[915],{"type":230,"value":496},{"type":225,"tag":370,"props":917,"children":918},{"style":377},[919],{"type":230,"value":920},"id Microsoft.AzureCLI\n",{"type":225,"tag":370,"props":922,"children":923},{"class":372,"line":474},[924,928,932,936,940,944,948],{"type":225,"tag":370,"props":925,"children":926},{"style":377},[927],{"type":230,"value":698},{"type":225,"tag":370,"props":929,"children":930},{"style":483},[931],{"type":230,"value":486},{"type":225,"tag":370,"props":933,"children":934},{"style":377},[935],{"type":230,"value":707},{"type":225,"tag":370,"props":937,"children":938},{"style":483},[939],{"type":230,"value":486},{"type":225,"tag":370,"props":941,"children":942},{"style":377},[943],{"type":230,"value":716},{"type":225,"tag":370,"props":945,"children":946},{"style":483},[947],{"type":230,"value":496},{"type":225,"tag":370,"props":949,"children":950},{"style":377},[951],{"type":230,"value":952},"id Microsoft.AzureCosmosEmulator\n",{"type":225,"tag":370,"props":954,"children":955},{"class":372,"line":520},[956,960,964,968,972,976,980],{"type":225,"tag":370,"props":957,"children":958},{"style":377},[959],{"type":230,"value":698},{"type":225,"tag":370,"props":961,"children":962},{"style":483},[963],{"type":230,"value":486},{"type":225,"tag":370,"props":965,"children":966},{"style":377},[967],{"type":230,"value":707},{"type":225,"tag":370,"props":969,"children":970},{"style":483},[971],{"type":230,"value":486},{"type":225,"tag":370,"props":973,"children":974},{"style":377},[975],{"type":230,"value":716},{"type":225,"tag":370,"props":977,"children":978},{"style":483},[979],{"type":230,"value":496},{"type":225,"tag":370,"props":981,"children":982},{"style":377},[983],{"type":230,"value":984},"id Microsoft.AzureDataStudio\n",{"type":225,"tag":370,"props":986,"children":987},{"class":372,"line":529},[988,992,996,1000,1004,1008,1012,1017,1021,1026,1030],{"type":225,"tag":370,"props":989,"children":990},{"style":377},[991],{"type":230,"value":698},{"type":225,"tag":370,"props":993,"children":994},{"style":483},[995],{"type":230,"value":486},{"type":225,"tag":370,"props":997,"children":998},{"style":377},[999],{"type":230,"value":707},{"type":225,"tag":370,"props":1001,"children":1002},{"style":483},[1003],{"type":230,"value":486},{"type":225,"tag":370,"props":1005,"children":1006},{"style":377},[1007],{"type":230,"value":716},{"type":225,"tag":370,"props":1009,"children":1010},{"style":483},[1011],{"type":230,"value":496},{"type":225,"tag":370,"props":1013,"children":1014},{"style":377},[1015],{"type":230,"value":1016},"id Microsoft.azure",{"type":225,"tag":370,"props":1018,"children":1019},{"style":483},[1020],{"type":230,"value":486},{"type":225,"tag":370,"props":1022,"children":1023},{"style":377},[1024],{"type":230,"value":1025},"iot",{"type":225,"tag":370,"props":1027,"children":1028},{"style":483},[1029],{"type":230,"value":486},{"type":225,"tag":370,"props":1031,"children":1032},{"style":377},[1033],{"type":230,"value":1034},"explorer\n",{"type":225,"tag":370,"props":1036,"children":1038},{"class":372,"line":1037},5,[1039,1043,1047,1051,1055,1059,1063],{"type":225,"tag":370,"props":1040,"children":1041},{"style":377},[1042],{"type":230,"value":698},{"type":225,"tag":370,"props":1044,"children":1045},{"style":483},[1046],{"type":230,"value":486},{"type":225,"tag":370,"props":1048,"children":1049},{"style":377},[1050],{"type":230,"value":707},{"type":225,"tag":370,"props":1052,"children":1053},{"style":483},[1054],{"type":230,"value":486},{"type":225,"tag":370,"props":1056,"children":1057},{"style":377},[1058],{"type":230,"value":716},{"type":225,"tag":370,"props":1060,"children":1061},{"style":483},[1062],{"type":230,"value":496},{"type":225,"tag":370,"props":1064,"children":1065},{"style":377},[1066],{"type":230,"value":1067},"id Microsoft.AzureStorageExplorer\n",{"type":225,"tag":370,"props":1069,"children":1071},{"class":372,"line":1070},6,[1072,1076,1080,1084,1088,1092,1096],{"type":225,"tag":370,"props":1073,"children":1074},{"style":377},[1075],{"type":230,"value":698},{"type":225,"tag":370,"props":1077,"children":1078},{"style":483},[1079],{"type":230,"value":486},{"type":225,"tag":370,"props":1081,"children":1082},{"style":377},[1083],{"type":230,"value":707},{"type":225,"tag":370,"props":1085,"children":1086},{"style":483},[1087],{"type":230,"value":486},{"type":225,"tag":370,"props":1089,"children":1090},{"style":377},[1091],{"type":230,"value":716},{"type":225,"tag":370,"props":1093,"children":1094},{"style":483},[1095],{"type":230,"value":496},{"type":225,"tag":370,"props":1097,"children":1098},{"style":377},[1099],{"type":230,"value":1100},"id Pulumi.Pulumi\n",{"type":225,"tag":370,"props":1102,"children":1104},{"class":372,"line":1103},7,[1105,1109,1113,1117,1121,1125,1129],{"type":225,"tag":370,"props":1106,"children":1107},{"style":377},[1108],{"type":230,"value":698},{"type":225,"tag":370,"props":1110,"children":1111},{"style":483},[1112],{"type":230,"value":486},{"type":225,"tag":370,"props":1114,"children":1115},{"style":377},[1116],{"type":230,"value":707},{"type":225,"tag":370,"props":1118,"children":1119},{"style":483},[1120],{"type":230,"value":486},{"type":225,"tag":370,"props":1122,"children":1123},{"style":377},[1124],{"type":230,"value":716},{"type":225,"tag":370,"props":1126,"children":1127},{"style":483},[1128],{"type":230,"value":496},{"type":225,"tag":370,"props":1130,"children":1131},{"style":377},[1132],{"type":230,"value":1133},"id Microsoft.AzureFunctionsCoreTools\n",{"type":225,"tag":370,"props":1135,"children":1137},{"class":372,"line":1136},8,[1138],{"type":225,"tag":370,"props":1139,"children":1140},{"style":468},[1141],{"type":230,"value":1142},"# Azurite can be installed through vscode extension or as a global npm package\n",{"type":225,"tag":370,"props":1144,"children":1146},{"class":372,"line":1145},9,[1147],{"type":225,"tag":370,"props":1148,"children":1149},{"style":468},[1150],{"type":230,"value":1151},"# pnpm add -g azurite\n",{"type":225,"tag":226,"props":1153,"children":1154},{},[1155,1157,1164,1166,1173],{"type":230,"value":1156},"My script also automates the installation of other tools, not related to software development but that I often use (like ",{"type":225,"tag":271,"props":1158,"children":1161},{"href":1159,"rel":1160},"https://www.7-zip.org/",[275],[1162],{"type":230,"value":1163},"7zip",{"type":230,"value":1165},", ",{"type":225,"tag":271,"props":1167,"children":1170},{"href":1168,"rel":1169},"https://docs.microsoft.com/en-us/windows/powertoys/",[275],[1171],{"type":230,"value":1172},"Microsoft Power Toys",{"type":230,"value":1174}," or just browsers).",{"type":225,"tag":226,"props":1176,"children":1177},{},[1178],{"type":230,"value":1179},"Generally, when the applications I want to install are available in the Microsoft Store, I specify winget to install them from there.",{"type":225,"tag":359,"props":1181,"children":1183},{"className":456,"code":1182,"language":458,"meta":207,"style":207},"winget install -e -h --id Microsoft.WindowsTerminal -s msstore\n",[1184],{"type":225,"tag":366,"props":1185,"children":1186},{"__ignoreMap":207},[1187],{"type":225,"tag":370,"props":1188,"children":1189},{"class":372,"line":373},[1190,1194,1198,1202,1206,1210,1214,1219,1223],{"type":225,"tag":370,"props":1191,"children":1192},{"style":377},[1193],{"type":230,"value":698},{"type":225,"tag":370,"props":1195,"children":1196},{"style":483},[1197],{"type":230,"value":486},{"type":225,"tag":370,"props":1199,"children":1200},{"style":377},[1201],{"type":230,"value":707},{"type":225,"tag":370,"props":1203,"children":1204},{"style":483},[1205],{"type":230,"value":486},{"type":225,"tag":370,"props":1207,"children":1208},{"style":377},[1209],{"type":230,"value":716},{"type":225,"tag":370,"props":1211,"children":1212},{"style":483},[1213],{"type":230,"value":496},{"type":225,"tag":370,"props":1215,"children":1216},{"style":377},[1217],{"type":230,"value":1218},"id Microsoft.WindowsTerminal ",{"type":225,"tag":370,"props":1220,"children":1221},{"style":483},[1222],{"type":230,"value":486},{"type":225,"tag":370,"props":1224,"children":1225},{"style":377},[1226],{"type":230,"value":1227},"s msstore\n",{"type":225,"tag":420,"props":1229,"children":1230},{"icon":422},[1231],{"type":225,"tag":226,"props":1232,"children":1233},{},[1234],{"type":230,"value":1235},"Automating the installation of my developer machine was the opportunity to realize all the tools I was using daily, and which ones were really useful.",{"type":225,"tag":604,"props":1237,"children":1239},{"id":1238},"tools-i-dont-need",[1240],{"type":230,"value":1241},"Tools I don't need",{"type":225,"tag":226,"props":1243,"children":1244},{},[1245],{"type":230,"value":1246},"Unnecessary applications that come with Windows out of the box are uninstalled using this function:",{"type":225,"tag":359,"props":1248,"children":1250},{"className":456,"code":1249,"language":458,"meta":207,"style":207},"function removeApp {\n    Param ([string]$appName)\n    Write-Output \"Trying to remove $appName\"\n    Get-AppxPackage $appName -AllUsers | Remove-AppxPackage\n    Get-AppXProvisionedPackage -Online | Where DisplayName -like $appName | Remove-AppxProvisionedPackage -Online\n",[1251],{"type":225,"tag":366,"props":1252,"children":1253},{"__ignoreMap":207},[1254,1273,1307,1338,1375],{"type":225,"tag":370,"props":1255,"children":1256},{"class":372,"line":373},[1257,1263,1268],{"type":225,"tag":370,"props":1258,"children":1260},{"style":1259},"--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA",[1261],{"type":230,"value":1262},"function",{"type":225,"tag":370,"props":1264,"children":1265},{"style":543},[1266],{"type":230,"value":1267}," removeApp",{"type":225,"tag":370,"props":1269,"children":1270},{"style":483},[1271],{"type":230,"value":1272}," {\n",{"type":225,"tag":370,"props":1274,"children":1275},{"class":372,"line":474},[1276,1282,1287,1292,1297,1302],{"type":225,"tag":370,"props":1277,"children":1279},{"style":1278},"--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF;--shiki-light-font-style:italic;--shiki-default-font-style:italic;--shiki-dark-font-style:italic",[1280],{"type":230,"value":1281},"    Param",{"type":225,"tag":370,"props":1283,"children":1284},{"style":483},[1285],{"type":230,"value":1286}," ([",{"type":225,"tag":370,"props":1288,"children":1289},{"style":1259},[1290],{"type":230,"value":1291},"string",{"type":225,"tag":370,"props":1293,"children":1294},{"style":483},[1295],{"type":230,"value":1296},"]$",{"type":225,"tag":370,"props":1298,"children":1299},{"style":377},[1300],{"type":230,"value":1301},"appName",{"type":225,"tag":370,"props":1303,"children":1304},{"style":483},[1305],{"type":230,"value":1306},")\n",{"type":225,"tag":370,"props":1308,"children":1309},{"class":372,"line":520},[1310,1315,1320,1325,1330,1334],{"type":225,"tag":370,"props":1311,"children":1312},{"style":543},[1313],{"type":230,"value":1314},"    Write-Output",{"type":225,"tag":370,"props":1316,"children":1317},{"style":483},[1318],{"type":230,"value":1319}," \"",{"type":225,"tag":370,"props":1321,"children":1322},{"style":509},[1323],{"type":230,"value":1324},"Trying to remove ",{"type":225,"tag":370,"props":1326,"children":1327},{"style":483},[1328],{"type":230,"value":1329},"$",{"type":225,"tag":370,"props":1331,"children":1332},{"style":377},[1333],{"type":230,"value":1301},{"type":225,"tag":370,"props":1335,"children":1336},{"style":483},[1337],{"type":230,"value":517},{"type":225,"tag":370,"props":1339,"children":1340},{"class":372,"line":529},[1341,1346,1351,1356,1360,1365,1370],{"type":225,"tag":370,"props":1342,"children":1343},{"style":543},[1344],{"type":230,"value":1345},"    Get-AppxPackage",{"type":225,"tag":370,"props":1347,"children":1348},{"style":483},[1349],{"type":230,"value":1350}," $",{"type":225,"tag":370,"props":1352,"children":1353},{"style":377},[1354],{"type":230,"value":1355},"appName ",{"type":225,"tag":370,"props":1357,"children":1358},{"style":483},[1359],{"type":230,"value":486},{"type":225,"tag":370,"props":1361,"children":1362},{"style":377},[1363],{"type":230,"value":1364},"AllUsers ",{"type":225,"tag":370,"props":1366,"children":1367},{"style":483},[1368],{"type":230,"value":1369},"|",{"type":225,"tag":370,"props":1371,"children":1372},{"style":543},[1373],{"type":230,"value":1374}," Remove-AppxPackage\n",{"type":225,"tag":370,"props":1376,"children":1377},{"class":372,"line":1037},[1378,1383,1388,1393,1397,1402,1407,1412,1416,1420,1424,1429,1433],{"type":225,"tag":370,"props":1379,"children":1380},{"style":543},[1381],{"type":230,"value":1382},"    Get-AppXProvisionedPackage",{"type":225,"tag":370,"props":1384,"children":1385},{"style":483},[1386],{"type":230,"value":1387}," -",{"type":225,"tag":370,"props":1389,"children":1390},{"style":377},[1391],{"type":230,"value":1392},"Online ",{"type":225,"tag":370,"props":1394,"children":1395},{"style":483},[1396],{"type":230,"value":1369},{"type":225,"tag":370,"props":1398,"children":1399},{"style":1278},[1400],{"type":230,"value":1401}," Where",{"type":225,"tag":370,"props":1403,"children":1404},{"style":377},[1405],{"type":230,"value":1406}," DisplayName ",{"type":225,"tag":370,"props":1408,"children":1409},{"style":483},[1410],{"type":230,"value":1411},"-like",{"type":225,"tag":370,"props":1413,"children":1414},{"style":483},[1415],{"type":230,"value":1350},{"type":225,"tag":370,"props":1417,"children":1418},{"style":377},[1419],{"type":230,"value":1355},{"type":225,"tag":370,"props":1421,"children":1422},{"style":483},[1423],{"type":230,"value":1369},{"type":225,"tag":370,"props":1425,"children":1426},{"style":543},[1427],{"type":230,"value":1428}," Remove-AppxProvisionedPackage",{"type":225,"tag":370,"props":1430,"children":1431},{"style":483},[1432],{"type":230,"value":1387},{"type":225,"tag":370,"props":1434,"children":1435},{"style":377},[1436],{"type":230,"value":1437},"Online\n",{"type":225,"tag":226,"props":1439,"children":1440},{},[1441,1443,1449,1451,1457],{"type":230,"value":1442},"It allows me to get rid of pre-installed applications like ",{"type":225,"tag":366,"props":1444,"children":1446},{"className":1445},[],[1447],{"type":230,"value":1448},"Facebook",{"type":230,"value":1450},"or ",{"type":225,"tag":366,"props":1452,"children":1454},{"className":1453},[],[1455],{"type":230,"value":1456},"Bing News",{"type":230,"value":409},{"type":225,"tag":232,"props":1459,"children":1461},{"id":1460},"configuring-software",[1462],{"type":230,"value":1463},"Configuring software",{"type":225,"tag":226,"props":1465,"children":1466},{},[1467],{"type":230,"value":1468},"Installing software is one part, but configuring it is another. As I previously mentioned, for some applications in which you sign in with an account, settings are synchronized so you don't need to transfer the application settings from your previous laptop. For the others, I decided to use symbolic links.",{"type":225,"tag":226,"props":1470,"children":1471},{},[1472],{"type":225,"tag":252,"props":1473,"children":1477},{"alt":1474,"className":1475,"src":1476},"A light bulb that is turned on.",[256,257],"/posts/images/automate_developer_machine_idea.jpg",[],{"type":225,"tag":226,"props":1479,"children":1480},{},[1481],{"type":230,"value":1482},"Here are some examples of settings I wanted to set up on a new laptop:",{"type":225,"tag":302,"props":1484,"children":1485},{},[1486,1498,1509,1520],{"type":225,"tag":306,"props":1487,"children":1488},{},[1489,1491],{"type":230,"value":1490},"my ",{"type":225,"tag":271,"props":1492,"children":1495},{"href":1493,"rel":1494},"https://github.com/TechWatching/dotfiles/blob/main/config/git/.gitconfig",[275],[1496],{"type":230,"value":1497},".gitconfig file",{"type":225,"tag":306,"props":1499,"children":1500},{},[1501,1502],{"type":230,"value":1490},{"type":225,"tag":271,"props":1503,"children":1506},{"href":1504,"rel":1505},"https://github.com/TechWatching/dotfiles/blob/main/config/windowsTerminal/settings.json",[275],[1507],{"type":230,"value":1508},"Windows Terminal settings",{"type":225,"tag":306,"props":1510,"children":1511},{},[1512,1513],{"type":230,"value":1490},{"type":225,"tag":271,"props":1514,"children":1517},{"href":1515,"rel":1516},"https://github.com/TechWatching/dotfiles/blob/main/config/powershell/Microsoft.PowerShell_profile.ps1",[275],[1518],{"type":230,"value":1519},"PowerShell profile",{"type":225,"tag":306,"props":1521,"children":1522},{},[1523,1524,1531],{"type":230,"value":1490},{"type":225,"tag":271,"props":1525,"children":1528},{"href":1526,"rel":1527},"https://github.com/TechWatching/dotfiles/blob/main/config/prompt/.oh-my-posh.omp.json",[275],[1529],{"type":230,"value":1530},"custom prompt configuration",{"type":230,"value":1532}," done using oh my posh",{"type":225,"tag":226,"props":1534,"children":1535},{},[1536,1538,1543],{"type":230,"value":1537},"To create a symbolic link at the Windows Terminal settings file pointing to the settings file in my ",{"type":225,"tag":366,"props":1539,"children":1541},{"className":1540},[],[1542],{"type":230,"value":407},{"type":230,"value":1544}," cloned repository I can do the following command:",{"type":225,"tag":359,"props":1546,"children":1548},{"className":456,"code":1547,"language":458,"meta":207,"style":207},"New-Item -ItemType SymbolicLink -Path \"$env:USERPROFILE\\AppData\\Local\\Packages\\Microsoft.WindowsTerminal_8wekyb3d8bbwe\\LocalState\\settings.json\" -Target \"$env:USERPROFILE\\dotfiles\\config\\windowsTerminal\\settings.json\"\"\n",[1549],{"type":225,"tag":366,"props":1550,"children":1551},{"__ignoreMap":207},[1552],{"type":225,"tag":370,"props":1553,"children":1554},{"class":372,"line":373},[1555,1560,1564,1569,1573,1578,1582,1586,1591,1595,1599,1604,1608,1612,1617],{"type":225,"tag":370,"props":1556,"children":1557},{"style":543},[1558],{"type":230,"value":1559},"New-Item",{"type":225,"tag":370,"props":1561,"children":1562},{"style":483},[1563],{"type":230,"value":1387},{"type":225,"tag":370,"props":1565,"children":1566},{"style":377},[1567],{"type":230,"value":1568},"ItemType SymbolicLink ",{"type":225,"tag":370,"props":1570,"children":1571},{"style":483},[1572],{"type":230,"value":486},{"type":225,"tag":370,"props":1574,"children":1575},{"style":377},[1576],{"type":230,"value":1577},"Path ",{"type":225,"tag":370,"props":1579,"children":1580},{"style":483},[1581],{"type":230,"value":570},{"type":225,"tag":370,"props":1583,"children":1584},{"style":377},[1585],{"type":230,"value":575},{"type":225,"tag":370,"props":1587,"children":1588},{"style":509},[1589],{"type":230,"value":1590},"\\AppData\\Local\\Packages\\Microsoft.WindowsTerminal_8wekyb3d8bbwe\\LocalState\\settings.json",{"type":225,"tag":370,"props":1592,"children":1593},{"style":483},[1594],{"type":230,"value":506},{"type":225,"tag":370,"props":1596,"children":1597},{"style":483},[1598],{"type":230,"value":1387},{"type":225,"tag":370,"props":1600,"children":1601},{"style":377},[1602],{"type":230,"value":1603},"Target ",{"type":225,"tag":370,"props":1605,"children":1606},{"style":483},[1607],{"type":230,"value":570},{"type":225,"tag":370,"props":1609,"children":1610},{"style":377},[1611],{"type":230,"value":575},{"type":225,"tag":370,"props":1613,"children":1614},{"style":509},[1615],{"type":230,"value":1616},"\\dotfiles\\config\\windowsTerminal\\settings.json",{"type":225,"tag":370,"props":1618,"children":1619},{"style":377},[1620],{"type":230,"value":1621},"\"\"\n",{"type":225,"tag":226,"props":1623,"children":1624},{},[1625],{"type":230,"value":1626},"Because I use symbolic links, when I modify the configuration of my Windows Terminal (event through the UI), the settings file in my git repository is the one being modified so I can commit it and push it so that my other machines have the latest version. And it's the same for all my settings files.",{"type":225,"tag":226,"props":1628,"children":1629},{},[1630],{"type":230,"value":1631},"There are others settings in my repository and I will probably continue to add some later.",{"type":225,"tag":232,"props":1633,"children":1635},{"id":1634},"what-i-did-not-automate-yet",[1636],{"type":230,"value":1637},"What I did not automate ... yet!",{"type":225,"tag":226,"props":1639,"children":1640},{},[1641],{"type":230,"value":1642},"There are many things I did not automate yet and that I will do bit by bit.  Nevertheless, I am happy with the current setup. There is much room for improvement but I've already won some time last time I changed my laptop, and that was the goal.",{"type":225,"tag":226,"props":1644,"children":1645},{},[1646,1648,1655,1657,1663],{"type":230,"value":1647},"As I've just said, there are other configurations I would probably need to store in my repository. ",{"type":225,"tag":271,"props":1649,"children":1652},{"href":1650,"rel":1651},"https://docs.microsoft.com/en-us/windows/powertoys",[275],[1653],{"type":230,"value":1654},"Power Toys",{"type":230,"value":1656}," settings might be one of them unless they add a settings sync (issue already opened ",{"type":225,"tag":271,"props":1658,"children":1661},{"href":1659,"rel":1660},"https://github.com/microsoft/PowerToys/issues/3381",[275],[1662],{"type":230,"value":651},{"type":230,"value":1664},"). It would be better because there are many settings files so only using symbolic links could be cumbersome.",{"type":225,"tag":226,"props":1666,"children":1667},{},[1668,1670,1677],{"type":230,"value":1669},"Most of the software I need is installed by my setup script. One exception is JetBrains products but I hope it will be possible soon. I have some commented lines in my installation script about automating the setup of ",{"type":225,"tag":271,"props":1671,"children":1674},{"href":1672,"rel":1673},"https://docs.microsoft.com/en-us/windows/wsl/install",[275],[1675],{"type":230,"value":1676},"WSL2",{"type":230,"value":1678}," and docker (well installation of Rancher Desktop to be more precise as a replacement of Docker Desktop due to its new license model) that required some windows features to be installed.  I think these lines should work with some adjustments, it's just that I did that manually last time and did not take the time to test the corresponding commands properly.",{"type":225,"tag":226,"props":1680,"children":1681},{},[1682],{"type":230,"value":1683},"There are also some limitations to my current approach to installing my developer machine:",{"type":225,"tag":302,"props":1685,"children":1686},{},[1687,1701,1706],{"type":225,"tag":306,"props":1688,"children":1689},{},[1690,1692,1699],{"type":230,"value":1691},"As everything is contained in a public GitHub repository, I can't keep some files or secrets private obviously (it could be useful to configure a new machine to ",{"type":225,"tag":271,"props":1693,"children":1696},{"href":1694,"rel":1695},"https://docs.github.com/en/authentication/managing-commit-signature-verification/signing-commits",[275],[1697],{"type":230,"value":1698},"sign commits",{"type":230,"value":1700}," for instance)",{"type":225,"tag":306,"props":1702,"children":1703},{},[1704],{"type":230,"value":1705},"The installation script is not idempotent so it will try to re-install and re-configure everything if I re-run it (not a big deal as I mainly use it to install a new machine, but it would be nice to be able to just re-run it to get on an existing installation all the latest improvements I made on another laptop)",{"type":225,"tag":306,"props":1707,"children":1708},{},[1709],{"type":230,"value":1710},"I did not set up anything to handle multiple configurations (one for my personal laptop and one for my professional laptop for example)",{"type":225,"tag":226,"props":1712,"children":1713},{},[1714,1716,1723],{"type":230,"value":1715},"I think the tool ",{"type":225,"tag":271,"props":1717,"children":1720},{"href":1718,"rel":1719},"https://www.chezmoi.io/",[275],[1721],{"type":230,"value":1722},"chezmoi",{"type":230,"value":1724}," might help to solve some of these limitations. Maybe one day I'll take the time to dig a little deeper to see if I can improve the whole process.",{"type":225,"tag":232,"props":1726,"children":1728},{"id":1727},"to-conclude",[1729],{"type":230,"value":1730},"To conclude",{"type":225,"tag":226,"props":1732,"children":1733},{},[1734,1736,1742],{"type":230,"value":1735},"You can find the repository with all the code I use to automate my installation ",{"type":225,"tag":271,"props":1737,"children":1740},{"href":1738,"rel":1739},"https://github.com/TechWatching/dotfiles",[275],[1741],{"type":230,"value":651},{"type":230,"value":409},{"type":225,"tag":226,"props":1744,"children":1745},{},[1746],{"type":230,"value":1747},"Automating my machine installation was not that fun, but I learned lots of things while doing it about package managers, windows, symbolic links, PowerShell... And in the end, it is very satisfying when everything starts to install automatically and you find a familiar environment on a new laptop.",{"type":225,"tag":226,"props":1749,"children":1750},{},[1751],{"type":230,"value":1752},"Whether you adopt this approach or another to automate the setup of your development machine, I think it's an important thing to do. It does not have to be complex, and you don't need to automate everything. But you should probably at least use a package manager for your software installations, have a list somewhere of the most useful tools you need, and keep a copy of the configuration files of your most important tools.",{"type":225,"tag":226,"props":1754,"children":1755},{},[1756,1758,1765],{"type":230,"value":1757},"This article is part of the ",{"type":225,"tag":271,"props":1759,"children":1762},{"href":1760,"rel":1761},"https://townhall.hashnode.com/4-articles-in-4-weeks-hashnode-writing-contest",[275],[1763],{"type":230,"value":1764},"4 articles in 4 weeks Hashnode writing contest",{"type":230,"value":409},{"type":225,"tag":226,"props":1767,"children":1768},{},[1769],{"type":230,"value":1770},"Happy learning.",{"type":225,"tag":1772,"props":1773,"children":1774},"style",{},[1775],{"type":230,"value":1776},"html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":207,"searchDepth":474,"depth":474,"links":1778},[1779,1780,1781,1787,1788,1789],{"id":234,"depth":474,"text":237},{"id":292,"depth":474,"text":295},{"id":599,"depth":474,"text":602,"children":1782},[1783,1784,1785,1786],{"id":606,"depth":520,"text":609},{"id":656,"depth":520,"text":659},{"id":811,"depth":520,"text":814},{"id":1238,"depth":520,"text":1241},{"id":1460,"depth":474,"text":1463},{"id":1634,"depth":474,"text":1637},{"id":1727,"depth":474,"text":1730},"markdown","content:1.posts:42.automate-developer-machine.md","content","1.posts/42.automate-developer-machine.md","md",[1796,1809],{"_path":136,"_dir":205,"_draft":206,"_partial":206,"_locale":207,"title":135,"description":1797,"lead":1798,"date":1799,"image":1800,"badge":1802,"tags":1803,"_type":1790,"_id":1807,"_source":1792,"_file":1808,"_extension":1794},"This article is a discussion about API clients. Without being a comparison between the best API clients, this article talks about the pros and cons of some popular tools to send HTTP requests to an API. The goal is not to elect the best one, but rather to try to answer the following question: what we should consider when choosing an API client, and what are the challenges when using one?","What should you consider when choosing an API client?","2022-09-08T00:00:00.000Z",{"src":1801},"/images/tools_1.jpg",{"label":212},[220,1804,1805,1806],"HTTP","thoughts","rest","content:1.posts:43.http-clients.md","1.posts/43.http-clients.md",{"_path":130,"_dir":205,"_draft":206,"_partial":206,"_locale":207,"title":129,"description":1810,"lead":1811,"date":1812,"badge":1813,"image":1815,"tags":1817,"_type":1790,"_id":1818,"_source":1792,"_file":1819,"_extension":1794},"Like I wrote in my last article, as a developer sometimes you get stuck on a problem for a few hours or a few days, your code won't work, and you think nobody can help you 😿. This can be very frustrating, but fortunately, there are plenty of ways to look for a solution or to seek help. You are probably already using some of them with success, yet there may be some you don't think of and that could help you a lot. That is the topic of this article.","Some tips to get unstuck as a developer","2022-08-27T00:00:00.000Z",{"label":1814},"Essay",{"src":1816},"/images/laptop_1.jpg",[1805],"content:1.posts:41.get-unstuck.md","1.posts/41.get-unstuck.md",1716749601549]