34 lines
1.2 KiB
Markdown
34 lines
1.2 KiB
Markdown
|
---
|
|||
|
title: "Error: unsupported tarball input attribute 'lastModified'"
|
|||
|
date: 2024-09-10 22:35:41
|
|||
|
tags: [Linux, Nix, NixOS]
|
|||
|
links:
|
|||
|
- https://discourse.nixos.org/t/error-unsupported-tarball-input-attribute-lastmodified/49435/4
|
|||
|
---
|
|||
|
|
|||
|
Yesterday, my laptop died and I needed to resurrect a spare laptop to work on.
|
|||
|
|
|||
|
This laptop was running an outdated version of NixOS, old packages, a different window manager and other things, so I tried to update it to bring it up to date so it's up to date with my dead laptop's configuration.
|
|||
|
|
|||
|
Doing so, though, gave me this error:
|
|||
|
|
|||
|
> Error: unsupported tarball input attribute ‘lastModified’
|
|||
|
|
|||
|
A normal `sudo nixos-rebuild switch` worked, but trying to use a Flake was generating the error.
|
|||
|
|
|||
|
I was able to get it working after running these commands from a Discourse thread:
|
|||
|
|
|||
|
```shell
|
|||
|
nix shell "github:NixOS/nix/2.18.4"
|
|||
|
|
|||
|
nix build .#nixosConfigurations.nixedo.config.system.build.toplevel
|
|||
|
|
|||
|
sudo nix-env --profile /nix/var/nix/profiles/system --set ./result
|
|||
|
|
|||
|
./result/bin/switch-to-configuration switch
|
|||
|
```
|
|||
|
|
|||
|
I also needed to add `--experimental-features 'nix-command flakes'` to the `nix` commands to get them to run.
|
|||
|
|
|||
|
Once this finished, I was able to reboot and get a running up-to-date configuration.
|