<?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>Forem: Aiyah Bungthong</title>
    <description>The latest articles on Forem by Aiyah Bungthong (@aybun).</description>
    <link>https://forem.com/aybun</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%2F3087232%2F972cb876-0e80-4588-852a-eaa0636194a7.jpg</url>
      <title>Forem: Aiyah Bungthong</title>
      <link>https://forem.com/aybun</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/aybun"/>
    <language>en</language>
    <item>
      <title>Django Rest framework : The End</title>
      <dc:creator>Aiyah Bungthong</dc:creator>
      <pubDate>Wed, 28 May 2025 10:23:52 +0000</pubDate>
      <link>https://forem.com/aybun/django-rest-framework-the-end-4lnk</link>
      <guid>https://forem.com/aybun/django-rest-framework-the-end-4lnk</guid>
      <description>&lt;p&gt;I finished my first series ever! You can check it out here. Don't hesitate to leave me some feedback. Thanks!!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://blog.aybun.co/drf-intro-series.html" rel="noopener noreferrer"&gt;https://blog.aybun.co/drf-intro-series.html&lt;/a&gt;&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>django</category>
      <category>beginners</category>
      <category>python</category>
    </item>
    <item>
      <title>Django Rest framework Now EP01: Poetry</title>
      <dc:creator>Aiyah Bungthong</dc:creator>
      <pubDate>Thu, 01 May 2025 14:12:16 +0000</pubDate>
      <link>https://forem.com/aybun/django-rest-framework-now-ep01-poetry-5e24</link>
      <guid>https://forem.com/aybun/django-rest-framework-now-ep01-poetry-5e24</guid>
      <description>&lt;p&gt;If you Have any suggestions, please let me know. Thanks!!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://blog.aybun.co/drf-1.html" rel="noopener noreferrer"&gt;https://blog.aybun.co/drf-1.html&lt;/a&gt;&lt;/p&gt;

</description>
      <category>django</category>
      <category>restapi</category>
      <category>webdev</category>
      <category>python</category>
    </item>
    <item>
      <title>A short tutorial on using fish shell.</title>
      <dc:creator>Aiyah Bungthong</dc:creator>
      <pubDate>Fri, 25 Apr 2025 05:11:13 +0000</pubDate>
      <link>https://forem.com/aybun/a-short-tutorial-on-using-fish-shell-eml</link>
      <guid>https://forem.com/aybun/a-short-tutorial-on-using-fish-shell-eml</guid>
      <description>&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;To catch your attention, I could have named the title &lt;code&gt;X shell sucks&lt;/code&gt;, but that would piss people off. A good blog post would compare at least 2 similar things to get a clear picture, but to be honest, I don't use other shells. So, I can't help but explain only the usage of fish. Now, let's catch some fish.&lt;/p&gt;

&lt;h2&gt;
  
  
  Installation
&lt;/h2&gt;

&lt;p&gt;Follow &lt;a href="https://fishshell.com/" rel="noopener noreferrer"&gt;this&lt;/a&gt; to install. Note that this tutorial assume that you are on Linux.&lt;/p&gt;

&lt;h2&gt;
  
  
  Making binaries available in fish shell
&lt;/h2&gt;

&lt;p&gt;Suppose that you want to expose binaries from a directory to fish shell. &lt;/p&gt;

&lt;p&gt;Edit the &lt;code&gt;~/.config/fish/config.fish&lt;/code&gt; file by adding&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;fish_add_path &amp;lt;your_directory_path&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then restart the shell to make it work.&lt;/p&gt;

&lt;h2&gt;
  
  
  Function calls in fish shell
&lt;/h2&gt;

&lt;p&gt;The syntax of a function declaration is the following:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;function_name&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;

&lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;function_body&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt;

&lt;span class="nx"&gt;end&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Suppose that we want to make an alias of the Vlang binary. Add the following lines to &lt;code&gt;~/.config/fish/config.fish&lt;/code&gt; :&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight javascript"&gt;&lt;code&gt;&lt;span class="err"&gt;#&lt;/span&gt; &lt;span class="nx"&gt;This&lt;/span&gt; &lt;span class="nx"&gt;is&lt;/span&gt; &lt;span class="nx"&gt;a&lt;/span&gt; &lt;span class="nx"&gt;comment&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;
&lt;span class="kd"&gt;function&lt;/span&gt; &lt;span class="nf"&gt;vv&lt;/span&gt;

&lt;span class="err"&gt;#&lt;/span&gt; &lt;span class="nx"&gt;Syntax&lt;/span&gt; &lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="o"&gt;&amp;lt;&lt;/span&gt;&lt;span class="nx"&gt;path_to_bin&lt;/span&gt;&lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="nx"&gt;$argv&lt;/span&gt;
&lt;span class="o"&gt;~&lt;/span&gt;&lt;span class="sr"&gt;/tools/&lt;/span&gt;&lt;span class="nx"&gt;v&lt;/span&gt;&lt;span class="o"&gt;/&lt;/span&gt;&lt;span class="nx"&gt;v&lt;/span&gt; &lt;span class="nx"&gt;$argv&lt;/span&gt;

&lt;span class="nx"&gt;end&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now, we can use &lt;code&gt;vv&lt;/code&gt; as an alias, where &lt;code&gt;$argv&lt;/code&gt; represents function arguments.&lt;/p&gt;

&lt;p&gt;Note that we need to restart the fish shell.&lt;/p&gt;

&lt;h2&gt;
  
  
  Organizing custom scripts
&lt;/h2&gt;

&lt;p&gt;As our config.fish grows, we may want to tidy things up to calm down our background anxiety.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;We can create a directory named &lt;code&gt;cust&lt;/code&gt; (the name does not matter) inside &lt;code&gt;~/.config/fish/&lt;/code&gt;.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Then &lt;code&gt;cd&lt;/code&gt; into &lt;code&gt;cust&lt;/code&gt; and create a file named &lt;code&gt;custom.fish&lt;/code&gt;.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;After that, we move our custom script there.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Finally, add the following line to &lt;code&gt;config.fish&lt;/code&gt; :&lt;br&gt;
&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;source ~/.config/fish/cust/custom.fish
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Themes
&lt;/h2&gt;

&lt;p&gt;The research showed that bad themes reduce programmers' productivity by 123.456%. &lt;/p&gt;

&lt;p&gt;Use &lt;a href="https://ohmyposh.dev/" rel="noopener noreferrer"&gt;oh-my-posh&lt;/a&gt; to make your terminal cute. &lt;/p&gt;

&lt;p&gt;Don't forget to config nerd font for the terminal!!&lt;/p&gt;

&lt;h2&gt;
  
  
  Before you go
&lt;/h2&gt;

&lt;p&gt;This is my first blog post. If you have any suggestions, &lt;em&gt;never&lt;/em&gt; hesitate to let me know. Thank you for your &lt;code&gt;attention&lt;/code&gt;.&lt;/p&gt;

</description>
      <category>shell</category>
      <category>linux</category>
      <category>beginners</category>
      <category>cli</category>
    </item>
  </channel>
</rss>
