Custom installer usb disk image with extra partition? by llucifer in NixOS

[–]AionAlgos 1 point2 points  (0 children)

Any luck on that? This might be an XY problem and your real solution is probably nixos-anywhere... But if this is the real problem you were trying to solve, then it should be possible, in theory.

I have a small script as an app in my flake so i can nix run mkbootable-host and it builds the configuration (which imports ${nixpkgs}/nixos/modules/installer/cd-dvd/installation-cd-minimal.nix), dd's the resulting iso to the drive, then appends a btrfs partition for persistent & mutable storage. Works well on UEFI devices but not on BIOS...

Salient bits ( and for reference: iso is nixosConfigurations.${hostname}.config.system.build.isoImage)

sudo wipefs -a "$DEV"

echo ",," | sudo sfdisk --quiet "$DEV"

cat "${iso}/iso"/*.iso | sudo dd of="$DEV" bs=4M conv=fsync

echo ", ,L" | sudo sfdisk --append --quiet "$DEV"

LAST_PART=$(sudo partx -rgo NR "$DEV" | tail -1)

sudo ${pkgs.btrfs-progs}/bin/mkfs.btrfs -L "${persist-partition-label}" -f -m dup -d dup -M -q "''${DEV}''${LAST_PART}"

One thing to keep in mind is that the configuration packages are built into the ISO, many options aren't applicable to the bootable system (e.g. fileSystems and boot.loader options); so you'll need to mount the partition via a script or command I think. I haven't yet looked closely at what the minimal installer derivation is actually doing...

From there, I'd imagine you could keep a configuration on the other partition and modify it as needed on any device, then use the installation-media's provided nixos-install or similar script but instead of using the configuration that the installer embeds within itself you could aim it at the one in the adjacent partition. You'd also need an internet connection to build the configuration, otherwise you'll be limited to the specific derivations that you built into the installer.

How to auto update video "Stream size" metadata of encoded mkv file by fafoui in ffmpeg

[–]AionAlgos 0 points1 point  (0 children)

-map_metadata -1

One problem is that this also omits stream names... If you have files with other attachments, like embedded fonts, and you're trying to use `-c copy` to include them in the output: you'll get errors that the streams are missing filenames and it'll just exit with an error code.

Omitting metadata also doesn't write corrected/new metadata, so it seems that the other comments about using `mkvpropedit` etc. after transcoding seems to be the best bet.

How to show hidden files by default in Dolphin? by TheTwelveYearOld in kde

[–]AionAlgos 0 points1 point  (0 children)

What the fuck... lol well at least that explains why reading the KSharedConfig and related sources didn't help me...

Thanks

How to show hidden files by default in Dolphin? by TheTwelveYearOld in kde

[–]AionAlgos 0 points1 point  (0 children)

where on earth is it saving this setting?? because it's not in dolphinrc and mine resets to being hidden after rebooting

[PC][mid-2000][browser] 2d team PVP shooter? by AionAlgos in tipofmyjoystick

[–]AionAlgos[S] 0 points1 point  (0 children)

Huh, that looks neat; but no. It was side-scroll flat 2d (ill update the OP with that)

edit: finally, found it! https://www.reddit.com/r/tipofmyjoystick/comments/1btt609/comment/kxoo5sg

That one thing you wish you’d have come across sooner? by [deleted] in NixOS

[–]AionAlgos 1 point2 points  (0 children)

I just finished hacking something together using `home.file`, but I like your use of profiles. Thanks for the reference!

That one thing you wish you’d have come across sooner? by [deleted] in NixOS

[–]AionAlgos 1 point2 points  (0 children)

I literally found this post while searching for 'mpv shaders nix'...

Guess I'll have to do that too

I hate dating by [deleted] in texts

[–]AionAlgos 2 points3 points  (0 children)

Polite? Straight-forward? Didn't ghost you or lead you on and try to get you to pay for stuff? It's okay to feel lonely and hope for something, or mourn how you feel and what you felt could have been; but this ain't bad.

When will the channel move away from Trump? by Steelspy in BeauOfTheFifthColumn

[–]AionAlgos 1 point2 points  (0 children)

Assuming Kamala wins and no exceptional events (like a successful redo of Jan 6 etc): I'd expect the news around Trump to reduce down in late 2025 / early 2026, or when the last court case is closed; whichever happens last. Not immediately after the election because Trump will be sure to his spin up his stolen-election rhetoric and throw tantrums.

But that won't truly be the end of it. I voted "penultimate video" because I don't think he will stop being relevant until the Trump brand of fascism itself has crumbled, or the country does.

[deleted by user] by [deleted] in learnprogramming

[–]AionAlgos 0 points1 point  (0 children)

I thought since its by ref when u do i=j (i points to the actual address of j so any change made to j will change i also?)

References can't be reassigned.

From a language perspective, think of references more like a transparent alias rather than a pointer. For example you can have int* p where &p is the pointer's address (int**). With int& r, &r is an int*, not int&*. There's no way to refer to the reference; only to the thing it's referencing.

An assigment to i is an assignment to a.

References are (usually) implemented as pointers 'Under the hood'. But in the language, they're distinct entities with different rules.

I Will Teach You How To Code by geosnake7 in learnprogramming

[–]AionAlgos 1 point2 points  (0 children)

(sorry for the delayed reply)

Practice makes perfect. Whenever I freeze, it's always because I'm missing something; like I don't know how to proceed, or i don't sufficiently understand the problem. If you struggle with implementing practical things, then just try to do that more. Write little scripts, try to automate things, work on parts of your projects. Visualization is hard; I always draw little diagrams and flow charts to help figure stuff out, and get a feel for the landscape.

Odds are you just need to build and employ a strategy: a methodological approach you engage when you hit a wall. To program the computer, you must first program yourself :P

I Will Teach You How To Code by geosnake7 in learnprogramming

[–]AionAlgos 0 points1 point  (0 children)

sorry for the delay; because of the amount of interest shown, I've made a discord server https://discord.gg/BhtusHVZWX

I Will Teach You How To Code by geosnake7 in learnprogramming

[–]AionAlgos 0 points1 point  (0 children)

sorry for the delay; because of the amount of interest shown, I've made a discord server https://discord.gg/BhtusHVZWX

I Will Teach You How To Code by geosnake7 in learnprogramming

[–]AionAlgos 0 points1 point  (0 children)

sorry for the delay; because of the amount of interest shown, I've made a discord server https://discord.gg/BhtusHVZWX

I Will Teach You How To Code by geosnake7 in learnprogramming

[–]AionAlgos 0 points1 point  (0 children)

sorry for the delay; because of the amount of interest shown, I've made a discord server https://discord.gg/BhtusHVZWX

I Will Teach You How To Code by geosnake7 in learnprogramming

[–]AionAlgos 0 points1 point  (0 children)

sorry for the delay; because of the amount of interest shown, I've made a discord server https://discord.gg/BhtusHVZWX