Hyprland Setup Assistant is a Go-based command-line tool designed to simplify the installation, configuration, and troubleshooting of the Hyprland window manager on FreeBSD. This application ensures that all necessary packages are installed, environment variables are properly set, and services like DBus are up and running.
- Install Hyprland and its required components (e.g.,
waybar
,alacritty
,wofi
,dbus
). - Configure Hyprland by copying a pre-configured
hyprland.conf
to the appropriate location. - Ensure DBus is installed and running for proper Wayland support.
- Set environment variables such as
XDG_RUNTIME_DIR
automatically in.profile
. - Troubleshooting functionality to verify installation and check for common issues.
- Log saving feature to assist with troubleshooting and debugging.
Before running the application, ensure that you have the following:
- FreeBSD system with
pkg
as the package manager. - sudo installed to allow the tool to manage packages and services with elevated privileges.
- The Go programming language installed (for compiling from source).
-
Clone the repository:
git clone https://github.com/vimanuelt/hyprland-setup.git cd hyprland-setup
-
Compile the Go application:
go build -o hyprsetup hyprsetup.go
-
Run the Setup Assistant:
sudo ./hyprsetup
Once you run hyprsetup
, you will be presented with a menu that offers several options:
-
Install Hyprland:
- Installs Hyprland and its dependencies (
wlroots
,waybar
,grim
, etc.). - Configures environment variables like
XDG_RUNTIME_DIR
. - Ensures
dbus
is installed and running.
- Installs Hyprland and its dependencies (
-
Configure Hyprland:
- Copies a predefined
hyprland.conf
file from the current directory to~/.config/hypr/
. - Sets up default key bindings and layout options.
- Copies a predefined
-
Troubleshoot:
- Checks if
Hyprland
is installed and in the systemPATH
. - Verifies that
XDG_RUNTIME_DIR
is properly set. - Ensures
dbus
is running.
- Checks if
-
Save Logs:
- Saves installation and configuration logs to
/tmp/hyprland_setup.log
.
- Saves installation and configuration logs to
-
Exit:
- Quits the application.
- The
hyprland.conf
file is included in the current directory and will be copied to~/.config/hypr/
during the installation process. You can modify this file according to your needs before running the setup.
###################
### MY PROGRAMS ###
###################
$terminal = alacritty
$fileManager = dolphin
$menu = wofi --show drun
#################
### AUTOSTART ###
#################
exec-once = waybar &
#####################
### LOOK AND FEEL ###
#####################
general {
gaps_in = 5
gaps_out = 20
border_size = 2
col.active_border = rgba(33ccffee) rgba(00ff99ee) 45deg
allow_tearing = false
}
decoration {
rounding = 10
active_opacity = 1.0
inactive_opacity = 1.0
blur {
enabled = true
size = 3
passes = 1
}
}
###################
### KEYBINDINGS ###
###################
$mainMod = SUPER
bind = $mainMod, Return, exec, $terminal
bind = $mainMod, E, exec, firefox
bind = $mainMod, M, exit
After completing the setup, you can start Hyprland using the following command from the terminal:
dbus-launch Hyprland
Make sure that XDG_RUNTIME_DIR
is correctly set by either restarting your terminal or manually sourcing the .profile
:
source ~/.profile
-
XDG_RUNTIME_DIR Not Set:
- Ensure that
XDG_RUNTIME_DIR
is set in.profile
. You can check the value by running:echo $XDG_RUNTIME_DIR
- Ensure that
-
DBus Not Running:
- If
waybar
or other applications fail to start, ensure thatdbus
is running by executing:sudo service dbus start
- If
-
Failed to Install Packages:
- If the installation fails, make sure you have
sudo
permissions and the correct package repositories are enabled.
- If the installation fails, make sure you have
This project is licensed under the BSD 3-Clause License.
If you would like to contribute, feel free to open a pull request or submit an issue on the GitHub repository.