<?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: Adrian P. Dunston</title>
    <description>The latest articles on DEV Community by Adrian P. Dunston (@bitcapulet).</description>
    <link>https://dev.to/bitcapulet</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%2F266993%2Ff169dadd-799a-4f12-9ee0-8efc496fa185.jpg</url>
      <title>DEV Community: Adrian P. Dunston</title>
      <link>https://dev.to/bitcapulet</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/bitcapulet"/>
    <language>en</language>
    <item>
      <title>An Ode to My Favorite Line of Elixir !</title>
      <dc:creator>Adrian P. Dunston</dc:creator>
      <pubDate>Wed, 29 Jul 2020 16:00:11 +0000</pubDate>
      <link>https://dev.to/papa/an-ode-to-favorite-line-of-elixir-319p</link>
      <guid>https://dev.to/papa/an-ode-to-favorite-line-of-elixir-319p</guid>
      <description>&lt;p&gt;Gather around, and I'll tell you the tale of my favorite line of code&lt;/p&gt;

&lt;p&gt;A piece of advice, I thought it concise to bequeath in the form of an ode&lt;/p&gt;

&lt;p&gt;&lt;code&gt;|&amp;gt; IO.inspect(label: "!!ADRIAN #{__ENV__.file}:#{__ENV__.line}", pretty: true)&lt;/code&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  Pipes
&lt;/h1&gt;

&lt;p&gt;We'll start with a pipe &lt;code&gt;|&amp;gt;&lt;/code&gt; a wondrous device, feeds one call's return to another&lt;/p&gt;

&lt;p&gt;Without such a token, our code would look broken, its calls piled up in a smother.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight elixir"&gt;&lt;code&gt;&lt;span class="n"&gt;text_of_poem&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s2"&gt;"One fish&lt;/span&gt;&lt;span class="se"&gt;\n&lt;/span&gt;&lt;span class="s2"&gt;Two fish&lt;/span&gt;&lt;span class="se"&gt;\n&lt;/span&gt;&lt;span class="s2"&gt;Red fish&lt;/span&gt;&lt;span class="se"&gt;\n&lt;/span&gt;&lt;span class="s2"&gt;Blue fish"&lt;/span&gt;

&lt;span class="c1"&gt;# Without pipes&lt;/span&gt;
&lt;span class="no"&gt;Enum&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;count&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="no"&gt;String&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;split&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;text_of_poem&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="se"&gt;\n&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt;

&lt;span class="c1"&gt;# ==&amp;gt; 4&lt;/span&gt;

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



&lt;p&gt;First argument in, next function begins; you can see at a glance it looks cleaner&lt;/p&gt;

&lt;p&gt;Make functions designed with piped-calls in mind; Your test suite is sure to run greener&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight elixir"&gt;&lt;code&gt;&lt;span class="c1"&gt;# With pipes&lt;/span&gt;
&lt;span class="n"&gt;text_of_poem&lt;/span&gt;
&lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;String&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;split&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="se"&gt;\n&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;Enum&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;count&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

&lt;span class="c1"&gt;# ==&amp;gt; 4&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



&lt;h1&gt;
  
  
  Inspect
&lt;/h1&gt;

&lt;p&gt;Now let us reflect on humble &lt;code&gt;inspect/2&lt;/code&gt;, a device indescribably lucid&lt;/p&gt;

&lt;p&gt;If your bug's a big stinker that's stuck in your thinker, &lt;code&gt;inspect/2&lt;/code&gt; makes it jump as if goose-ed&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight elixir"&gt;&lt;code&gt;&lt;span class="c1"&gt;# Convert data structure to readable string&lt;/span&gt;
&lt;span class="n"&gt;quoth&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;%{&lt;/span&gt;&lt;span class="ss"&gt;raven:&lt;/span&gt; &lt;span class="s2"&gt;"nevermore"&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="n"&gt;inspect&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;quoth&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="c1"&gt;# ==&amp;gt; "%{raven: \"nevermore\"}"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



&lt;p&gt;&lt;code&gt;inspect/2&lt;/code&gt; by itself is more than a help, it converts any data to string form&lt;/p&gt;

&lt;p&gt;And with option &lt;code&gt;pretty&lt;/code&gt;, the output's less bitty; Your brain has more room for a brainstorm&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight elixir"&gt;&lt;code&gt;&lt;span class="n"&gt;quoth&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;%{&lt;/span&gt;&lt;span class="ss"&gt;raven:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="s2"&gt;"nevermore"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s2"&gt;"nevermore"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s2"&gt;"nevermore"&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt; 
    &lt;span class="ss"&gt;poe:&lt;/span&gt; &lt;span class="s2"&gt;"Take thy form from off my door!"&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="n"&gt;inspect&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;quoth&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;IO&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;puts&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

&lt;span class="c1"&gt;# 👀%{poe: "Take thy form from off my door!", raven: ["nevermore", "nevermore", "nevermore"]}&lt;/span&gt;
&lt;span class="c1"&gt;# ==&amp;gt; :ok&lt;/span&gt;

&lt;span class="c1"&gt;# The pretty: true option gives us more readable spacing.&lt;/span&gt;
&lt;span class="n"&gt;inspect&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;quoth&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="o"&gt;**&lt;/span&gt;&lt;span class="ss"&gt;pretty:&lt;/span&gt; &lt;span class="no"&gt;true&lt;/span&gt;&lt;span class="o"&gt;**&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;IO&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;puts&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

&lt;span class="c1"&gt;# 👀%{&lt;/span&gt;
&lt;span class="c1"&gt;#    poe: "Take thy form from off my door!",&lt;/span&gt;
&lt;span class="c1"&gt;#    raven: ["nevermore", "nevermore", "nevermore"]&lt;/span&gt;
&lt;span class="c1"&gt;#   }&lt;/span&gt;
&lt;span class="c1"&gt;# ==&amp;gt; :ok&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



&lt;h1&gt;
  
  
  IO.inspect
&lt;/h1&gt;

&lt;p&gt;&lt;code&gt;IO.inspect/2&lt;/code&gt; has dual effects, first it needs not a &lt;code&gt;puts/1&lt;/code&gt; to be candid,&lt;/p&gt;

&lt;p&gt;The second more subtle, not run in a bubble, this function returns what it's handed&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight elixir"&gt;&lt;code&gt;&lt;span class="no"&gt;IO&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;inspect&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="kn"&gt;quote&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="c1"&gt;# 👀%{raven: "nevermore"}&lt;/span&gt;
&lt;span class="c1"&gt;# ==&amp;gt; %{raven: "nevermore"}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;





&lt;div class="highlight"&gt;&lt;pre class="highlight elixir"&gt;&lt;code&gt;&lt;span class="c1"&gt;# Inspection without interference!&lt;/span&gt;
&lt;span class="n"&gt;text_of_poem&lt;/span&gt;
&lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;String&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;split&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="se"&gt;\n&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;IO&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;inspect&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
&lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;Enum&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;count&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

&lt;span class="c1"&gt;# 👀["One fish", "Two fish", "Red fish", "Blue fish"]&lt;/span&gt;
&lt;span class="c1"&gt;# ==&amp;gt; 4&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



&lt;p&gt;Now let's look at &lt;code&gt;:label&lt;/code&gt;; It's part of the stable of options &lt;code&gt;inspect/2&lt;/code&gt; can make use of&lt;/p&gt;

&lt;p&gt;ID your inspections for further reflection on whatever info's elusive&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight elixir"&gt;&lt;code&gt;&lt;span class="n"&gt;text_of_poem&lt;/span&gt;
&lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;IO&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;inspect&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="ss"&gt;label:&lt;/span&gt; &lt;span class="s2"&gt;"Before split"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;String&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;split&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="se"&gt;\n&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;IO&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;inspect&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="ss"&gt;label:&lt;/span&gt; &lt;span class="s2"&gt;"After split"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;Enum&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;count&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

&lt;span class="c1"&gt;# 👀Before split: "One fish\nTwo fish\nRed fish\nBlue fish"&lt;/span&gt;
&lt;span class="c1"&gt;# 👀After split: ["One fish", "Two fish", "Red fish", "Blue fish"]&lt;/span&gt;
&lt;span class="c1"&gt;# ==&amp;gt; 4&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



&lt;h1&gt;
  
  
  Calling Card
&lt;/h1&gt;

&lt;p&gt;Now &lt;code&gt;IO.inspect\2&lt;/code&gt;'s not a thing to forget when your feature is primed for submission,&lt;/p&gt;

&lt;p&gt;When you &lt;strong&gt;fit-and-finish&lt;/strong&gt;, prestige will diminish with inspect lines as part of commission&lt;/p&gt;

&lt;p&gt;Remind to remove and avoid such reprove with &lt;strong&gt;calling-card&lt;/strong&gt; text you're alert to&lt;/p&gt;

&lt;p&gt;Make it unique, add your mystique, and before you commit do a search-through&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight elixir"&gt;&lt;code&gt;&lt;span class="c1"&gt;#!!ADRIAN - debug lines easier to spot in console&lt;/span&gt;
&lt;span class="c1"&gt;# Remember to grep and remove !!ADRIAN lines before you push&lt;/span&gt;

&lt;span class="n"&gt;text_of_poem&lt;/span&gt;
&lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;IO&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;inspect&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="ss"&gt;label:&lt;/span&gt; &lt;span class="s2"&gt;"!!ADRIAN Before split"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;String&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;split&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="se"&gt;\n&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;IO&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;inspect&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="ss"&gt;label:&lt;/span&gt; &lt;span class="s2"&gt;"!!ADRIAN After split"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;Enum&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;count&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

&lt;span class="c1"&gt;# 👀!!ADRIAN Before split: "One fish\nTwo fish\nRed fish\nBlue fish"&lt;/span&gt;
&lt;span class="c1"&gt;# 👀!!ADRIAN After split: ["One fish", "Two fish", "Red fish", "Blue fish"]&lt;/span&gt;
&lt;span class="c1"&gt;# ==&amp;gt; 4&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



&lt;h1&gt;
  
  
  ENV file and line
&lt;/h1&gt;

&lt;p&gt;Final reflection on one-line perfection confesses the fact that I'm slothful.&lt;/p&gt;

&lt;p&gt;It feels such a bother, each label to author; is cutting and pasting so awful?&lt;/p&gt;

&lt;p&gt;Now in walks dear &lt;code&gt;ENV&lt;/code&gt;, our quite astute friend; she knows both the file and line number&lt;/p&gt;

&lt;p&gt;With this pal in hand, inspect can be canned; and attention advance unencumbered&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight elixir"&gt;&lt;code&gt;&lt;span class="mi"&gt;1&lt;/span&gt;  &lt;span class="n"&gt;text_of_poem&lt;/span&gt;
&lt;span class="mi"&gt;2&lt;/span&gt;  &lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;IO&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;inspect&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="ss"&gt;label:&lt;/span&gt; &lt;span class="s2"&gt;"!!ADRIAN &lt;/span&gt;&lt;span class="si"&gt;#{&lt;/span&gt;&lt;span class="n"&gt;__ENV__&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;file&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;:&lt;/span&gt;&lt;span class="si"&gt;#{&lt;/span&gt;&lt;span class="n"&gt;__ENV__&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;line&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="ss"&gt;pretty:&lt;/span&gt; &lt;span class="no"&gt;true&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="mi"&gt;3&lt;/span&gt;  &lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;String&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;split&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="se"&gt;\n&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="mi"&gt;4&lt;/span&gt;  &lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;IO&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;inspect&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="ss"&gt;label:&lt;/span&gt; &lt;span class="s2"&gt;"!!ADRIAN &lt;/span&gt;&lt;span class="si"&gt;#{&lt;/span&gt;&lt;span class="n"&gt;__ENV__&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;file&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;:&lt;/span&gt;&lt;span class="si"&gt;#{&lt;/span&gt;&lt;span class="n"&gt;__ENV__&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;line&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="ss"&gt;pretty:&lt;/span&gt; &lt;span class="no"&gt;true&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="mi"&gt;5&lt;/span&gt;  &lt;span class="o"&gt;|&amp;gt;&lt;/span&gt; &lt;span class="no"&gt;Enum&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;count&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

&lt;span class="c1"&gt;# 👀!!ADRIAN example.ex:2: "One fish\nTwo fish\nRed fish\nBlue fish"&lt;/span&gt;
&lt;span class="c1"&gt;# 👀!!ADRIAN example.ex:4: ["One fish", "Two fish", "Red fish", "Blue fish"]&lt;/span&gt;
&lt;span class="c1"&gt;# ==&amp;gt; 4&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



&lt;h1&gt;
  
  
  Coda - Clipboard Extension Tools
&lt;/h1&gt;

&lt;p&gt;I hope you've admired this line so inspired by the folks who have taught me before,&lt;/p&gt;

&lt;p&gt;And with your indulgence, I've one more divulgence, a quirk that can quickly be yours&lt;/p&gt;

&lt;p&gt;Clipboard extension is carapal prevention; it works by saving you typing&lt;/p&gt;

&lt;p&gt;Along with your copies, it pastes pre-typed drop-ins, so coding continues like lightning!&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight"&gt;&lt;pre class="highlight markdown"&gt;&lt;code&gt;Ditto Clipboard Extension for Windows
https://www.microsoft.com/en-us/p/ditto-clipboard/9nblggh3zbjq

Clipy Clipboard Extension for Mac
https://github.com/Clipy/Clipy
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;



</description>
    </item>
    <item>
      <title>Have a Calling Card - Putting your personal stamp on things left undone</title>
      <dc:creator>Adrian P. Dunston</dc:creator>
      <pubDate>Mon, 27 Jul 2020 14:08:35 +0000</pubDate>
      <link>https://dev.to/papa/have-a-calling-card-putting-your-personal-stamp-on-things-left-undone-lk8</link>
      <guid>https://dev.to/papa/have-a-calling-card-putting-your-personal-stamp-on-things-left-undone-lk8</guid>
      <description>&lt;p&gt;When I'm writing/changing software, and I write something that I know I don't want to go out to production, I put a comment with the string &lt;code&gt;!!ADRIAN&lt;/code&gt; in it. Before I commit/push/deploy (depending on the situation), I do a full-text-search for that string. Wherever I find it, I fix it.&lt;/p&gt;

&lt;p&gt;This has improved my life in ways beyond measure. It's easy to understand and easy to do, so it's one of the first pieces of advice I give to newer programmers: &lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Invent a personal calling card&lt;/li&gt;
&lt;li&gt;Leave it as a comment wherever you are leaving something unfinished&lt;/li&gt;
&lt;li&gt;Search for it before you turn in your work&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Why?
&lt;/h2&gt;

&lt;p&gt;So you finish what you intend to. The ability to &lt;strong&gt;make your intentions real in the world&lt;/strong&gt; is the definition of power. Software is complicated. Your mind (while very impressive) is limited. We use tools to leverage the power of our mind. This simple tool gives you more power over software.&lt;/p&gt;

&lt;h2&gt;
  
  
  How?
&lt;/h2&gt;

&lt;p&gt;Pick something unique to you. &lt;code&gt;TODO&lt;/code&gt; doesn't cut it. You'll probably be working in a team soon (if not already). &lt;code&gt;TODO&lt;/code&gt; is everyone's responsibility, &lt;strong&gt;so it's no one's responsibility&lt;/strong&gt;. &lt;code&gt;!!ADRIAN&lt;/code&gt; claims something as my responsibility. I'm generally the only Adrian on a team. Pick something that no one else will use. When I suggested this to a colleague, he immediately started using 🚨. Brilliant. I would never have thought of that. (I'm still not used to the fact that my editor understand emoji.) If someone else starts using it, my colleague may want to put his initials on it, but &lt;strong&gt;let's not go solving tomorrow's problems&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Pick something agreeable. &lt;strong&gt;Agreeability is not always the right choice&lt;/strong&gt;, but here it is. Sometimes you'll forget to search. Seeing your calling-card in production code will be mildly embarrassing, and that's fine. We &lt;strong&gt;develop with our feelings&lt;/strong&gt;. You don't want to exacerbate that by having a calling card that is additionally embarrassing. In general, &lt;strong&gt;don't write swears&lt;/strong&gt;, and try to &lt;strong&gt;keep it positive&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Pick something that indicates a problem. Seeing &lt;code&gt;!!&lt;/code&gt; , it's easy for other developers to infer that the comment indicates something is wrong or unfinished. 🚨 accomplishes the same thing.&lt;/p&gt;

&lt;p&gt;Pick something easy to write. My fingers type &lt;code&gt;#!!ADRIAN&lt;/code&gt; automatically now. It's also in certain debug lines I'm always pasting in. My colleague knows how to make an 🚨 appear with a few keystrokes. You may want to use a &lt;strong&gt;clipboard manager&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Do the search at the end. I encourage you to &lt;strong&gt;have an actual checklist&lt;/strong&gt; you run through before turning in any work. I have a checklist for &lt;strong&gt;fit and finish&lt;/strong&gt;. It includes searching for &lt;code&gt;#!!ADRIAN&lt;/code&gt; and &lt;code&gt;@tag :wip&lt;/code&gt;, two artifacts I often leave behind in Elixir development. Your checklist is up to you, but I recommend having one, and I recommend "search for calling card" be on it.&lt;/p&gt;

&lt;h2&gt;
  
  
  What about the rest of the team?
&lt;/h2&gt;

&lt;p&gt;You use this tool. See if it works for you. If so, suggest it to your closest teammates and then to the rest of the team. Socializing tools helps those around you, and &lt;strong&gt;teaching helps you learn&lt;/strong&gt;. But ultimately, this is an individual tool. It will help you regardless of who else adopts it.&lt;/p&gt;

&lt;h2&gt;
  
  
  What about you?
&lt;/h2&gt;

&lt;p&gt;Thanks for reading. If you start using this or have been, I'd love to hear it. Feel free to reach out and let me know your calling card or any fun stories from leaving one behind.&lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
