<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Krzysztof Kopieczek</title>
    <description>The latest articles on DEV Community by Krzysztof Kopieczek (@kopieczekdev).</description>
    <link>https://dev.to/kopieczekdev</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F616507%2F27550e7c-1094-4bad-84dd-5ca7a973d400.jpeg</url>
      <title>DEV Community: Krzysztof Kopieczek</title>
      <link>https://dev.to/kopieczekdev</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/kopieczekdev"/>
    <language>en</language>
    <item>
      <title>Force English on all Microsoft sites (Azure, Learn)</title>
      <dc:creator>Krzysztof Kopieczek</dc:creator>
      <pubDate>Fri, 03 Mar 2023 08:49:54 +0000</pubDate>
      <link>https://dev.to/kopieczekdev/force-english-on-all-microsoft-sites-azure-learn-a07</link>
      <guid>https://dev.to/kopieczekdev/force-english-on-all-microsoft-sites-azure-learn-a07</guid>
      <description>&lt;p&gt;Microsoft has a great documentation pages, but I'm willing to read them in English, not in my web browser's language. Additionally, very often the first couple of results in Google are linked to articles in my native language. Unfortunately, the quality of automatic translations from English is not always accurate.&lt;/p&gt;

&lt;p&gt;I'm tired of constantly switching articles to English, or scrolling on Google results to find proper links (even if I enter English search phrases).&lt;/p&gt;

&lt;p&gt;As always, there is an easy solution to this - &lt;a href="https://chrome.google.com/webstore/detail/redirector/ocgpenflpmgnfapjedencafcfakcekcd"&gt;Redirector&lt;/a&gt; is a Chrome Extension which automatically redirects URLs to user-defined rules.&lt;/p&gt;

&lt;p&gt;The rule for all  Microsoft pages is:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Example URL:&lt;/strong&gt; &lt;code&gt;https://learn.microsoft.com/pl-pl/azure/batch/batch-technical-overview&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Include pattern:&lt;/strong&gt; &lt;code&gt;https://*.microsoft.com/pl-pl/*&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Redirect to:&lt;/strong&gt; &lt;code&gt;https://$1.microsoft.com/en-us/$2&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Pattern type:&lt;/strong&gt; Wildcard&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Example result:&lt;/strong&gt; &lt;code&gt;https://learn.microsoft.com/en-us/azure/batch/batch-technical-overview&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Please note, that in the &lt;strong&gt;pattern&lt;/strong&gt; field, the &lt;code&gt;*&lt;/code&gt; character replaces all the phrases that need to be changed, and in &lt;strong&gt;Redirect to&lt;/strong&gt; those phrases are put into correct place.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;$1&lt;/code&gt; for the subdomain: &lt;code&gt;learn.microsoft.com&lt;/code&gt;, &lt;code&gt;azure.microsoft.com&lt;/code&gt;, etc&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;$2&lt;/code&gt; for the rest of the URL&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;That's all. Plenty of redundant clicks a day saved.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Beware of caching in Azure Key Vault</title>
      <dc:creator>Krzysztof Kopieczek</dc:creator>
      <pubDate>Wed, 22 Feb 2023 13:13:43 +0000</pubDate>
      <link>https://dev.to/kopieczekdev/beware-of-caching-in-azure-key-vault-5abh</link>
      <guid>https://dev.to/kopieczekdev/beware-of-caching-in-azure-key-vault-5abh</guid>
      <description>&lt;p&gt;Did you know, that secretes being read from Azure Key Vault may be out of date? This happened to me and caused a lot of confusion. The secret was changed in the Key Vault, but the application was still getting the old, unchanged value. &lt;/p&gt;

&lt;p&gt;It turned out, that when &lt;a href="https://learn.microsoft.com/en-us/azure/app-service/app-service-key-vault-references?tabs=azure-cli#reference-syntax" rel="noopener noreferrer"&gt;Key Vault references&lt;/a&gt; are stored in the Web App or Azure Function configuration (as in the screenshot below), the values may be cached for even 24 hours!!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fdk4jcz622el2k66bti70.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fdk4jcz622el2k66bti70.png" alt="Screenshot of Azure Function Configuration"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;To be clear, there is an information about this caching &lt;a href="https://learn.microsoft.com/en-us/azure/app-service/app-service-key-vault-references?tabs=azure-cli#rotation" rel="noopener noreferrer"&gt;in the documentation&lt;/a&gt;, but it's not as visible, as it should be. In my case, the value finally was refreshed in the cache after 16 hours. &lt;/p&gt;

&lt;p&gt;Happily, there is a solution for this and your application don't have to be dependent on this unpredictable caching mechanism. In order to have secretes always up to date, Key Vault should be accessed via &lt;a href="https://learn.microsoft.com/en-us/azure/key-vault/secrets/quick-create-net" rel="noopener noreferrer"&gt;the SDK&lt;/a&gt; from the application code. &lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight csharp"&gt;&lt;code&gt;

&lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;client&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nf"&gt;SecretClient&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nf"&gt;Uri&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;kvUri&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nf"&gt;DefaultAzureCredential&lt;/span&gt;&lt;span class="p"&gt;());&lt;/span&gt;

&lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;secret&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="n"&gt;client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;GetSecretAsync&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"secretName"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="n"&gt;Console&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;WriteLine&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;$"Your secret is '&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="n"&gt;secret&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Value&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Value&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s"&gt;'."&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;It's not as easy as Key Vault references, but there is no alternative if the application requires immediate reaction for changed secrets. &lt;/p&gt;

&lt;p&gt;PS.&lt;br&gt;
Azure Key Vault pricing model is based on per-request model, so still you'd like to cache secrets anyway: &lt;a href="https://learn.microsoft.com/en-us/samples/azure/azure-sdk-for-net/azure-key-vault-proxy/" rel="noopener noreferrer"&gt;read about Key Vault proxy policy&lt;/a&gt; &lt;/p&gt;

</description>
      <category>azure</category>
      <category>azurekeyvault</category>
    </item>
    <item>
      <title>terraform apply in Azure DevOps fails with "resource with the ID already exists"</title>
      <dc:creator>Krzysztof Kopieczek</dc:creator>
      <pubDate>Tue, 26 Oct 2021 18:45:57 +0000</pubDate>
      <link>https://dev.to/kopieczekdev/terraform-apply-in-azure-devops-fails-with-resource-with-the-id-already-exists-5694</link>
      <guid>https://dev.to/kopieczekdev/terraform-apply-in-azure-devops-fails-with-resource-with-the-id-already-exists-5694</guid>
      <description>&lt;p&gt;Recently I was developing a simple Terraform pipeline in Azure DevOps. Everything seemed intuitive and easy - install, init, plan, apply. Clear steps and UI forms for every setting. &lt;br&gt;
&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fz2lm0drttjl00wgr2l9t.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fz2lm0drttjl00wgr2l9t.png" alt="terraform init settings in the Azure DevOps Pipeline"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Everything was configured properly. Code was working fine from my local machine, but in Azure DevOps, pipeline run successfully only for the first time. Every next attempt resulted in the following error:&lt;br&gt;
&lt;code&gt;Error: The process 'C:\hostedtoolcache\windows\terraform\1.0.8\x64\terraform.exe' failed with exit code 1&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;And details from the log:&lt;br&gt;
&lt;code&gt;Error: [0m[0m[1mA resource with the ID "/subscriptions/45197771-2d3e-4685-aaef-e96f62dd80b4/resourceGroups/tfexample-sample-rg" already exists - to be managed via Terraform this resource needs to be imported into the State. Please see the resource documentation for "azurerm_resource_group" for more information.[0m&lt;/code&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  The problem was in my code
&lt;/h2&gt;


&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;provider "azurerm" {
  subscription_id = "45197771-2d3e-4685-aaef-e96f62dd80b4"
  features {}
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;It was missing the &lt;code&gt;backend&lt;/code&gt; part! Code worked from my local machine, because terraform saved the state in local &lt;code&gt;terraform.tfstate&lt;/code&gt; file (default terraform behavior), but in Azure DevOps the settings provided in the UI was ignored with no clear error message. &lt;code&gt;terraform apply&lt;/code&gt; couldn't find the state file, so was creating every resource from scratch each time.&lt;/p&gt;
&lt;h2&gt;
  
  
  The solution
&lt;/h2&gt;

&lt;p&gt;I fixed the code by adding empty properties. That was enough to have the pipeline working correctly. Note that no values are required...&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;provider "azurerm" {
  subscription_id = "45197771-2d3e-4685-aaef-e96f62dd80b4"
  features {}
}

terraform {
  backend "azurerm" {
    resource_group_name = ""
    storage_account_name = "" 
    container_name       = "" 
    key                  = ""  
  }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Please leave some comment if this helped.&lt;/p&gt;

</description>
      <category>azure</category>
      <category>terraform</category>
      <category>azuredevops</category>
    </item>
    <item>
      <title>Improve command line UX on Windows</title>
      <dc:creator>Krzysztof Kopieczek</dc:creator>
      <pubDate>Tue, 10 Aug 2021 19:56:17 +0000</pubDate>
      <link>https://dev.to/kopieczekdev/improve-terminal-ux-on-windows-4ff6</link>
      <guid>https://dev.to/kopieczekdev/improve-terminal-ux-on-windows-4ff6</guid>
      <description>&lt;p&gt;As a .NET developer who remembers coding in .NET Framework 2.0, I'm not used to use command line at daily basis, but recently my workflow includes Bash/PowerShell/Azure CLI more and more every day. Over time, I improved my setup and here is a configuration which I may recommend. &lt;/p&gt;

&lt;p&gt;This is how it will look at the end:&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--vMlyVx4J--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xj7rabm1kl4g3hjzxdqo.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--vMlyVx4J--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/xj7rabm1kl4g3hjzxdqo.png" alt="image" width="800" height="432"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  1. Get windows terminal
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://aka.ms/terminal"&gt;https://aka.ms/terminal&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  2. Pin Windows Terminal to taskbar
&lt;/h2&gt;

&lt;p&gt;This will allow to quickly run Terminal with a shortcut Win+number (e.g. Win+5 as shown below)&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--3JCCLqmQ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0w44591hrlgln8rp7wpz.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--3JCCLqmQ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0w44591hrlgln8rp7wpz.png" alt="image" width="336" height="121"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  3. Update PowerShell
&lt;/h2&gt;

&lt;p&gt;Run PowerwShell and type &lt;code&gt;$PSVersionTable.PSVersion&lt;/code&gt; Probably version 5 is installed on your machine.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;Major&lt;/span&gt;&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="nx"&gt;Minor&lt;/span&gt;&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="nx"&gt;Build&lt;/span&gt;&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="nx"&gt;Revision&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="o"&gt;-----&lt;/span&gt;&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="o"&gt;-----&lt;/span&gt;&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="o"&gt;-----&lt;/span&gt;&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="o"&gt;--------&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="mi"&gt;5&lt;/span&gt;&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="w"&gt;      &lt;/span&gt;&lt;span class="mi"&gt;19041&lt;/span&gt;&lt;span class="w"&gt;  &lt;/span&gt;&lt;span class="mi"&gt;1023&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Go to &lt;a href="https://github.com/PowerShell/PowerShell"&gt;https://github.com/PowerShell/PowerShell&lt;/a&gt;, download and run the installer. This will install v7 side-by-side with v5, but it will be tackled in the next steps. &lt;/p&gt;

&lt;h2&gt;
  
  
  4. Set PowerShell 7 as default
&lt;/h2&gt;

&lt;p&gt;Windows Terminal opens PowerShell 5 by default, but it's configurable. Go to Settings &amp;gt; Startup and select the second "PowerShell" item in the "Default profile".&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--oHyudCEY--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/uuit4wtj46fs2w9rycce.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--oHyudCEY--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/uuit4wtj46fs2w9rycce.png" alt="image" width="557" height="329"&gt;&lt;/a&gt;&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--8HphpsuJ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/hxh1a73z9wgrfc0xdmtg.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--8HphpsuJ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/hxh1a73z9wgrfc0xdmtg.png" alt="image" width="675" height="202"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Or "Open JSON file" and locate the &lt;code&gt;defaultProfile&lt;/code&gt; property. Replace its value with the guid of &lt;code&gt;Windows.Terminal.PowershellCore&lt;/code&gt; from the bottom of the json.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--pi--q9wH--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/zejeyjmye2oozaq7fjec.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--pi--q9wH--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/zejeyjmye2oozaq7fjec.png" alt="image" width="599" height="619"&gt;&lt;/a&gt;&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--Z5Hh2dcX--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/p4ea140lr8k4mkib9e0o.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--Z5Hh2dcX--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/p4ea140lr8k4mkib9e0o.png" alt="image" width="597" height="519"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Restart Windows Terminal to verify the step.&lt;/p&gt;
&lt;h2&gt;
  
  
  5. Install a proper font
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;I recommend Caskaydia Cove from from &lt;a href="https://github.com/ryanoasis/nerd-fonts"&gt;Nerd Fonts&lt;/a&gt; repository. This font is based on well-known &lt;a href="https://github.com/microsoft/cascadia-code"&gt;Cascadia Code&lt;/a&gt;. Nerd Fonts mod adds extra glyphs to the original font.&lt;/li&gt;
&lt;li&gt;Download the patched version of the font &lt;a href="https://github.com/ryanoasis/nerd-fonts/blob/master/patched-fonts/CascadiaCode/Regular/CaskaydiaCoveNerdFontMono-Regular.ttf"&gt;from here&lt;/a&gt; (use "Download" button)&lt;/li&gt;
&lt;li&gt;Go to downloads folder on your machine, locate downloaded *.ttf file, press right mouse button and select "Install".&lt;/li&gt;
&lt;li&gt;Change the font in Windows Terminal settings for the PowerShell" profile or in json.
&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--1mFtrx6p--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/a9zc6peh2c61nx3m21bi.png" alt="change font in settings" width="779" height="428"&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;
  
  
  6. Install required PowerShell modules
&lt;/h2&gt;

&lt;p&gt;Now the fun part begins. We will install more themes and tweaks to the Terminal. Run these commands&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;Install-Module&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;posh-git&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-Scope&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;CurrentUser&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;Install-Module&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;oh-my-posh&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-Scope&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;CurrentUser&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  7. Pick a theme
&lt;/h2&gt;

&lt;p&gt;Run &lt;code&gt;Get-PoshThemes&lt;/code&gt; and locate one you like the most.&lt;/p&gt;

&lt;h2&gt;
  
  
  8. Set theme
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;Set-PoshPrompt&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-Theme&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;themename&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;I chosen &lt;code&gt;powerlevel10k_classic&lt;/code&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  9. Save settings in your profile
&lt;/h2&gt;

&lt;p&gt;Run &lt;code&gt;notepad $PROFILE&lt;/code&gt; in base folder (create file if don't exist) and paste the following. Replace &lt;code&gt;themename&lt;/code&gt; with your theme name.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;Import-Module&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;posh-git&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;Import-Module&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;oh-my-posh&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;Set-PoshPrompt&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-Theme&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;themename&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  10. Enjoy more productive terminal environment 🙂
&lt;/h2&gt;

&lt;p&gt;And feel free to post the font you have selected.&lt;/p&gt;

&lt;h3&gt;
  
  
  PS
&lt;/h3&gt;

&lt;p&gt;Kudos to Scott Hanselman - I saw the pretty command line at his blog for the first time. Here is the &lt;a href="https://www.hanselman.com/blog/how-to-make-a-pretty-prompt-in-windows-terminal-with-powerline-nerd-fonts-cascadia-code-wsl-and-ohmyposh"&gt;original post&lt;/a&gt;&lt;/p&gt;

</description>
      <category>windows</category>
      <category>windowsterminal</category>
      <category>commandline</category>
      <category>productivity</category>
    </item>
    <item>
      <title>How to import data from spreadsheet easily and productive</title>
      <dc:creator>Krzysztof Kopieczek</dc:creator>
      <pubDate>Sat, 19 Jun 2021 10:19:30 +0000</pubDate>
      <link>https://dev.to/kopieczekdev/how-to-import-data-from-spreadsheet-easily-and-productive-clj</link>
      <guid>https://dev.to/kopieczekdev/how-to-import-data-from-spreadsheet-easily-and-productive-clj</guid>
      <description>&lt;p&gt;This post is for developers, who just got a huge spreadsheet of data and have to import them to the application. Recently I was in that position and I have a couple of takeaways how to make the process easier, faster and less painful. &lt;/p&gt;

&lt;h2&gt;
  
  
  1. Make a copy of a spreadsheet and fix it
&lt;/h2&gt;

&lt;p&gt;Non-technical people in general see data much different from a developer. You will have to remove duplicates, standardize fields, maybe add additional fields and probably remove a lot of useless data. This step is to make the parsing easier and remember, that most of the time it's easier to change data in the document, than making sophisticated mechanisms in the code.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;For &lt;strong&gt;duplicated rows,&lt;/strong&gt; try adding just another column as a flag field (e.g. products duplicated in different packets - add fields/columns &lt;code&gt;IsPacketA&lt;/code&gt;, &lt;code&gt;IsPacketB&lt;/code&gt;, etc).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Avoid lots of data in one column&lt;/strong&gt; - split everything that you think should be different property, but don't overdo -you are not creating a relational database here.&lt;/li&gt;
&lt;li&gt;If &lt;strong&gt;some data duplicates are necessary&lt;/strong&gt; (e.g. product variants - color, size, etc.), make sure that data is consistent. Look for typos and similarities (e.g. XL and big - use one standard for size) and always split such data in the same way (comma &lt;code&gt;,&lt;/code&gt; worked best for me).&lt;/li&gt;
&lt;li&gt;Check &lt;strong&gt;floating point character&lt;/strong&gt; - using comma may cause incorrect parsing, so the best idea would be to use en-Us regionals in the document.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  2. Export data to CSV
&lt;/h2&gt;

&lt;p&gt;Working with plain text is much easier, than parsing rows and cells. In C# there is a super simple NuGet called &lt;a href="https://joshclose.github.io/CsvHelper/getting-started/"&gt;CsvHelper&lt;/a&gt; that will load all data in a few lines of code. Make sure that &lt;strong&gt;delimiter&lt;/strong&gt; may conflict with your data - for me, semicolon worked perfectly. I tried working with TSV but in my case it was missing new lines and some empty columns.&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Start coding with difficult data
&lt;/h2&gt;

&lt;p&gt;Now the data is ready to be loaded in the code. Before developing anything, watch for new lines and special characters - they might be parsed incorrectly and/or cause the application to crash. Maybe you will have to go back to fix the data in the spreadsheet but it much more time-consuming now, than at the later stages.&lt;/p&gt;

&lt;h2&gt;
  
  
  4. ID's, keys
&lt;/h2&gt;

&lt;p&gt;Store id's/keys in the spreadsheet from step 1. This will help work with the changes at later stages - it will be easier to locate row by key in the database to update it. &lt;a href="https://www.guidgenerator.com/"&gt;Guid generator&lt;/a&gt; will help you with generating unique values.&lt;/p&gt;

&lt;h2&gt;
  
  
  5. Explain the "fixed spreadsheet" to the author
&lt;/h2&gt;

&lt;p&gt;Having two sources of data is a nightmare. You will encounter situations, where you will have to investigate, which document is newer, merge changes, resolve conflicts... To avoid this, explain your "fixed document" (step 1) to people who created the source document. &lt;/p&gt;

&lt;h2&gt;
  
  
  6. Finally, track changes in the document
&lt;/h2&gt;

&lt;p&gt;Google Sheets makes it easy with version history. Maybe think about automating the process.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Simple way to transform any Google Sheet to JSON</title>
      <dc:creator>Krzysztof Kopieczek</dc:creator>
      <pubDate>Fri, 23 Apr 2021 20:53:02 +0000</pubDate>
      <link>https://dev.to/kopieczekdev/simple-way-to-transform-any-google-sheet-to-json-1o74</link>
      <guid>https://dev.to/kopieczekdev/simple-way-to-transform-any-google-sheet-to-json-1o74</guid>
      <description>&lt;p&gt;Solution is really easy, but with one big drawback - the sheet needs to accessed publicly on the Internet. In my case this is not a permanent feature - I just have to move data from one source to another one, but I would not recommend this solution if you deal with sensitive data. &lt;/p&gt;

&lt;h1&gt;
  
  
  Prepare the sheet
&lt;/h1&gt;

&lt;p&gt;Go to &lt;strong&gt;File &amp;gt; Publish to the web&lt;/strong&gt; and select &lt;strong&gt;Entire Document &amp;gt; Web Page&lt;/strong&gt;. That's all here, just close the window. &lt;br&gt;
&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fy7n6dszibuh8j3osy76b.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fy7n6dszibuh8j3osy76b.png" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Next, copy the sheet id from the URL in the browser.&lt;/p&gt;
&lt;h1&gt;
  
  
  The saviour
&lt;/h1&gt;

&lt;p&gt;&lt;a href="http://gsx2json.com" rel="noopener noreferrer"&gt;gsx2json&lt;/a&gt; is a tool which does all the magic for us. Please go to the project website and buy a coffee to the author if it helped you. It saved me a ton of time!&lt;/p&gt;
&lt;h1&gt;
  
  
  Get the data
&lt;/h1&gt;

&lt;p&gt;I use C# but the code is quite simple. Just create the url with the sheet id and get the JSON.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight csharp"&gt;&lt;code&gt;&lt;span class="c1"&gt;// using System.Net;&lt;/span&gt;
&lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;sheetId&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="s"&gt;"1zpss4g850wpb9YltdzefCyvl2Vl4gDZ-Ip4Hk-dQjOk"&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
&lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;uri&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nf"&gt;Uri&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;$"http://gsx2json.com/api?id=&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="n"&gt;sheetId&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="s"&gt;"&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="kt"&gt;string&lt;/span&gt; &lt;span class="n"&gt;json&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt; 

&lt;span class="k"&gt;using&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;wc&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="k"&gt;new&lt;/span&gt; &lt;span class="nf"&gt;WebClient&lt;/span&gt;&lt;span class="p"&gt;())&lt;/span&gt;
&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="n"&gt;json&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="n"&gt;wc&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;DownloadStringTaskAsync&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;uri&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here's the &lt;a href="http://gsx2json.com/api?id=1zpss4g850wpb9YltdzefCyvl2Vl4gDZ-Ip4Hk-dQjOk" rel="noopener noreferrer"&gt;link&lt;/a&gt; to the API if you'd like to review the JSON created by gsx2json.&lt;/p&gt;

&lt;h1&gt;
  
  
  Transform the data
&lt;/h1&gt;

&lt;p&gt;Now, when you got the data, do whatever it has to be done. Here is an example of extracting rows from the JSON response.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight csharp"&gt;&lt;code&gt;&lt;span class="c1"&gt;// using Newtonsoft.Json.Linq;&lt;/span&gt;
&lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;tmp&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;JObject&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;Parse&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;json&lt;/span&gt;&lt;span class="p"&gt;)[&lt;/span&gt;&lt;span class="s"&gt;"rows"&lt;/span&gt;&lt;span class="p"&gt;];&lt;/span&gt;
&lt;span class="kt"&gt;var&lt;/span&gt; &lt;span class="n"&gt;players&lt;/span&gt; &lt;span class="p"&gt;=&lt;/span&gt; &lt;span class="n"&gt;tmp&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;ToObject&lt;/span&gt;&lt;span class="p"&gt;&amp;lt;&lt;/span&gt;&lt;span class="n"&gt;Player&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="k"&gt;]&amp;gt;&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h1&gt;
  
  
  Cleaning up
&lt;/h1&gt;

&lt;p&gt;Remember to unpublish the sheet from the Internet. And that's all!&lt;/p&gt;

</description>
      <category>5days5blogposts</category>
      <category>googlesheets</category>
      <category>csharp</category>
      <category>json</category>
    </item>
    <item>
      <title>Be more productive in Visual Studio with #TODO</title>
      <dc:creator>Krzysztof Kopieczek</dc:creator>
      <pubDate>Thu, 22 Apr 2021 21:58:19 +0000</pubDate>
      <link>https://dev.to/kopieczekdev/be-more-productive-in-visual-studio-with-todo-1al0</link>
      <guid>https://dev.to/kopieczekdev/be-more-productive-in-visual-studio-with-todo-1al0</guid>
      <description>&lt;p&gt;&lt;a href="https://docs.microsoft.com/en-us/visualstudio/ide/using-the-task-list" rel="noopener noreferrer"&gt;Task List&lt;/a&gt; in Visual Studio is not very popular but it's one of the most simple and productive solutions to remember things to do. Let me show you how to use in everyday work.&lt;/p&gt;

&lt;h1&gt;
  
  
  How it works?
&lt;/h1&gt;

&lt;p&gt;The idea is to just write simple &lt;code&gt;// TODO&lt;/code&gt; in the code and the IDE will show this line of code in the Task List window. You can also write description afterwards to also have it in the Task List: &lt;code&gt;// TODO need to add logic here&lt;/code&gt;. This is how it looks in the code:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight csharp"&gt;&lt;code&gt;&lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;someFlag&lt;/span&gt; &lt;span class="p"&gt;==&lt;/span&gt; &lt;span class="k"&gt;true&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nf"&gt;doSomething&lt;/span&gt;&lt;span class="p"&gt;();&lt;/span&gt;
    &lt;span class="nf"&gt;doSomethingMore&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="k"&gt;else&lt;/span&gt;
&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="c1"&gt;// TODO need to add logic here&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And that's how it looks in my IDE. I disabled all the additional columns because for me they are they are unnecessary.&lt;br&gt;
&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fl77lz5twq1xjw1kvl3h1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fl77lz5twq1xjw1kvl3h1.png" alt="image"&gt;&lt;/a&gt; &lt;/p&gt;

&lt;h1&gt;
  
  
  Tips and tricks
&lt;/h1&gt;

&lt;ul&gt;
&lt;li&gt;double click on task will open that particular line in the code&lt;/li&gt;
&lt;li&gt;I prefer to leave only the "Description" column and hide all the others, as they are irrelevant for me&lt;/li&gt;
&lt;li&gt;add a number after &lt;code&gt;//TODO&lt;/code&gt; and before description and you will be able to sort the list by priorities&lt;/li&gt;
&lt;li&gt;add your initials after &lt;code&gt;//TODO&lt;/code&gt; and use search if your colleagues refuse to handle their &lt;em&gt;todos&lt;/em&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;h1&gt;
  
  
  When to use it?
&lt;/h1&gt;

&lt;ul&gt;
&lt;li&gt;when you are in the flow and would like to remember something for later&lt;/li&gt;
&lt;li&gt;when you would like to maintain clear git commit log and you don't like to have big commits&lt;/li&gt;
&lt;li&gt;when you notice a refactor opportunity/necessity but you would rather do it later&lt;/li&gt;
&lt;/ul&gt;

&lt;h1&gt;
  
  
  When not to use it?
&lt;/h1&gt;

&lt;ul&gt;
&lt;li&gt;this is not a feature to replace your kanban board&lt;/li&gt;
&lt;li&gt;please don't use it to mark tasks you will maybe do in future sprint&lt;/li&gt;
&lt;li&gt;don't delegate work to your colleagues with this Task List&lt;/li&gt;
&lt;/ul&gt;

&lt;h1&gt;
  
  
  How to show Task List in VS?
&lt;/h1&gt;

&lt;p&gt;Just press &lt;code&gt;Ctrl + Q&lt;/code&gt; and type "task list" or press &lt;code&gt;Ctrl + W, T&lt;/code&gt; .&lt;/p&gt;

</description>
      <category>5days5blogposts</category>
      <category>visualstudio</category>
      <category>productivity</category>
    </item>
    <item>
      <title>How to embed GIFs on dev.to posts with Azure</title>
      <dc:creator>Krzysztof Kopieczek</dc:creator>
      <pubDate>Wed, 21 Apr 2021 21:51:16 +0000</pubDate>
      <link>https://dev.to/kopieczekdev/how-to-embed-gifs-on-dev-to-posts-with-azure-1p1b</link>
      <guid>https://dev.to/kopieczekdev/how-to-embed-gifs-on-dev-to-posts-with-azure-1p1b</guid>
      <description>&lt;p&gt;Yesterday I had an idea to show text completion by Autohotkey with animated images (GIFs)&lt;br&gt;
&lt;/p&gt;
&lt;div class="ltag__link"&gt;
  &lt;a href="/kopieczekdev" class="ltag__link__link"&gt;
    &lt;div class="ltag__link__pic"&gt;
      &lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F616507%2F27550e7c-1094-4bad-84dd-5ca7a973d400.jpeg" alt="kopieczekdev"&gt;
    &lt;/div&gt;
  &lt;/a&gt;
  &lt;a href="/kopieczekdev/speed-up-git-commands-with-autohotkey-m46" class="ltag__link__link"&gt;
    &lt;div class="ltag__link__content"&gt;
      &lt;h2&gt;Speed up git commands with Autohotkey&lt;/h2&gt;
      &lt;h3&gt;Krzysztof Kopieczek ・ Apr 20 '21&lt;/h3&gt;
      &lt;div class="ltag__link__taglist"&gt;
        &lt;span class="ltag__link__tag"&gt;#5days5blogposts&lt;/span&gt;
        &lt;span class="ltag__link__tag"&gt;#git&lt;/span&gt;
        &lt;span class="ltag__link__tag"&gt;#productivity&lt;/span&gt;
        &lt;span class="ltag__link__tag"&gt;#autohotkey&lt;/span&gt;
      &lt;/div&gt;
    &lt;/div&gt;
  &lt;/a&gt;
&lt;/div&gt;


&lt;p&gt;Unfortunately dev.to changes pasted images to *.png. After the image is pasted to the text, it's being changed to a proper markdown image placeholder:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight markdown"&gt;&lt;code&gt;&lt;span class="p"&gt;![&lt;/span&gt;&lt;span class="nv"&gt;image&lt;/span&gt;&lt;span class="p"&gt;](&lt;/span&gt;&lt;span class="sx"&gt;https://dev-to-uploads.s3.amazonaws.com/uploads/articles/nj3ef8hw44slxqk1agn1.png&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Seeing AWS in the image source immediately triggered me to use my existing Azure subscription to host *.gif files. &lt;/p&gt;

&lt;h1&gt;
  
  
  How to upload GIF to Azure Storage
&lt;/h1&gt;

&lt;ol&gt;
&lt;li&gt;Let's assume you have existing Azure subscription. If not, you may consider reading/watching different tutorial.&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Create a new Storage Account. I suggest using a new, separate resource group for your "blog stuff" &lt;br&gt;
&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fb2aye92j18p9wgdgevfu.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fb2aye92j18p9wgdgevfu.png" alt="image"&gt;&lt;/a&gt;&lt;br&gt;
&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fhdbt7r947sbr98svr2ry.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fhdbt7r947sbr98svr2ry.png" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Provide account name (f.e. "kopieczekdevstoraccount"), select Azure region of your choice (any will be good, as &lt;a href="http://dev.to"&gt;dev.to&lt;/a&gt; readers are from all over the world), set &lt;strong&gt;standard&lt;/strong&gt; performance, &lt;strong&gt;v2&lt;/strong&gt; account type and replication of your choice (I chose LRS because I don't need any backup). Other settings are irrelevant.   &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Wait for the account to be created and create a container. Give it any name, f.e. "images" and set &lt;strong&gt;Blob&lt;/strong&gt; public access level.&lt;br&gt;
&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F23kxdtrfsy7yadnjfh78.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F23kxdtrfsy7yadnjfh78.png" alt="image"&gt;&lt;/a&gt;&lt;br&gt;
&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F92eynwpw78zqzv9w9519.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F92eynwpw78zqzv9w9519.png" alt="image"&gt;&lt;/a&gt;  &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Now just open newly created blob and upload your GIF.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Click on the uploaded gif on the blobls list and copy the blob URL. &lt;br&gt;
&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fudcuou9vlm3gcc6n8hbk.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fudcuou9vlm3gcc6n8hbk.png" alt="image"&gt;&lt;/a&gt; &lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Paste the URL to your post:&lt;br&gt;
&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight markdown"&gt;&lt;code&gt;&lt;span class="p"&gt;![&lt;/span&gt;&lt;span class="nv"&gt;image&lt;/span&gt;&lt;span class="p"&gt;](&lt;/span&gt;&lt;span class="sx"&gt;https://kopieczekdevstoraccount.blob.core.windows.net/images/No1p3JHaGb.gif&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Voila! Now you can use GIFs in your &lt;a href="http://dev.to"&gt;dev.to&lt;/a&gt; posts.&lt;/p&gt;

</description>
      <category>5days5blogposts</category>
      <category>azure</category>
      <category>devto</category>
      <category>gifs</category>
    </item>
    <item>
      <title>Speed up git commands with Autohotkey</title>
      <dc:creator>Krzysztof Kopieczek</dc:creator>
      <pubDate>Tue, 20 Apr 2021 18:23:29 +0000</pubDate>
      <link>https://dev.to/kopieczekdev/speed-up-git-commands-with-autohotkey-m46</link>
      <guid>https://dev.to/kopieczekdev/speed-up-git-commands-with-autohotkey-m46</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Disclaimer:&lt;/strong&gt; This solution only works on Windows.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Working with git on the command line interface seems to be faster and more productive than using a mouse. But do you know all the commands by heart? Do you type without mistakes? Yeah, me neither.&lt;/p&gt;

&lt;p&gt;Today I present a solution - &lt;a href="https://www.autohotkey.com/"&gt;Autohotkey&lt;/a&gt; will complete any command for you. &lt;/p&gt;

&lt;h1&gt;
  
  
  How it works?
&lt;/h1&gt;

&lt;p&gt;Autohotkey will complete your predefined phrases with anything you want it to. Let's start simple - watch how it works with &lt;code&gt;git checkout -&lt;/code&gt; &lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--snkbfGD4--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://kopieczedevstorage.blob.core.windows.net/blogfiles/7l8e3WzDkM.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--snkbfGD4--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://kopieczedevstorage.blob.core.windows.net/blogfiles/7l8e3WzDkM.gif" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I just write &lt;code&gt;gitc&lt;/code&gt; and press space/tab/enter and Autohotkey completes the command for me. This is because I configured it to work this way. All "scripts" are configured in *.ahk file that should be put to startup folder (its &lt;code&gt;Windows + R&lt;/code&gt; and &lt;code&gt;shell:startup&lt;/code&gt; or just &lt;code&gt;%appdata%\Microsoft\Windows\Start Menu\Programs\Startup&lt;/code&gt;).&lt;/p&gt;
&lt;h1&gt;
  
  
  Examples
&lt;/h1&gt;
&lt;h3&gt;
  
  
  Checkout
&lt;/h3&gt;


&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;::gitc::
Send, git checkout -
return
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--snkbfGD4--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://kopieczedevstorage.blob.core.windows.net/blogfiles/7l8e3WzDkM.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--snkbfGD4--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://kopieczedevstorage.blob.core.windows.net/blogfiles/7l8e3WzDkM.gif" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h3&gt;
  
  
  Rebase
&lt;/h3&gt;


&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;::gitrm::
Send, git rebase master --rebase-merges
return
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--CpGP7ILQ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://kopieczedevstorage.blob.core.windows.net/blogfiles/eewVggmVDG.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--CpGP7ILQ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://kopieczedevstorage.blob.core.windows.net/blogfiles/eewVggmVDG.gif" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h3&gt;
  
  
  Fetch and log
&lt;/h3&gt;

&lt;p&gt;It's more fun because there are 2 git commands with 1 Authotkey command.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;::gitfl::
Send, git log HEAD..origin/main --oneline
return
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--VBWa6Dx1--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://kopieczedevstorage.blob.core.windows.net/blogfiles/No1p3JHaGb.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--VBWa6Dx1--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_880/https://kopieczedevstorage.blob.core.windows.net/blogfiles/No1p3JHaGb.gif" alt="image"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  But why?
&lt;/h2&gt;

&lt;p&gt;I prefer command line because I do in git exactly what I indented to do. No more unexpected actions hidden on the UI. Writing commands also helps with learning and mastering git. If your goal is to have clean and readable history, that's the perfect way to go. &lt;/p&gt;

&lt;p&gt;Now working on the command line with git should be easier and more friendly. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Documentation:&lt;/strong&gt; &lt;a href="https://www.autohotkey.com/docs/AutoHotkey.htm"&gt;https://www.autohotkey.com/docs/AutoHotkey.htm&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  PS
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;this will also work with any kind of scripts, not only git&lt;/li&gt;
&lt;li&gt;off course, you can use Autohotkey to autocomplete your email footer or any other recurrent plain text&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>5days5blogposts</category>
      <category>git</category>
      <category>productivity</category>
      <category>autohotkey</category>
    </item>
    <item>
      <title>Hello, world!</title>
      <dc:creator>Krzysztof Kopieczek</dc:creator>
      <pubDate>Mon, 19 Apr 2021 19:28:31 +0000</pubDate>
      <link>https://dev.to/kopieczekdev/hello-world-3i90</link>
      <guid>https://dev.to/kopieczekdev/hello-world-3i90</guid>
      <description>&lt;h2&gt;
  
  
  Hello, world!
&lt;/h2&gt;

&lt;p&gt;As this my first post, please let me introduce myself. I am a software developer with 8 year of full-time experience. Most of the time I use .NET with Azure cloud, and recently I'm learning React and React Native. I work at &lt;a href="http://cloudstate.eu"&gt;cloudstate.eu&lt;/a&gt; and at the same time I'm CTO of longevity oriented startup (PL &lt;a href="https://www.jaknieumrzec.pl/"&gt;link&lt;/a&gt;).  &lt;/p&gt;

&lt;p&gt;Recently I run across an inspiring &lt;a href="https://blogconf.arkademy.dev/"&gt;conference about blogging&lt;/a&gt; so I decided to finally start a blog, what I was postponing for a long time.&lt;/p&gt;

&lt;h2&gt;
  
  
  But why?
&lt;/h2&gt;

&lt;p&gt;My motivations are summarized by &lt;a href="https://dev.to/andrzejkrzywda"&gt;Andrzej&lt;/a&gt; in &lt;a href="https://dev.to/andrzejkrzywda/what-if-you-start-your-own-dev-blog-3g74"&gt;What if you start your own dev blog?&lt;/a&gt;, and I'm sure that logging solutions of day-to-day development challenges may be beneficial for someone facing the same problem. It would be ridiculous to waste time twice for the same problem. In fact, every developer use online search to look for solutions and I do the same.&lt;/p&gt;

&lt;p&gt;Also, I would like to have an online "portfolio" as a software developer. I don't want to be anonymous anymore to anyone who would like to verify my skills.&lt;/p&gt;

&lt;h2&gt;
  
  
  Challenge accepted
&lt;/h2&gt;

&lt;p&gt;Supposedly it can only take 10 minutes to create a post - it was repeated a lot at the conference. This time I stayed at work a while longer and almost succeeded with the clock, although it's a very simple post without a line of code. &lt;/p&gt;

&lt;p&gt;I'm taking the challenge with hope that it would be beneficial for the community.&lt;/p&gt;

</description>
      <category>career</category>
      <category>5days5blogposts</category>
    </item>
  </channel>
</rss>
