<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom"><title>GNUcode.me</title><id>https://gnucode.me/feeds/tags/guix ssd.xml</id><subtitle>Tag: guix ssd</subtitle><updated>2024-04-18T01:18:57Z</updated><link href="https://gnucode.me/feeds/tags/guix ssd.xml" rel="self" /><link href="https://gnucode.me" /><entry><title>Migrating to an SSD</title><id>https://gnucode.me/migrating-to-an-ssd.html</id><author><name>Joshua Branson</name><email>jbranso@dismail.de</email></author><updated>2021-06-29T05:00:00Z</updated><link href="https://gnucode.me/migrating-to-an-ssd.html" rel="alternate" /><content type="html">&lt;h1&gt;Table of Contents&lt;/h1&gt;&lt;ol&gt;&lt;li&gt;&lt;p&gt;&lt;a href=&quot;#orgf6d0c49&quot;&gt;Time to upgrade your computer&lt;/a&gt;&lt;/p&gt;&lt;ol&gt;&lt;li&gt;&lt;p&gt;&lt;a href=&quot;#org0396ea4&quot;&gt;Introduction&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;&lt;a href=&quot;#org3c88524&quot;&gt;Installing packages for the user profile: joshua&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;&lt;a href=&quot;#org227238d&quot;&gt;Setting up Sway's config files&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;&lt;a href=&quot;#org1bb21a0&quot;&gt;Refreshing my fonts&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;&lt;a href=&quot;#org135c8b8&quot;&gt;Reconfiguring my system to use my services&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;&lt;a href=&quot;#org66d6e9e&quot;&gt;Setting up jmacs&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;&lt;a href=&quot;#orgeb8ae8c&quot;&gt;Setting up my hosts file&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;&lt;a href=&quot;#orgd6b36d5&quot;&gt;re-installing firefox via flatpak&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;&lt;a href=&quot;#org6c5528f&quot;&gt;Setting up application specific settings&lt;/a&gt;&lt;/p&gt;&lt;ol&gt;&lt;li&gt;&lt;a href=&quot;#orgf4086d5&quot;&gt;Setting up isync.&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href=&quot;#org9fa06cd&quot;&gt;Setting up termite settings&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href=&quot;#orgb693454&quot;&gt;re-setting up tootle&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href=&quot;#orgea6efa5&quot;&gt;re-setting up linphone&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href=&quot;#orga2a283e&quot;&gt;re-setting up my wifi connections&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href=&quot;#org94e1897&quot;&gt;setting up my git username&lt;/a&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;&lt;a href=&quot;#orga2d1f7d&quot;&gt;copying &lt;code&gt;~./authinfo&lt;/code&gt;&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;&lt;a href=&quot;#org94b5f0b&quot;&gt;Conclusion&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/li&gt;&lt;/ol&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;orgf6d0c49&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h1&gt;TODO Time to upgrade your computer&lt;/h1&gt;&lt;p&gt;tl;dr   Re-installing my OS to my liking sure takes a while.  It
took me 9 hours (and counting).  Can you beat that time?  Let's
be real.  Of course you can!  :)&lt;/p&gt;&lt;p&gt;The strategy described below is perhaps a bit silly.  This
strategy is how you would recreate your OS settings from your
config files.  It may be easier to occasionally re-create your
entire disk image and save to a file or usb stick.  The below
example taken from the guix manual, shows you how to boot your
GNU Guix system image from a virtual machine.&lt;/p&gt;&lt;pre&gt;&lt;code&gt;image=$(guix system image --image-type=qcow2 \
             gnu/system/examples/lightweight-desktop.tmpl)
cp $image /tmp/my-image.qcow2
chmod +w /tmp/my-image.qcow2
qemu-system-x86_64 -enable-kvm -hda /tmp/my-image.qcow2 -m 1000 \
                   -bios $(guix build ovmf)/share/firmware/ovmf_x64.bin&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;It is probably possible to modify the commands below to create a
boot-able usb stick that has your exact OS with all your
settings, users, and packages.  With that usb stick, you should
somehow be able to boot it and copy it onto your new computer.&lt;/p&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;org0396ea4&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h2&gt;Introduction&lt;/h2&gt;&lt;p&gt;I read a blog post entitled &lt;a href=&quot;https://ambrevar.xyz/reproducible-computing-environments/index.html&quot;&gt;what if you lost your computer right
now?&lt;/a&gt; from a guix developer some time ago.  It describes a fun
thought experiment, namely how difficult would it be to copy your
settings from your previous computer to your new one?  How long
would this process take you?  Well today I updated my &lt;a href=&quot;https://osboot.org/index.html&quot;&gt;os-boot&lt;/a&gt;-ed
Thinkpad T400 laptop from an HDD to an SSD.  Here are the
settings that I had to manually copy over to the SSD.&lt;/p&gt;&lt;p&gt;I first tried to set up disc encryption via guix's installer.
The install went ok, but booting it up did &lt;em&gt;not&lt;/em&gt; work.  Grub
would not decrypt the drive. That's when I realized that the
keyboard layout that I typed in the original password was dvorak,
but osboot was using a qwerty layout.  So then I re-installed GNU
Guix and specified an encrypted password for /dev/sda3 to be only
numbers.  Grub still did not decrypt the partition…Please note
that I am using os-boot, which means that I am using not using
the grub that is installed via Guix.  Instead osboot already
includes a grub that is flashed to my rom image.  So perhaps that
image is a bit dated.&lt;/p&gt;&lt;p&gt;Anyway, then I installed Guix System without any encryption.  Now
I could boot into the system.  Oh, and I installed Guix System
using this mostly barebones config.  In my experience, if you try
to install Guix System with a desktop environment, at some point
your internet will flake out, fail to download some dependency,
and you will have to start over.  So install bare bones first.
:)&lt;/p&gt;&lt;pre&gt;&lt;code&gt;;; This is an operating system configuration generated
;; by the graphical installer.

(use-modules (gnu))
(use-service-modules desktop networking ssh xorg)

(operating-system
  (locale &amp;quot;en_US.utf8&amp;quot;)
  (timezone &amp;quot;America/Indiana/Indianapolis&amp;quot;)
  (keyboard-layout (keyboard-layout &amp;quot;us&amp;quot; &amp;quot;dvorak&amp;quot;))
  (host-name &amp;quot;dobby&amp;quot;)
  (users (cons* (user-account
                  (name &amp;quot;joshua&amp;quot;)
                  (comment &amp;quot;Joshua Branson&amp;quot;)
                  (group &amp;quot;users&amp;quot;)
                  (home-directory &amp;quot;/home/joshua&amp;quot;)
                  (supplementary-groups
                    '(&amp;quot;wheel&amp;quot; &amp;quot;netdev&amp;quot; &amp;quot;audio&amp;quot; &amp;quot;video&amp;quot;)))
                %base-user-accounts))
  (packages
    (append
      (list (specification-&amp;gt;package &amp;quot;nss-certs&amp;quot;))
      %base-packages))
  (services
    (append
      (list (service network-manager-service-type)
            (service wpa-supplicant-service-type))
      %base-services))
  (bootloader
    (bootloader-configuration
      (bootloader grub-bootloader)
      (target &amp;quot;/dev/sda&amp;quot;)
      (keyboard-layout keyboard-layout)))
  (swap-devices
    (list (uuid &amp;quot;d021373e-2399-49ea-bc92-6134f2b2c94f&amp;quot;)))
  (file-systems
    (cons* (file-system
            (mount-point &amp;quot;/&amp;quot;)
             (device
               (uuid &amp;quot;4bf80701-e54e-44eb-817f-b2f52f5af80e&amp;quot;
                     'ext4))
             (type &amp;quot;ext4&amp;quot;))
           %base-file-systems)))&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;org3c88524&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h2&gt;Installing packages for the user profile: joshua&lt;/h2&gt;&lt;p&gt;Now that I could boot my configuration (into a tty console), I
started to go about installing my previous packages for the user
&amp;quot;joshua&amp;quot;, which is me!  Obviously.  :D&lt;/p&gt;&lt;pre&gt;&lt;code&gt;joshua@dobby $ git clone https://notabug.org/jbranso/prog
             $ boring output blah blah blah
             $ done
joshua@dobby $
joshua@dobby $ cd prog;
joshua@dobby $ mkdir -p gnu/guix;
joshua@dobby $ cd gnu/guix;
joshua@dobby $ git clone https://notabug.org/jbranso/guix-config
             $ boring output blah blah blah
             $ done
joshua@dobby $
joshua@dobby $ guix package -m manifest.scm
joshua@dobby $ error: jmacs package not found&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;#+RESULTS&lt;/p&gt;&lt;pre&gt;&lt;code&gt;Error: package jmacs cannot be found&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Whoops…I forgot.  jmacs is my custom emacs package.  Don't get
too excited. It pretty much only works for me, and if you try to
use it, you will curse my name.  Create specific files for
reasons that only make sense to me.  Trust me, you'd have to add
in my custom channel, fail to install my jmacs, etc.  You have
been warned.&lt;/p&gt;&lt;p&gt;So this is a minor annoyance.  As far as I know, GNU Guix does
not let you specify your channel in &lt;code&gt;config.scm&lt;/code&gt;.  Instead you
specify your custom channels in &lt;code&gt;~/.config/guix/channels.scm&lt;/code&gt;.
Perhaps this is a strategic choice.  As in, please push your code
upstream that way you do NOT need to have a private repo of code.&lt;/p&gt;&lt;p&gt;Anyway, for now, I will delete my jmacs package in the manifest
file. Take 2:&lt;/p&gt;&lt;pre&gt;&lt;code&gt;nano manifest.scm # delete my jmacs line
guix package -m manifest.scm&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;For some reason the above command &lt;code&gt;guix package -m manifest.scm&lt;/code&gt;,
failed the first time I tried it.  I guess my manifest file is
sort of big:&lt;/p&gt;&lt;pre&gt;&lt;code&gt;ls manifest.scm&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Anyway, take 3:&lt;/p&gt;&lt;pre&gt;&lt;code&gt;guix package -m manifest.scm&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;This time it worked!  Sweetness!  I now have the previous file in
my profile.&lt;/p&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;org227238d&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h2&gt;Setting up Sway's config files&lt;/h2&gt;&lt;p&gt;Now I need to copy my sway configuration into &lt;code&gt;~/.config/sway&lt;/code&gt;.&lt;/p&gt;&lt;pre&gt;&lt;code&gt;mkdir ~/.config/sway
cp ./config ~/.config/sway/
cp ./status.sh ~/.config/sway/&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;org1bb21a0&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h2&gt;Refreshing my fonts&lt;/h2&gt;&lt;p&gt;Due to a long standing &lt;a href=&quot;http://issues.guix.gnu.org/18640&quot;&gt;bug&lt;/a&gt; in GNU Guix, fontconfig's cache is
not refreshed automatically.  The below command makes my newly
installed fonts available, which are needed for my sway status
bar.&lt;/p&gt;&lt;pre&gt;&lt;code&gt;fc-cache -fv&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;org135c8b8&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h2&gt;Reconfiguring my system to use my services&lt;/h2&gt;&lt;p&gt;Originally I installed GNU Guix from a bare-bones.scm file. Now,
I can reconfigure my system to set up my services, including a
locally running dovecot server, nginx, and mcron, etc.  Here is
my current &lt;a href=&quot;https://notabug.org/jbranso/guix-config/src/master/sway.scm&quot;&gt;sway.scm&lt;/a&gt; config file.&lt;/p&gt;&lt;pre&gt;&lt;code&gt;sudo guix system reconfigure sway.scm&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;#+RESULTS&lt;/p&gt;&lt;pre&gt;&lt;code&gt;Error: no code for module secret&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Whoops.  That's right.  I've got some bit of code in my config
that I did not share with the world…That means that my current
config will not work…A few deletions to my config later…&lt;/p&gt;&lt;pre&gt;&lt;code&gt;sudo guix system reconfigure sway.scm&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;#+RESULTS&lt;/p&gt;&lt;pre&gt;&lt;code&gt;Error filesystem uuid &amp;quot;0542cf20-9f62-49cf-992f-54a75186f2b2&amp;quot; not found.&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Whoops.  I can't use the uuid from the HHD.  I need to get the
UUID from the SSD.&lt;/p&gt;&lt;p&gt;In order to avoid having this minor
annoyance in the future, I could label my partitions.  When
doing the manual install I could do something like:&lt;/p&gt;&lt;pre&gt;&lt;code&gt;sudo fdisk /dev/sda;
# create a new partition table either msdos or gpt
# gpt is probably what you want for newer hardware
g
# add a new partition
# it's just much easier to set it up to use two partitions
# 1 for the EFI partition and 2 for the / (root) filesystem.
n
n
# write to the disk save and exit
w
parted /dev/sda set 1 esp on
mkfs.fat -F32 -L my-EFI /dev/sda1
mkfs.ext4 -L my-root /dev/sda2
mount LABEL=my-root /mnt
mkdir -p /mnt/boot/efi
mount LABEL=my-EFI /mnt/boot/efi&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Then I could use this bit to configure my partitions.&lt;/p&gt;&lt;pre&gt;&lt;code&gt;(filesystems
 (list
  (file-system
   (mount-point &amp;quot;/boot/efi&amp;quot;)
   (type &amp;quot;vfat&amp;quot;)
   (device (file-system-label &amp;quot;my-EFI&amp;quot;)))
  (file-system
   (mount-point &amp;quot;/&amp;quot;)
   (type &amp;quot;ext4&amp;quot;)
   (device (file-system-label &amp;quot;my-root&amp;quot;)))))&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;A quick copy from my local &lt;code&gt;/etc/config.scm&lt;/code&gt; later:&lt;/p&gt;&lt;pre&gt;&lt;code&gt;sudo guix system reconfigure sway.scm&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;This surprisingly was really uneventful.  Most of the services
did not run immediately.  For instance dovecot did not run,
because I do not have the &lt;code&gt;~/.mbsyncrc&lt;/code&gt; file, which means that I
don't have any mail to serve.  Surprisingly nginx did run!  Even
though some of the spots where I told it to serve html files do
not exist yet on the filesystem.  But I can actually view my
locally running website (local.gnucode.me) via opening up icecat
and viewing &lt;a href=&quot;http://local.propernaming.org&quot;&gt;http://local.propernaming.org&lt;/a&gt;.  Which is really
weird.  Because it should be showing my local propernaming.org
site, but instead it is showing my gnucode.me site.  Weird.
Apparently I need to tweak my nginx service.&lt;/p&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;org66d6e9e&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h2&gt;Setting up jmacs&lt;/h2&gt;&lt;p&gt;I first need to download my emacs config.&lt;/p&gt;&lt;pre&gt;&lt;code&gt;git clone https://notabug.org/jbranso/emacs.d ~/.config/emacs
rm -r ~/.emacs.d&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Now I can guix pull and install jmacs.&lt;/p&gt;&lt;pre&gt;&lt;code&gt;guix pull
guix package -i jmacs

-sha256 hash mismatch for /gnu/store/8i2n33a06lfbpxr3jmxj6mhdvsp5fnvl-aggressive-fill-paragraph-20180910.816.el:
expected hash: 12fi9r1wfzv8iqyzrnh82lq6793i9gxq52hk54acxskax29kmn30
actual hash:   1q1xpz3rfsm7402d5k32lkr2vfvimwxf19p1xf3jslqdw8c0k06a&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Hmmm, emacs-aggressive-fill-paragraph is not building…I don't
think that I actually use aggressive fill paragraph much…So I
think that I will NOT use that.&lt;/p&gt;&lt;p&gt;While it is nice to set up &lt;a href=&quot;https://notabug.org/jbranso/guix-packages/src/master/gnu/packages/jmacs.scm&quot;&gt;jmacs&lt;/a&gt; via my &lt;a href=&quot;https://notabug.org/jbranso/guix-packages/src/master/gnu/packages/jmacs.scm&quot;&gt;custom channel&lt;/a&gt;. For
development purposes, it's actually easier to set up
&lt;code&gt;GUIX_PACKAGE_PATH&lt;/code&gt;.&lt;/p&gt;&lt;p&gt;So I copied my .bash&amp;lt;sub&amp;gt;profile&amp;lt;/sub&amp;gt; from the old machine.&lt;/p&gt;&lt;pre&gt;&lt;code&gt;cat ~/.bash_profile&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;The important bit is where I set &lt;code&gt;GUIX_PACKAGE_PATH&lt;/code&gt;
environmental variable.  It might actually be a better idea to
set that variable in ~/.profile, because that then those
settings would be saved for any shell.&lt;/p&gt;&lt;p&gt;Take 2!&lt;/p&gt;&lt;pre&gt;&lt;code&gt;guix pull
guix package -i jmacs&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;#+RESULTS&lt;/p&gt;&lt;pre&gt;&lt;code&gt;build of /gnu/store/9m73xmni7ixvmlyksj74fid73ij9sn0b-ledger-mode-20200530.1710.tar.drv failed
View build log at '/var/log/guix/drvs/9m/73xmni7ixvmlyksj74fid73ij9sn0b-ledger-mode-20200530.1710.tar.drv.bz2'.&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Oh, I guess I haven't actually used ledger mode in emacs in a
while…let's disable that as well.  A few more local edits in
&lt;code&gt;~/gnu/guix/guix-packages/gnu/packages/jmacs.scm&lt;/code&gt; later…&lt;/p&gt;&lt;p&gt;Take 3!&lt;/p&gt;&lt;pre&gt;&lt;code&gt;guix package -i jmacs&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;I do find it a little interesting that it is compiling Emacs
from source.  I'm not entirely certain why this is necessary.
My &lt;code&gt;jmacs.scm&lt;/code&gt; is not entirely complicated.  Here is an excerpt:&lt;/p&gt;&lt;pre&gt;&lt;code&gt;grep -A 15 '(define-public jmacs' /home/joshua/prog/gnu/guix/guix-packages/gnu/packages/jmacs.scm&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;I'm essentially just setting up Emacs to use guix as the package
manager for emacs packages.&lt;/p&gt;&lt;p&gt;Surprisingly, jmacs worked for me after I got it to install.  I
did not expect that to work out so well.  I did have one tiny
issue with autosaves.  I just needed to create this directory:&lt;/p&gt;&lt;pre&gt;&lt;code&gt;mkdir ~/.config/emacs/emacs-auto-saves&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;orgeb8ae8c&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h2&gt;Setting up my hosts file&lt;/h2&gt;&lt;p&gt;I have a 10 or lines in my /etc/hosts file, so that I can run my
static websites locally.  That way I can make local changes,
before I upload them to the actual server. I've got most of
these settings in my &lt;a href=&quot;https://notabug.org/jbranso/guix-config/src/master/sway.scm&quot;&gt;guix-config.scm&lt;/a&gt;, but some of them are
&amp;quot;secret&amp;quot;.&lt;/p&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;orgd6b36d5&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h2&gt;re-installing firefox via flatpak&lt;/h2&gt;&lt;p&gt;And re-settung up firefox sync only took about 5 minutes.&lt;/p&gt;&lt;pre&gt;&lt;code&gt;flatpak install flathub org.mozilla.firefox&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;org6c5528f&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h2&gt;Setting up application specific settings&lt;/h2&gt;&lt;p&gt;This following would not be all that necessary if I set up &lt;a href=&quot;https://git.sr.ht/~abcdw/rde&quot;&gt;guix
home&lt;/a&gt; or the slightly more &amp;quot;perfect&amp;quot; &lt;a href=&quot;https://framagit.org/tyreunom/guix-home-manager&quot;&gt;guix home manager.&lt;/a&gt;  Those two
tools let you set up a user profile that declares all of your
system state.  The command for it might look like:&lt;/p&gt;&lt;pre&gt;&lt;code&gt;guix home reconfigure home.scm&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;At the moment, I am not using these tools.  It also appears that
guix home will be merged into GNU Guix soon-ish.  I would
recommend you use guix home, if you want to try it.&lt;/p&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;orgf4086d5&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h3&gt;Setting up isync.&lt;/h3&gt;&lt;p&gt;Isync is what the cool kids are doing to set up local &lt;a href=&quot;https://en.wikipedia.org/wiki/Maildir&quot;&gt;maildirs&lt;/a&gt;,
which is how you can search for your email REALLY fast.  Like
the speed of thought fast.  :)&lt;/p&gt;&lt;p&gt;isync's configuration file is found in &lt;code&gt;~/.mbsyncrc&lt;/code&gt;.  Now this
file currently has the password for my email account.  So I
cannot simply put this file in my &lt;code&gt;guix-config&lt;/code&gt; git repository.
Or perhaps I could I would just modify the password line to look
like:&lt;/p&gt;&lt;p&gt;&lt;code&gt;password SomeReallyAwesomePassword&lt;/code&gt;&lt;/p&gt;&lt;p&gt;And then I would put .mbsyncrc into my .gitignore file.  Any
changes that I make to that file would not go in the repo.&lt;/p&gt;&lt;p&gt;It would probably be better to create a user service &lt;a href=&quot;https://git.sr.ht/~abcdw/rde&quot;&gt;guix home&lt;/a&gt;
or just a regular &lt;a href=&quot;https://guix.gnu.org/manual/en/html_node/Services.html&quot;&gt;Guix System Service&lt;/a&gt;.&lt;/p&gt;&lt;p&gt;But then I still have to figure out how to give isync my
password for my email account.  One possibility comes from the
&lt;a href=&quot;https://wiki.archlinux.org/title/Isync#Configuring&quot;&gt;archlinux wiki&lt;/a&gt; (seriously, if you are ever configuring software,
read the archlinux wiki first.  It is hands down the best wiki
out there to help you configure software!  Beware though.  Some
webpages will tell you how to set up proprietary software).&lt;/p&gt;&lt;p&gt;&lt;code&gt;# PassCmd &amp;quot;gpg2 -q --for-your-eyes-only --no-tty -d ~/.mailpass.gpg&amp;quot;&lt;/code&gt;&lt;/p&gt;&lt;p&gt;Another option is to set up &lt;a href=&quot;https://wiki.archlinux.org/title/Gnome_Keyring&quot;&gt;Gnome keyring&lt;/a&gt;, and to use the &lt;a href=&quot;https://wiki.gnome.org/Projects/Libsecret&quot;&gt;secret
tool.&lt;/a&gt;  The Archlinux wiki page about the gnome keyring would
probably be helpful in setting this up.  But again, I would have
to continually re-store my secrets on every upgrade.  I do not
know if Gnome keyring has a way of securely storing my secrets
in a git repository.&lt;/p&gt;&lt;p&gt;For now, I will just chose the lazy option. Just copying the
config from the &lt;a href=&quot;https://wiki.archlinux.org/title/Isync#Configuring&quot;&gt;archlinux wiki page&lt;/a&gt; and tweaking it for my needs.
My &lt;code&gt;~/.mbsyncrc&lt;/code&gt; now works for me.&lt;/p&gt;&lt;pre&gt;&lt;code&gt;mkdir -p ~/.mail/dismail
mbsync -a&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;org9fa06cd&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h3&gt;Setting up termite settings&lt;/h3&gt;&lt;p&gt;My default terminal is termite, and I need to recreate the
terminal configuration file: &lt;code&gt;~/.config/termite/config&lt;/code&gt;:&lt;/p&gt;&lt;pre&gt;&lt;code&gt;mkdir -p ~/.config/termite;
nano -p ~/.config/termite/config
# some edits later
cat ~/.config/termite/config&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Done!&lt;/p&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;orgb693454&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h3&gt;re-setting up tootle&lt;/h3&gt;&lt;p&gt;Tootle is a gtk application to access your mastodon account.
It's actually pretty awesome!  It only took me 5 minutes to get
this re-setup.  The file in
&lt;code&gt;~/.config/com.github.bleakgrey.tootle/accounts.json&lt;/code&gt; includes a
secret API token.  Again, I cannot put that in my guix-config.
Though I think that guix-home has a way to get around this…I hope.&lt;/p&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;orgea6efa5&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h3&gt;re-setting up linphone&lt;/h3&gt;&lt;p&gt;This first bit is authentication.  That takes 5 minutes.&lt;/p&gt;&lt;p&gt;The trick bit is merging my contacts.  I use jmp.chat, which is
an awesome cellular service.  For texting, jmp.chat uses XMPP.
Which is awesome, because my contacts are saved on the server.&lt;/p&gt;&lt;p&gt;BUT linphone, stores all the contacts locally…So I need to
find a way to automate all of my contacts when I upgrade.  For
now, it was pretty easy to just save my &lt;code&gt;~/.config/&lt;/code&gt; directory
from my hard drive to a usb, and copy the linphone directory over.&lt;/p&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;orga2a283e&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h3&gt;re-setting up my wifi connections&lt;/h3&gt;&lt;p&gt;Right now I use sway, and I can't quite get nm-applet to work.
So I set up wifi connections via&lt;/p&gt;&lt;pre&gt;&lt;code&gt;sudo nmcli dev wifi connect &amp;quot;&amp;lt;WIFI Name&amp;gt;&amp;quot; password &amp;lt;password&amp;gt; [name &amp;quot;&amp;lt;name&amp;gt;&amp;quot;]&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;I've got three or so wifi networks that I use:&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;p&gt;My parents wifi&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;work wifi&lt;/p&gt;&lt;/li&gt;&lt;li&gt;&lt;p&gt;home wifi&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;-public library wifi&lt;/p&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;org94e1897&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h3&gt;setting up my git username&lt;/h3&gt;&lt;pre&gt;&lt;code&gt;git config --global user.name &amp;quot;Joshua Branson&amp;quot;
git config --global user.email &amp;quot;jbranso AT gnucode.me&amp;quot;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;I actually don't know where git stores these settings, because
I do not see a &lt;code&gt;~/.config/git&lt;/code&gt; directory.&lt;/p&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;orga2d1f7d&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h2&gt;copying &lt;code&gt;~./authinfo&lt;/code&gt;&lt;/h2&gt;&lt;p&gt;So Emacs uses &lt;code&gt;~/.authinfo&lt;/code&gt; to save my passwords for various
machines.  For example to use my dismail email account the lines
look like:&lt;/p&gt;&lt;pre&gt;&lt;code&gt;machine imap.dismail.de login jbranso@dismail.de port imaps password someCoolPassword
machine smtp.dismail.de login jbranso@dismail.de port 587 password someCoolPassword&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Of course this password cannot be stored in a git repository, or
anyone could read my email.  So I have to copy this file
directly from the old machine.&lt;/p&gt;&lt;p&gt;Please note that Emacs recommends that you use &lt;code&gt;~/.authinfo.gpg&lt;/code&gt;
to securely encrypt your passwords.  For the life of me, I cannot
figure out how to reliably get this to work.  gpg is hard to
use.  I also lose my gpg key all the time, and then I cannot
decrypt my &lt;code&gt;.authinfo.gpg&lt;/code&gt; file.  I also have a hard time setting
up emacs to use &lt;code&gt;~/.authinfo.gpg&lt;/code&gt;.&lt;/p&gt;&lt;p&gt;Perhaps I should invest in a physical&lt;a href=&quot;https://en.wikipedia.org/wiki/Trusted_Platform_Module&quot;&gt; trusted platform module&lt;/a&gt;
like the &lt;a href=&quot;https://www.yubico.com/products/&quot;&gt;yubikey&lt;/a&gt; or &lt;a href=&quot;https://puri.sm/products/librem-key/&quot;&gt;librem-key&lt;/a&gt;.  I've heard that makes gpg key
management a little easier.  But then I just &lt;strong&gt;cannot&lt;/strong&gt; lose that
physical key.&lt;/p&gt;&lt;p&gt;&amp;lt;a id=&amp;quot;org94b5f0b&amp;quot;&amp;gt;&amp;lt;/a&amp;gt;&lt;/p&gt;&lt;h2&gt;Conclusion&lt;/h2&gt;&lt;p&gt;Whew!  If you've read this far, then you are an awesome human
being!  As you can see, many of up carry a lot of system state
in your operating systems.  I hope this convinces you that we
should store this state, so that it can be reliable reproduced
without too much hassle!&lt;/p&gt;&lt;p&gt;Also, as a fun aside, Guix System sure takes up a lot of disk
space.  My SSD is either 220 or 240 GB.  My &lt;code&gt;/&lt;/code&gt; partition
originally had 219 GB of free space on it.&lt;/p&gt;&lt;pre&gt;&lt;code&gt;sudo fdisk --list /dev/sda | grep -e '240|sda3'&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;BUT after installing GNU Guix System, and setting up sway and a
good amount of applications, 10% of &lt;code&gt;/&lt;/code&gt; is already being used!&lt;/p&gt;&lt;pre&gt;&lt;code&gt;df -h | grep -B 1 sda&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;And &lt;code&gt;/gnu/&lt;/code&gt; takes up 17GB!&lt;/p&gt;&lt;pre&gt;&lt;code&gt;sudo du -hc --max-depth=1 /gnu/&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Now I've reconfigured a few times.  How much of that &lt;code&gt;/gnu/store/&lt;/code&gt; can be
deleted once I have deleted some system generations and perhaps some
package generations?&lt;/p&gt;&lt;p&gt;The below suggests that I have three system generations.  Let's
reboot (to make sure that the current generation works), and
then delete those old generations.&lt;/p&gt;&lt;pre&gt;&lt;code&gt;guix system list-generations  | grep Generation

Generation 3    Jun 22 2021 21:41:14
Generation 4    Jun 27 2021 01:36:47    (current)&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Rebooting worked, now let's try deleting some old generations.&lt;/p&gt;&lt;pre&gt;&lt;code&gt;sudo guix system delete-generations&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;#+RESULTS&lt;/p&gt;&lt;pre&gt;&lt;code&gt;deleting /var/guix/profiles/system-1-link
deleting /var/guix/profiles/system-2-link
building /gnu/store/gdbm5lvi901ys1dplgjpw144fymr9di5-grub.cfg.drv...
building /gnu/store/zx89ajlx901m46jk48pql3zlb25zsdsa-install-bootloader.scm.drv...&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;The same is true for my package generations:&lt;/p&gt;&lt;pre&gt;&lt;code&gt;guix package --list-generations | grep Generation

Generation 5    Jun 23 2021 02:31:59    (current)

guix package --delete-generations&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;New let's go and delete some garbage!&lt;/p&gt;&lt;pre&gt;&lt;code&gt;guix gc

deleting `/gnu/store/trash'
deleting unused links...
note: currently hard linking saves 1386.33 MiB
guix gc: freed 13,245.99083 MiBs&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Now how much does space does &lt;code&gt;/gnu/&lt;/code&gt; take up now?&lt;/p&gt;&lt;pre&gt;&lt;code&gt;sudo du -hc --max-depth=1 /gnu/&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;#+RESULTS&lt;/p&gt;&lt;pre&gt;&lt;code&gt;11G /gnu/store
11G /gnu/
11G total&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;So it looks like we deleted 6 GB of cruft!  That's not too bad!&lt;/p&gt;</content></entry></feed>