<?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: Thrijith Thankachan</title>
    <description>The latest articles on DEV Community by Thrijith Thankachan (@thrijith).</description>
    <link>https://dev.to/thrijith</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%2F424867%2Fa90d1f99-b0f2-4b3e-94fa-0f3d5bf19738.jpeg</url>
      <title>DEV Community: Thrijith Thankachan</title>
      <link>https://dev.to/thrijith</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/thrijith"/>
    <language>en</language>
    <item>
      <title>Utility tools to boost your command line experience</title>
      <dc:creator>Thrijith Thankachan</dc:creator>
      <pubDate>Sat, 25 Jul 2020 18:45:15 +0000</pubDate>
      <link>https://dev.to/thrijith/utility-tools-to-boost-your-command-line-experience-5ble</link>
      <guid>https://dev.to/thrijith/utility-tools-to-boost-your-command-line-experience-5ble</guid>
      <description>&lt;p&gt;If you are a programmer, you may spend a good amount of time on the command line. Here is a small set of utility tools which have helped me.&lt;/p&gt;

&lt;h4&gt;
  
  
  &lt;code&gt;bat&lt;/code&gt; command
&lt;/h4&gt;

&lt;p&gt;You may have come across the &lt;a href="https://man7.org/linux/man-pages/man1/cat.1.html" rel="noopener noreferrer"&gt;cat&lt;/a&gt; command, which helps you in viewing the contents of a file.&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%2Fawp.thrijith.com%2Fwp-content%2Fuploads%2F2020%2F07%2Fcat_command_demo.gif" 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%2Fawp.thrijith.com%2Fwp-content%2Fuploads%2F2020%2F07%2Fcat_command_demo.gif" alt="cat command preview"&gt;&lt;/a&gt;&lt;code&gt;cat&lt;/code&gt; command preview&lt;/p&gt;

&lt;p&gt;It certainly is very helpful, but what if we could make it better? Enter the &lt;code&gt;bat&lt;/code&gt; command, or as described on its repository &lt;strong&gt;A cat(1) clone with wings.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The command really does add wings to the &lt;code&gt;cat&lt;/code&gt; command, &lt;code&gt;bat&lt;/code&gt; supports syntax highlighting for a large number of programming and markup languages, integration with git and automatic paging if the content doesn’t fit on your screen, here is a preview of the command.&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%2Fawp.thrijith.com%2Fwp-content%2Fuploads%2F2020%2F07%2Fbat_command_demo.gif" 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%2Fawp.thrijith.com%2Fwp-content%2Fuploads%2F2020%2F07%2Fbat_command_demo.gif" alt="bat command preview"&gt;&lt;/a&gt;&lt;code&gt;bat&lt;/code&gt; command preview&lt;/p&gt;

&lt;p&gt;Installation instructions can be found &lt;a href="https://dev.to/scottw/bat-57pg-temp-slug-2229370"&gt;here&lt;/a&gt;, take it on a test drive! If you find this useful, you can alias the &lt;code&gt;bat&lt;/code&gt; command for &lt;code&gt;cat&lt;/code&gt; and make it your default way of viewing file contents.&lt;/p&gt;

&lt;p&gt;Overriding the cat command using alias :  &lt;/p&gt;

&lt;p&gt;&lt;code&gt;alias cat='bat'&lt;/code&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  &lt;code&gt;fzf&lt;/code&gt; fuzzy finder
&lt;/h4&gt;

&lt;p&gt;If you are lazy and looking to run commands you ran earlier but don’t exactly recall the exact usage, you must have done a &lt;code&gt;Ctrl+R&lt;/code&gt; to search through history, &lt;code&gt;fzf&lt;/code&gt; enhances this and gives you a preview, here is the command in action.&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%2Fawp.thrijith.com%2Fwp-content%2Fuploads%2F2020%2F07%2Ffzf.gif" 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%2Fawp.thrijith.com%2Fwp-content%2Fuploads%2F2020%2F07%2Ffzf.gif"&gt;&lt;/a&gt;&lt;code&gt;fzf&lt;/code&gt; preview&lt;/p&gt;

&lt;p&gt;Installation instructions can be found &lt;a href="https://github.com/junegunn/fzf" rel="noopener noreferrer"&gt;here&lt;/a&gt;, you can also use &lt;code&gt;fzf&lt;/code&gt; to preview files in a directory by combining it with &lt;code&gt;bat&lt;/code&gt;, for a quick preview.&lt;/p&gt;

&lt;p&gt;Alias for &lt;code&gt;fzf&lt;/code&gt; + &lt;code&gt;bat&lt;/code&gt; preview :  &lt;/p&gt;

&lt;p&gt;&lt;code&gt;alias preview="fzf --preview 'bat {}'"&lt;/code&gt;&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%2Fawp.thrijith.com%2Fwp-content%2Fuploads%2F2020%2F07%2Fpreview.gif" 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%2Fawp.thrijith.com%2Fwp-content%2Fuploads%2F2020%2F07%2Fpreview.gif" alt="command combination alias preview"&gt;&lt;/a&gt;&lt;code&gt;fzf&lt;/code&gt; + &lt;code&gt;bat&lt;/code&gt; alias preview&lt;/p&gt;

&lt;p&gt;That’s about it for now, I hope this helps!&lt;/p&gt;

</description>
      <category>utility</category>
      <category>cli</category>
      <category>zsh</category>
      <category>bash</category>
    </item>
    <item>
      <title>The Headless WordPress Experience with Frontity</title>
      <dc:creator>Thrijith Thankachan</dc:creator>
      <pubDate>Mon, 06 Jul 2020 05:22:14 +0000</pubDate>
      <link>https://dev.to/thrijith/the-headless-wordpress-experience-with-frontity-505m</link>
      <guid>https://dev.to/thrijith/the-headless-wordpress-experience-with-frontity-505m</guid>
      <description>&lt;p&gt;Ever since I came to know about the possibility of a headless setup for WordPress, I have always been tempted to try it out.&lt;/p&gt;

&lt;p&gt;I tested out a simple setup based on &lt;a href="https://nextjs.org/"&gt;Next.JS&lt;/a&gt; on my local setup, before going ahead with &lt;a href="https://frontity.org/"&gt;Frontity&lt;/a&gt; on my blog with high traffic, which now has 2 posts counting this one 😅&lt;/p&gt;

&lt;p&gt;You can check out the simple implementation here &lt;a href="https://github.com/thrijith/headless-wp"&gt;https://github.com/thrijith/headless-wp&lt;/a&gt; which is based on this &lt;a href="https://webdevstudios.com/2019/01/03/headless-wordpress-with-react-and-nextjs-1/"&gt;https://webdevstudios.com/2019/01/03/headless-wordpress-with-react-and-nextjs-1/&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The setup is pretty straightforward you may follow &lt;a href="https://docs.frontity.org/getting-started/quick-start-guide"&gt;this&lt;/a&gt;, to get started.&lt;/p&gt;

&lt;p&gt;Run &lt;code&gt;npx frontity create mysite-frontity-app &amp;amp;&amp;amp; cd mysite-frontity-app&lt;/code&gt; select your desired theme and it will create a starter setup for your Forntiy app, run &lt;code&gt;npx frontity dev&lt;/code&gt;, to launch the app, it will use a demo site to get the posts data for your newly created site.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--oC0iWNHU--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://awp.thrijith.com/wp-content/uploads/2020/04/image-1-1024x333.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--oC0iWNHU--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://awp.thrijith.com/wp-content/uploads/2020/04/image-1-1024x333.png" alt="" class="wp-image-126"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Go ahead and edit &lt;strong&gt;frontity.settings.js&lt;/strong&gt; and point &lt;strong&gt;@frontity/wp-source&lt;/strong&gt; =&amp;gt; &lt;strong&gt;api&lt;/strong&gt; field to your WordPress site, run &lt;code&gt;npx frontity dev&lt;/code&gt; again you should now see posts from your site instead of data from the demo site.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--JXXqsQ5T--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://awp.thrijith.com/wp-content/uploads/2020/04/image-2-1024x572.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--JXXqsQ5T--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://awp.thrijith.com/wp-content/uploads/2020/04/image-2-1024x572.png" alt="" class="wp-image-127"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h4&gt;
  
  
  Deploying your site in Vercel
&lt;/h4&gt;

&lt;p&gt;Frontity has a dedicated section which covers the deployment on &lt;a href="https://docs.frontity.org/deployment/deploy-on-now"&gt;Vercel&lt;/a&gt; ( Previously Zeit )&lt;/p&gt;

&lt;p&gt;Once your app is set up correctly, it will be visible in your Vercel Dashboard, it will create a random URL for your site, you can test your site there.&lt;/p&gt;



&lt;p&gt;You can also set a custom domain for your site, settings for the same can be found under Project =&amp;gt; Settings =&amp;gt; Domains, you'll also have to set up an ALIAS record to point your custom domain.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--h7S3m7J5--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://awp.thrijith.com/wp-content/uploads/2020/04/Domains-thrijith-frontity-app-Vercel-2020-04-28-12-58-02.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--h7S3m7J5--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://awp.thrijith.com/wp-content/uploads/2020/04/Domains-thrijith-frontity-app-Vercel-2020-04-28-12-58-02.png" alt="" class="wp-image-129"&gt;&lt;/a&gt;Settings Page&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--24QXiQPQ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://awp.thrijith.com/wp-content/uploads/2020/04/Screenshot-2020-04-28-at-1.01.50-PM.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--24QXiQPQ--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://awp.thrijith.com/wp-content/uploads/2020/04/Screenshot-2020-04-28-at-1.01.50-PM.png" alt="" class="wp-image-130"&gt;&lt;/a&gt;Sample ALIAS record in &lt;a href="https://porkbun.com/"&gt;&lt;/a&gt;&lt;a href="https://porkbun.com/"&gt;https://porkbun.com/&lt;/a&gt; ( My domain registrar )&lt;/p&gt;

&lt;p&gt;Please note it may take a couple of hours to reflect the change.&lt;/p&gt;

</description>
      <category>wordpress</category>
      <category>frontity</category>
      <category>headless</category>
      <category>vercel</category>
    </item>
  </channel>
</rss>
