<?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: Ruraam</title>
    <description>The latest articles on DEV Community by Ruraam (@ruraam).</description>
    <link>https://dev.to/ruraam</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.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4128381%2Fe3ae1433-8a95-4e18-83f0-6b1739388576.png</url>
      <title>DEV Community: Ruraam</title>
      <link>https://dev.to/ruraam</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/ruraam"/>
    <language>en</language>
    <item>
      <title>Stop manually updating GitHub `.deb` packages: I built a lightweight Bash tool</title>
      <dc:creator>Ruraam</dc:creator>
      <pubDate>Wed, 16 Sep 2026 16:23:46 +0000</pubDate>
      <link>https://dev.to/ruraam/stop-manually-updating-github-deb-packages-i-built-a-lightweight-bash-tool-b38</link>
      <guid>https://dev.to/ruraam/stop-manually-updating-github-deb-packages-i-built-a-lightweight-bash-tool-b38</guid>
      <description>&lt;p&gt;If you run Debian, Ubuntu, or Mint, you probably use tools like Discord, Obsidian, Fastfetch, or various CLI utilities that publish their latest builds directly as &lt;code&gt;.deb&lt;/code&gt; assets on &lt;strong&gt;GitHub Releases&lt;/strong&gt; instead of maintaining a proper APT PPA or repository.&lt;/p&gt;

&lt;p&gt;The problem? Updating them is tedious:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Go to the repo's release page.&lt;/li&gt;
&lt;li&gt;Find the right architecture asset (&lt;code&gt;amd64&lt;/code&gt;, &lt;code&gt;arm64&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;Download it viabrowser or &lt;code&gt;curl&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Install it with &lt;code&gt;sudo dpkg -i ...&lt;/code&gt; and fix missing dependencies with &lt;code&gt;apt --fix-broken install&lt;/code&gt;.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;I wanted an automated, &lt;strong&gt;Obtainium-like experience&lt;/strong&gt; for the Linux desktop/server, but without installing Python runtimes, Node packages, or untrusted binary blobs.&lt;/p&gt;

&lt;p&gt;So I wrote &lt;strong&gt;debup&lt;/strong&gt; — a zero-dependency Bash script.&lt;/p&gt;




&lt;h2&gt;
  
  
  What does it look like?
&lt;/h2&gt;

&lt;p&gt;Tracking and installing a new tool is aone-liner:&lt;/p&gt;

&lt;p&gt;Add and install a GitHub release package&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;debup add fastfetch-cli/fastfetch
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That's it. It queries GitHub's API, compares versions, pulls the right architecture, installs dependencies, and cleans up after itself.&lt;/p&gt;




&lt;h2&gt;
  
  
  Technical Details (Under the Hood)
&lt;/h2&gt;

&lt;p&gt;Since the goal was to keep it strictly native to Debian-based systems, here area few implementation choices:&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Safe Dependency Resolution
&lt;/h3&gt;

&lt;p&gt;Instead of using the raw &lt;code&gt;dpkg -i file.deb&lt;/code&gt; (which fails silently when dependencies are missing), &lt;code&gt;debup&lt;/code&gt; invokes:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;apt-get &lt;span class="nb"&gt;install&lt;/span&gt; &lt;span class="nt"&gt;-y&lt;/span&gt; ./package.deb
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This allows APT to resolve and fetch upstream Debian dependencies automatically in a single pass.&lt;/p&gt;

&lt;h3&gt;
  
  
  2.Accurate Version Comparison
&lt;/h3&gt;

&lt;p&gt;Comparing versions with string equality (&lt;code&gt;$local == $remote&lt;/code&gt;) often breaks because of tag naming quirks (e.g. &lt;code&gt;v1.2.0&lt;/code&gt; vs package version &lt;code&gt;1.2.0-1&lt;/code&gt;). We use Debian's native comparison tool instead:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;dpkg &lt;span class="nt"&gt;--compare-versions&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="nv"&gt;$local_ver&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt; ge &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="nv"&gt;$remote_ver&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  3. Graceful Cleanups
&lt;/h3&gt;

&lt;p&gt;To prevent leftover &lt;code&gt;.deb&lt;/code&gt; artifacts in &lt;code&gt;/tmp&lt;/code&gt; if a user hits &lt;code&gt;Ctrl+C&lt;/code&gt; or a download fails:&lt;br&gt;
local&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;tmp_deb&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="s2"&gt;"/tmp/debup_&lt;/span&gt;&lt;span class="k"&gt;${&lt;/span&gt;&lt;span class="nv"&gt;remote_ver&lt;/span&gt;&lt;span class="k"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;_&lt;/span&gt;&lt;span class="k"&gt;${&lt;/span&gt;&lt;span class="nv"&gt;ARCH&lt;/span&gt;&lt;span class="k"&gt;}&lt;/span&gt;&lt;span class="s2"&gt;.deb"&lt;/span&gt;
&lt;span class="nb"&gt;trap&lt;/span&gt; &lt;span class="s1"&gt;'rm -f "$tmp_deb"'&lt;/span&gt; INT TERM EXIT
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  4. Zero External Dependencies
&lt;/h3&gt;

&lt;p&gt;Only uses standard core utilities already present on any Debian/Ubuntu install: &lt;code&gt;bash&lt;/code&gt;, &lt;code&gt;curl&lt;/code&gt;, &lt;code&gt;grep&lt;/code&gt;, &lt;code&gt;sed&lt;/code&gt;, &lt;code&gt;dpkg&lt;/code&gt;, and &lt;code&gt;apt&lt;/code&gt;.&lt;/p&gt;




&lt;h2&gt;
  
  
  Give it a spin
&lt;/h2&gt;

&lt;p&gt;The project is fully open source on GitHub:&lt;/p&gt;

&lt;p&gt;👉 &lt;strong&gt;&lt;a href="https://github.com/Ruraam/debup" rel="noopener noreferrer"&gt;github.com/Ruraam/debup&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;If you have feedback, packaging edge-cases to report, or ShellCheck improvements,feel free to open an issue or drop a comment below!&lt;/p&gt;

</description>
      <category>linux</category>
      <category>ubuntu</category>
      <category>bash</category>
      <category>opensource</category>
    </item>
  </channel>
</rss>
