<?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: ૮༼⚆︿⚆༽つ</title>
    <description>The latest articles on DEV Community by ૮༼⚆︿⚆༽つ (@drsensor).</description>
    <link>https://dev.to/drsensor</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%2F75992%2Fb0233562-0b58-4efd-9b83-0f508a94eb6c.png</url>
      <title>DEV Community: ૮༼⚆︿⚆༽つ</title>
      <link>https://dev.to/drsensor</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/drsensor"/>
    <language>en</language>
    <item>
      <title>List of helpful FFMPEG command for checking capabilities</title>
      <dc:creator>૮༼⚆︿⚆༽つ</dc:creator>
      <pubDate>Thu, 11 Mar 2021 08:07:11 +0000</pubDate>
      <link>https://dev.to/drsensor/list-of-helpful-ffmpeg-command-for-checking-capabilities-1110</link>
      <guid>https://dev.to/drsensor/list-of-helpful-ffmpeg-command-for-checking-capabilities-1110</guid>
      <description>&lt;p&gt;A lot of FFMPEG options are not in the documentations and only available to the specific build, hardware acceleration, or codecs. So I need a list of commands on how to show and search all available settings and options.&lt;/p&gt;

&lt;h4&gt;
  
  
  1. List all possible options of &lt;code&gt;-filter_complex&lt;/code&gt; and &lt;code&gt;-vf&lt;/code&gt; filter graph
&lt;/h4&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ffmpeg &lt;span class="nt"&gt;-hide_banner&lt;/span&gt; &lt;span class="nt"&gt;-filters&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Filters:
 A = Audio input/output
 V = Video input/output
 N = Dynamic number and/or type of input/output
 | = Source or sink filter

 T.. = Timeline support
 .S. = Slice threading
 ..C = Command support
 ---
 ... filter_name            N-&amp;gt;N       Description.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h5&gt;
  
  
  1.2 Check filter details
&lt;/h5&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ffmpeg &lt;span class="nt"&gt;-hide_banner&lt;/span&gt; &lt;span class="nt"&gt;-h&lt;/span&gt; &lt;span class="nv"&gt;filter&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$fname&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Filter lowpass
  Description.
    Inputs:
       … (…)
    Outputs:
       … (…)
lowpass AVOptions:
  options         &amp;lt;type&amp;gt;     ..F....... Description (default or range value)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h4&gt;
  
  
  2. List all hardware acceleration
&lt;/h4&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ffmpeg &lt;span class="nt"&gt;-hide_banner&lt;/span&gt; &lt;span class="nt"&gt;-hwaccels&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Hardware acceleration methods:
vdpau
cuda
vaapi
qsv
drm
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h4&gt;
  
  
  3. List all encoders and/or decoders
&lt;/h4&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ffmpeg &lt;span class="nt"&gt;-hide_banner&lt;/span&gt; &lt;span class="nt"&gt;-encoders&lt;/span&gt;
ffmpeg &lt;span class="nt"&gt;-hide_banner&lt;/span&gt; &lt;span class="nt"&gt;-decoders&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Encoders/Decoders:
 V..... = Video
 A..... = Audio
 S..... = Subtitle
 .F.... = Frame-level multithreading
 ..S... = Slice-level multithreading
 ...X.. = Codec is experimental
 ....B. = Supports draw_horiz_band
 .....D = Supports direct rendering method 1
 ------
 ...... cname_hwaccel                 Description
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h5&gt;
  
  
  3.0 List all codecs
&lt;/h5&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ffmpeg &lt;span class="nt"&gt;-hide_banner&lt;/span&gt; &lt;span class="nt"&gt;-codecs&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Codecs:
 D..... = Decoding supported
 .E.... = Encoding supported
 ..V... = Video codec
 ..A... = Audio codec
 ..S... = Subtitle codec
 ...I.. = Intra frame-only codec
 ....L. = Lossy compression
 .....S = Lossless compression
 ------
 ...... cname_hwaccel                 Description
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h5&gt;
  
  
  3.1 Check encoders details
&lt;/h5&gt;

&lt;p&gt;(can list multiple encoders depend on hardware acceleration you have)&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ffmpeg &lt;span class="nt"&gt;-hide_banner&lt;/span&gt; &lt;span class="nt"&gt;-h&lt;/span&gt; &lt;span class="nv"&gt;encoder&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$cname_hwaccel&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Encoder libname [Description]:
    General capabilities: delay threads 
    Threading capabilities: auto
    Supported pixel formats: … … …
libname AVOptions:
  -option            &amp;lt;type&amp;gt;     .......... Description (default or range value)

 codec_name configuration using a :-separated list of key=value parameters


Encoder cname_hwaccel [Description]:
    General capabilities: delay hardware 
    Threading capabilities: none
    Supported hardware devices: …
    Supported pixel formats: … …
cname_hwaccel AVOptions:
  -option             &amp;lt;type&amp;gt;        E......... Description (default or range value)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h5&gt;
  
  
  3.2 Check decoder details
&lt;/h5&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ffmpeg &lt;span class="nt"&gt;-hide_banner&lt;/span&gt; &lt;span class="nt"&gt;-h&lt;/span&gt; &lt;span class="nv"&gt;decoder&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nv"&gt;$cname&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Decoder cname [Description]:
    General capabilities: dr1 delay threads 
    Threading capabilities: frame and slice
    Supported hardware devices: … … … 
cname Decoder AVOptions:
  -option         &amp;lt;type&amp;gt;    .D........ Description (default or range value)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



</description>
      <category>ffmpeg</category>
      <category>multimedia</category>
    </item>
    <item>
      <title>Rust is not panacea</title>
      <dc:creator>૮༼⚆︿⚆༽つ</dc:creator>
      <pubDate>Wed, 24 Feb 2021 09:25:38 +0000</pubDate>
      <link>https://dev.to/drsensor/rust-is-not-panacea-3g3e</link>
      <guid>https://dev.to/drsensor/rust-is-not-panacea-3g3e</guid>
      <description>&lt;p&gt;Just my personal list on when writing software in Rust become a problem.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Rust grievances&lt;br&gt;
&lt;a href="https://gist.github.com/brendanzab/d41c3ae485d66c07178749eaeeb9e5f7"&gt;https://gist.github.com/brendanzab/d41c3ae485d66c07178749eaeeb9e5f7&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;why esbuild written in Go&lt;br&gt;
&lt;a href="https://news.ycombinator.com/item?id=22336284"&gt;https://news.ycombinator.com/item?id=22336284&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;problem writing wayland compositor in Rust&lt;br&gt;
&lt;a href="http://way-cooler.org/blog/2020/01/09/way-cooler-post-mortem.html"&gt;http://way-cooler.org/blog/2020/01/09/way-cooler-post-mortem.html&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;switching to Rust can breaks things&lt;br&gt;
&lt;a href="https://drewdevault.com/2021/02/09/Rust-move-fast-and-break-things.html"&gt;https://drewdevault.com/2021/02/09/Rust-move-fast-and-break-things.html&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Zig vs Rust&lt;br&gt;
&lt;a href="https://scattered-thoughts.net/writing/assorted-thoughts-on-zig-and-rust/"&gt;https://scattered-thoughts.net/writing/assorted-thoughts-on-zig-and-rust/&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;unnecessary syscalls produced by Rust compiler&lt;br&gt;
&lt;a href="https://drewdevault.com/2020/01/08/Re-Slow.html"&gt;https://drewdevault.com/2020/01/08/Re-Slow.html&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Rust is faster than Javascript but mostly untrue when targeting web browser&lt;br&gt;
&lt;a href="https://zaplib.com/docs/blog_post_mortem.html"&gt;https://zaplib.com/docs/blog_post_mortem.html&lt;/a&gt;&lt;br&gt;
&lt;iframe class="tweet-embed" id="tweet-1520809822530142208-862" src="https://platform.twitter.com/embed/Tweet.html?id=1520809822530142208"&gt;
&lt;/iframe&gt;

  // Detect dark theme
  var iframe = document.getElementById('tweet-1520809822530142208-862');
  if (document.body.className.includes('dark-theme')) {
    iframe.src = "https://platform.twitter.com/embed/Tweet.html?id=1520809822530142208&amp;amp;theme=dark"
  }



&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;When Zig is safer and faster than Rust&lt;br&gt;
&lt;a href="https://zackoverflow.dev/writing/unsafe-rust-vs-zig/"&gt;https://zackoverflow.dev/writing/unsafe-rust-vs-zig/&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>rust</category>
      <category>rant</category>
    </item>
    <item>
      <title>Nix Multi-User Installation Without Default Channel</title>
      <dc:creator>૮༼⚆︿⚆༽つ</dc:creator>
      <pubDate>Wed, 03 Feb 2021 14:53:10 +0000</pubDate>
      <link>https://dev.to/drsensor/nix-multi-user-installation-without-default-channel-45nd</link>
      <guid>https://dev.to/drsensor/nix-multi-user-installation-without-default-channel-45nd</guid>
      <description>&lt;h1&gt;
  
  
  Why do this?
&lt;/h1&gt;

&lt;p&gt;Let's just say I want to restrict all users from polluting &lt;code&gt;/nix/store&lt;/code&gt; but still allow them to use Nix toolchains.&lt;/p&gt;

&lt;h1&gt;
  
  
  Installation
&lt;/h1&gt;


&lt;div class="ltag_asciinema"&gt;
  
&lt;/div&gt;


&lt;p&gt;fish&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sh (curl -L https://nixos.org/nix/install | psub) --daemon
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;zsh&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;sh &lt;span class="o"&gt;=(&lt;/span&gt;curl &lt;span class="nt"&gt;-L&lt;/span&gt; https://nixos.org/nix/install&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="nt"&gt;--daemon&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;bash&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;sh &amp;lt;&lt;span class="o"&gt;(&lt;/span&gt;curl &lt;span class="nt"&gt;-L&lt;/span&gt; https://nixos.org/nix/install&lt;span class="o"&gt;)&lt;/span&gt; &lt;span class="nt"&gt;--daemon&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;h1&gt;
  
  
  Replace channel
&lt;/h1&gt;

&lt;p&gt;When you list the channel in a normal way you will get an empty list.&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;nix-channel &lt;span class="nt"&gt;--list&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;However, when you run it as a superuser then you will see &lt;strong&gt;nixpkgs&lt;/strong&gt; channel.&lt;/p&gt;


&lt;div class="ltag_asciinema"&gt;
  
&lt;/div&gt;



&lt;p&gt;This channel is available to all users. Let's make this channel only accessible to you!&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Remove default channel
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;nix-channel &lt;span class="nt"&gt;--remove&lt;/span&gt; nixpkgs
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;div class="ltag_asciinema"&gt;
  
&lt;/div&gt;



&lt;h2&gt;
  
  
  2. Re-add channel
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;nix-channel &lt;span class="nt"&gt;--add&lt;/span&gt; https://nixos.org/channels/nixpkgs-unstable
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;div class="ltag_asciinema"&gt;
  
&lt;/div&gt;



&lt;h2&gt;
  
  
  3. Add yourself to the group
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;groupadd &lt;span class="nt"&gt;-r&lt;/span&gt; nixbld
&lt;span class="nb"&gt;sudo &lt;/span&gt;useradd &lt;span class="nt"&gt;-c&lt;/span&gt; &lt;span class="s2"&gt;"Nix build user &lt;/span&gt;&lt;span class="nv"&gt;$USER&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-d&lt;/span&gt; /var/empty &lt;span class="nt"&gt;-g&lt;/span&gt; nixbld &lt;span class="nt"&gt;-G&lt;/span&gt; nixbld &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-M&lt;/span&gt; &lt;span class="nt"&gt;-N&lt;/span&gt; &lt;span class="nt"&gt;-r&lt;/span&gt; &lt;span class="nt"&gt;-s&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="si"&gt;$(&lt;/span&gt;which nologin&lt;span class="si"&gt;)&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  nixbld_&lt;span class="nv"&gt;$USER&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;div class="ltag_asciinema"&gt;
  
&lt;/div&gt;



&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;For &lt;a href="http://fishshell.com/"&gt;fish&lt;/a&gt; user&lt;/strong&gt;: remove &lt;code&gt;"&lt;/code&gt; and &lt;code&gt;$&lt;/code&gt; so that it would be &lt;code&gt;(which nologin)&lt;/code&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  4. Update nix channel and toolchains
&lt;/h2&gt;

&lt;p&gt;To update channel&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;nix-channel &lt;span class="nt"&gt;--update&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;blockquote&gt;
&lt;p&gt;if you get a permission error and &lt;code&gt;sysemctl status nix-daemon&lt;/code&gt; has FAIL messages, try rebooting your system&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Optionally, upgrade all Nix toolchains&lt;br&gt;
&lt;/p&gt;
&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;nix-env &lt;span class="nt"&gt;-iA&lt;/span&gt; nixpkgs.nix nixpkgs.cacert
systemctl daemon-reload
systemctl restart nix-daemon
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;div class="ltag_asciinema"&gt;
  
&lt;/div&gt;



&lt;h2&gt;
  
  
  5. Fixing NIX_PATH
&lt;/h2&gt;


&lt;div class="ltag_github-liquid-tag"&gt;
  &lt;h1&gt;
    &lt;a href="https://github.com/NixOS/nix/issues/2033#issuecomment-744059453"&gt;
      &lt;img class="github-logo" alt="GitHub logo" src="https://res.cloudinary.com/practicaldev/image/fetch/s--A9-wwsHG--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev.to/assets/github-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg"&gt;
      &lt;span class="issue-title"&gt;
        Comment for
      &lt;/span&gt;
      &lt;span class="issue-number"&gt;#2033&lt;/span&gt;
    &lt;/a&gt;
  &lt;/h1&gt;
  &lt;div class="github-thread"&gt;
    &lt;div class="timeline-comment-header"&gt;
      &lt;a href="https://github.com/nathanshelly"&gt;
        &lt;img class="github-liquid-tag-img" src="https://res.cloudinary.com/practicaldev/image/fetch/s--nYb5uh5X--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://avatars.githubusercontent.com/u/9750687%3Fu%3Df4a76833563ce40ed1a86425d9f56ba814742383%26v%3D4" alt="nathanshelly avatar"&gt;
      &lt;/a&gt;
      &lt;div class="timeline-comment-header-text"&gt;
        &lt;strong&gt;
          &lt;a href="https://github.com/nathanshelly"&gt;nathanshelly&lt;/a&gt;
        &lt;/strong&gt; commented on &lt;a href="https://github.com/NixOS/nix/issues/2033#issuecomment-744059453"&gt;&lt;time&gt;Dec 13, 2020&lt;/time&gt;&lt;/a&gt;
      &lt;/div&gt;
    &lt;/div&gt;
    &lt;div class="ltag-github-body"&gt;
      &lt;p&gt;If I understand things correctly I believe your issues could be solved by adding the following line (which this issue is proposing should be included by default) to your &lt;code&gt;$HOME/.zshrc&lt;/code&gt; (or other startup file depending on your preferences):&lt;/p&gt;
&lt;div class="highlight highlight-source-shell js-code-highlight"&gt;
&lt;pre&gt;&lt;span class="pl-k"&gt;export&lt;/span&gt; NIX_PATH=&lt;span class="pl-smi"&gt;$NIX_PATH&lt;/span&gt;:&lt;span class="pl-smi"&gt;$HOME&lt;/span&gt;/.nix-defexpr/channels&lt;/pre&gt;

&lt;/div&gt;
&lt;p&gt;I'm still learning Nix myself so I don't have context on why that is not the default already. Let me know if that doesn't work and we can try to keep debugging things 😄&lt;/p&gt;

    &lt;/div&gt;
    &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/NixOS/nix/issues/2033#issuecomment-744059453"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
  &lt;/div&gt;
&lt;/div&gt;
&lt;br&gt;


&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"export NIX_PATH=&lt;/span&gt;&lt;span class="nv"&gt;$NIX_PATH&lt;/span&gt;&lt;span class="s2"&gt;:&lt;/span&gt;&lt;span class="nv"&gt;$HOME&lt;/span&gt;&lt;span class="s2"&gt;/.nix-defexpr/channels"&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&amp;gt;&lt;/span&gt; ~/.profile
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;


&lt;p&gt;(in my case, I add it to my .xprofile)&lt;/p&gt;

&lt;p&gt;if you don't do this, nix-shell will complain:&lt;br&gt;
&lt;/p&gt;
&lt;div class="ltag_asciinema"&gt;
  
&lt;/div&gt;



&lt;div class="ltag_github-liquid-tag"&gt;
  &lt;h1&gt;
    &lt;a href="https://github.com/NixOS/nix/issues/2033"&gt;
      &lt;img class="github-logo" alt="GitHub logo" src="https://res.cloudinary.com/practicaldev/image/fetch/s--A9-wwsHG--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://dev.to/assets/github-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg"&gt;
      &lt;span class="issue-title"&gt;
        Default Nix installations don't include user channels in NIX_PATH, causing inconsistent tool behavior
      &lt;/span&gt;
      &lt;span class="issue-number"&gt;#2033&lt;/span&gt;
    &lt;/a&gt;
  &lt;/h1&gt;
  &lt;div class="github-thread"&gt;
    &lt;div class="timeline-comment-header"&gt;
      &lt;a href="https://github.com/grahamc"&gt;
        &lt;img class="github-liquid-tag-img" src="https://res.cloudinary.com/practicaldev/image/fetch/s--AN_JGjOf--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://avatars.githubusercontent.com/u/76716%3Fv%3D4" alt="grahamc avatar"&gt;
      &lt;/a&gt;
      &lt;div class="timeline-comment-header-text"&gt;
        &lt;strong&gt;
          &lt;a href="https://github.com/grahamc"&gt;grahamc&lt;/a&gt;
        &lt;/strong&gt; posted on &lt;a href="https://github.com/NixOS/nix/issues/2033"&gt;&lt;time&gt;Apr 01, 2018&lt;/time&gt;&lt;/a&gt;
      &lt;/div&gt;
    &lt;/div&gt;
    &lt;div class="ltag-github-body"&gt;
      &lt;p&gt;Should Nix installations include &lt;code&gt;$HOME/.nix-defexpr/channels&lt;/code&gt; in the NIX_PATH? Should it appear before or after root channels?&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;nixpkgs=/nix/var/nix/profiles/per-user/root/channels/nixos/nixpkgs:nixos-config=/etc/nixos/configuration.nix:/nix/var/nix/profiles/per-user/root/channels

$ nix-channel --list             
nixpkgsunstable https://nixos.org/channels/nixpkgs-unstable

$ nix-env -iA nixpkgsunstable.git
installing 'git-minimal-2.16.2'

$ nix-shell -p nixpkgsunstable.git
error: undefined variable 'nixpkgsunstable' at (string):1:94
(use '--show-trace' to show detailed location information)

$ nix-shell '&amp;lt;nixpkgsunstable&amp;gt;' -p git
error: file 'nixpkgsunstable' was not found in the Nix search path (add it using $NIX_PATH or -I), at (string):1:94
(use '--show-trace' to show detailed location information)

$ nix-build '&amp;lt;nixpkgsunstable&amp;gt;' -A git
error: file 'nixpkgsunstable' was not found in the Nix search path (add it using $NIX_PATH or -I)

&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;vs:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;$ export NIX_PATH=$NIX_PATH:$HOME/.nix-defexpr/channels

$ nix-env -iA nixpkgsunstable.git    
replacing old 'git-minimal-2.16.2'
installing 'git-minimal-2.16.2'

$ nix-shell -p nixpkgsunstable.git    
error: undefined variable 'nixpkgsunstable' at (string):1:94
(use '--show-trace' to show detailed location information)

$ nix-shell '&amp;lt;nixpkgsunstable&amp;gt;' -p git

[nix-shell:~]$ exit

$ nix-build '&amp;lt;nixpkgsunstable&amp;gt;' -A git
/nix/store/jaani1kx4a4kvz11d0myfkjjiiklfl7w-git-2.16.2
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;With this configuration, and the explicitly specified nixpkgs, is it possible for users to override &lt;code&gt;nixpkgs&lt;/code&gt; without redefining the NIX_PATH? Does it matter?&lt;/p&gt;

    &lt;/div&gt;
    &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/NixOS/nix/issues/2033"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
  &lt;/div&gt;
&lt;/div&gt;



&lt;blockquote&gt;
&lt;p&gt;TIPS: use &lt;a href="https://github.com/nix-community/nix-direnv"&gt;nix-direnv&lt;/a&gt; for this&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h1&gt;
  
  
  References
&lt;/h1&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://nixos.org/manual/nix/unstable/installation/installing-binary.html#multi-user-installation"&gt;Nix Manual: Multi User Installation&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://nixos.org/manual/nix/unstable/installation/multi-user.html"&gt;Nix Manual: Multi User Security&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://nixos.org/manual/nix/unstable/installation/upgrading.html"&gt;Nix Manual: Upgrading Nix&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>nix</category>
      <category>linux</category>
    </item>
    <item>
      <title>Current states of IoT development</title>
      <dc:creator>૮༼⚆︿⚆༽つ</dc:creator>
      <pubDate>Tue, 15 Sep 2020 12:59:21 +0000</pubDate>
      <link>https://dev.to/drsensor/current-states-of-iot-development-2pg0</link>
      <guid>https://dev.to/drsensor/current-states-of-iot-development-2pg0</guid>
      <description>&lt;blockquote&gt;
&lt;p&gt;In the current state, you can build Web Apps in 5 days alone but you can't build a simple IoT solution in 1 week.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The current state doing web development is easy not only because there is many content/tutorial for that but also many great tooling that exists in the ecosystem (thanks to many Open Source project). Let's list what we have now in the Web Dev ecosystem.&lt;/p&gt;

&lt;p&gt;Now in Front-End or Mobile development we have:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;some framework that decent and have mature enough based on Component Design Pattern&lt;/li&gt;
&lt;li&gt;hot &lt;a href="https://webpack.js.org/concepts/hot-module-replacement/"&gt;module&lt;/a&gt;/&lt;a href="https://flutter.dev/docs/development/tools/hot-reload"&gt;reload&lt;/a&gt;. Change a small portion of code and the result will be shown in less than seconds regardless of how big/complex your codebase.&lt;/li&gt;
&lt;li&gt;Static, dynamic, or duck typing language. Choose what suits you well&lt;/li&gt;
&lt;li&gt;development can be framework and language agnostic thanks to &lt;a href="https://developer.mozilla.org/en-US/docs/Web/Web_Components"&gt;WebComponent&lt;/a&gt; &amp;amp; &lt;a href="https://developer.mozilla.org/en-US/docs/WebAssembly"&gt;WebAssembly&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;thousand library and hundred UI Components ready to use in many frameworks&lt;/li&gt;
&lt;li&gt;rich debugging tools, you can even do time travel debugging, event there is built in the debugger in any popular browser now&lt;/li&gt;
&lt;li&gt;rise of &lt;a href="https://micro-frontends.org/"&gt;micro front-end&lt;/a&gt; architecture
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;and Back End development we have:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;some backend framework has &lt;em&gt;hot reload&lt;/em&gt; alike. (it's called &lt;a href="https://en.wikipedia.org/wiki/Hot_swapping#Software"&gt;Hot Code Swap&lt;/a&gt;)&lt;/li&gt;
&lt;li&gt;many backend frameworks/libs became database agnostic&lt;/li&gt;
&lt;li&gt;thanks to microservice pattern and docker, backend code can be written in any language&lt;/li&gt;
&lt;li&gt;many tools for documenting, building, and inspecting API and data. (&lt;a href="https://swagger.io/"&gt;Swagger&lt;/a&gt;, &lt;a href="https://graphql.org/"&gt;GraphiQL&lt;/a&gt;, etc)&lt;/li&gt;
&lt;li&gt;Design Pattern agnostic. (some depends on the language that you use)&lt;/li&gt;
&lt;li&gt;advanced logging system&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;while in Embedded development (especially µC) we have:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;language agnostic but depend on specific devices. (&lt;a href="https://micropython.org/"&gt;microphyton&lt;/a&gt;, &lt;a href="http://johnny-five.io/"&gt;nodejs johnyfive&lt;/a&gt;, STM32F4DISC, etc)&lt;/li&gt;
&lt;li&gt;device agnostic but depend on language and abstraction layer. (&lt;a href="https://en.wikipedia.org/wiki/Embedded_C%2B%2B"&gt;EC++&lt;/a&gt;, &lt;a href="https://www.arduino.cc/"&gt;Arduino&lt;/a&gt;)&lt;/li&gt;
&lt;li&gt;nearly &lt;em&gt;write once run anywhere&lt;/em&gt; can only be achieved using &lt;a href="https://www.arduino.cc/"&gt;Arduino&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;low productivity because no live/hot reload thing. (exception if using &lt;a href="https://www.zephyrproject.org/"&gt;Zephyr OS&lt;/a&gt;)&lt;/li&gt;
&lt;li&gt;mostly concurrent programming can only be achieved if using &lt;a href="https://en.wikipedia.org/wiki/Real-time_operating_system"&gt;RTOS&lt;/a&gt; by sacrificing significant memory&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;However, IoT development is not only about hardware. It's a combination of those three that makes IoT solution valuable. So, how to glue them together and avoid silos mistake?&lt;/p&gt;

</description>
      <category>iot</category>
      <category>discuss</category>
    </item>
  </channel>
</rss>
