https://blue-build.org/ logo
Newbie question about what files can be edited/add...
# questions
w
Hi everyone! I’m working on making a personal project of blue-build with hyprland. I have all of my hyprland dot files saved in another repository and was wondering how to go about having blue-build automagically have them added to the users ~/.config/hypr/ directory. Additionally, a couple of the apps I want to add to my blue build have to be compiled from source, and I have those being copied into the /usr/bin/ but they need to be added to the $PATH, am I able to edit the PATH variable in blue-build or is there a better way to go about that?
a
message has been deleted
a
yeah so basically if you want to put a file into
/usr
or
/etc
, you can do that directly by putting it into the image you're building (e.g. with the
files
module). But to add something to
/var
(which includes anything in user home directories), you can't do it directly from the base image, because
/var
doesn't get replaced with image updates; the usual way to handle this is by creating a systemd user service that makes the changes you want (typically with some run condition that makes it only run once).
for modifying users'
$PATH
or other environment variables, you can add a drop-in conf file in
/usr/lib/environment.d
or
/etc/profile.d
, though that only applies to bash or certain other similar shells, so you'd need to do something else for fish or other shells
b
Also, it's worth mentioning the [chezmoi](https://blue-build.org/reference/modules/chezmoi/) module to move your dotfiles to the desired places in your home directory
c
If you are compiling software from source, then I'd recommend putting the built binaries into
/usr/bin
as that is where sysadmin binaries go. It will be automatically on the
$PATH
for users by default
b
⁨`/usr/bin`⁩ (nitpicking ^^)
And you would like to use [stages](https://blue-build.org/reference/stages/) for that, imo
c
Nah appreciated💚 was just a typo
3 Views