Fix Getting Started section

Fix links, simplify grammar, remove redundant text.
This commit is contained in:
Mihai Fufezan 2022-08-13 02:45:14 +03:00
parent 7d7b2ab26c
commit 04bf3f24f9
No known key found for this signature in database
GPG key ID: 5899325F2F120900
2 changed files with 72 additions and 56 deletions

View file

@ -1,12 +1,15 @@
# Foreword
Nvidia GPUs are widely known as... yeah. If you want to try Hyprland on Nvidia regardless (many people have reported successes), follow the [Nvidia page](https://github.com/hyprwm/Hyprland/wiki/Nvidia) after installing Hyprland.
Nvidia GPUs are widely known as... yeah. If you want to try Hyprland on Nvidia
regardless (many people have reported successes), follow the
[Nvidia page](https://github.com/hyprwm/Hyprland/wiki/Nvidia) after installing
Hyprland.
### Distros
Arch and NixOS are very supported. For any other distro (not based on Arch/Nix)
you might have varying amounts of success. However, since Hyprland is extremely
bleeding-edge, distros like Pop!_OS, Ubuntu, etc. etc. might have **major**
bleeding-edge, distros like Pop!\_OS, Ubuntu, etc. might have **major**
issues running Hyprland.
# Installation
@ -14,34 +17,33 @@ issues running Hyprland.
Installing Hyprland is very easy. Either you install it from your local package
provider (if they provide pkgs for Hyprland) or you install/build it yourself.
**Notice:** Given this project is under development and constantly changing, if
{{< hint title=Note >}}
This project is under development and is constantly changing. If
you want to keep up to date with the latest commits, please consider updating
your packages with `yay -Syu --devel`, or your other preferred package manager.
{{< /hint >}}
## Packages
**WARNING:** I do not maintain any packages. If they are broken, try building
from source first.
## Arch Linux
{{< tabs "uniqueid" >}}
*AUR:*
{{< tab "Arch Linux" >}}
*If you're on Arch Linux, I* ***heavily*** *recommend you use the AUR.*
```
```plain
hyprland-git - compiles from latest source
hyprland - compiles from latest release source
hyprland-bin - compiled latest release
```
{{< /tab >}}
*If you're on Arch Linux, I* ***heavily*** *recommend you use the AUR.*
{{< tab "Nix" >}}Read the [Nix page](https://github.com/hyprwm/Hyprland/wiki/Nix).{{< /tab >}}
{{< tab "Fedora" >}}<https://github.com/hyprwm/Hyprland/discussions/284>{{< /tab >}}
{{< /tabs >}}
## Nix
Read the [Nix page](https://github.com/hyprwm/Hyprland/wiki/Nix).
## Fedora
[https://github.com/hyprwm/Hyprland/discussions/284](https://github.com/hyprwm/Hyprland/discussions/284)
## Manual (Releases)
@ -65,7 +67,9 @@ libwlroots), you don't need to update anything else.
*Arch dependencies*:
`yay -S gdb ninja gcc cmake libxcb xcb-proto xcb-util xcb-util-keysyms libxfixes libx11 libxcomposite xorg-xinput libxrender pixman wayland-protocols cairo pango`
```plain
yay -S gdb ninja gcc cmake libxcb xcb-proto xcb-util xcb-util-keysyms libxfixes libx11 libxcomposite xorg-xinput libxrender pixman wayland-protocols cairo pango
```
(If any are missing hmu)
@ -78,9 +82,7 @@ that (`gcc>=12.1.0` or `clang>=15`)
### CMake (recommended)
then...
```
```Plain
git clone --recursive https://github.com/hyprwm/Hyprland
cd Hyprland
sudo make install
@ -88,33 +90,31 @@ sudo make install
### Meson
then...
```
```plain
meson _build
ninja -C _build
ninja -C _build install
```
Refer to Debugging to see how to build & debug.
Refer to [Debugging](../../Contributing-and-Debugging) to see how to build & debug.
## Crashes at launch
## Crash on launch
See the log, `cat /tmp/hypr/[INSTANCE_SIGNATURE]/hyprland.log`
*If you are unsure of the signature, grab the one thats the most recently
*If you are unsure of the signature, grab the one that's the most recently
modified.*
Diagnose the issue by what is in the log:
- `sWLRBackend was NULL!` -> launch in the TTY and refer to the wlr logs in RED.
- `Monitor X has NO PREFERRED MODE, and an INVALID one was requested` -> your
monitor is bork.
monitor is borked.
- Other -> see the coredump. Use `coredumpctl`, find the latest one's PID and do
`coredumpctl info PID`.
- failing on a driver (e.g. `radeon`) -> try compiling with
`make legacyrenderer`, if that doesn't help, report an issue.
- failing on `wlr-xxx` -> try compiling with `make legacyrenderer`, if that
`make legacyrenderer`. If that doesn't help, report an issue.
- failing on `wlr-xxx` -> try compiling with `make legacyrenderer`. If that
doesn't help, report an issue, and also refer to the TTY wlr logs in RED like
in the first point.
- failing on `Hyprland` -> report an issue.
@ -125,7 +125,7 @@ cd into the hyprland repo.
for legacy renderer:
```
```plain
sudo make clear && sudo make config && make legacyrenderer && sudo cp ./build/Hyprland /usr/bin && sudo cp ./example/hyprland.desktop /usr/share/wayland-sessions
```
@ -133,7 +133,7 @@ _please note the legacy renderer may not support some graphical features._
<br/><br/> Any other config: (replace \[PRESET\] with your preset, `release`
`debug` `legacyrenderer` `legacyrendererdebug`)
```
```plain
sudo make clear && sudo make config && make [PRESET] && sudo cp ./build/Hyprland /usr/bin && sudo cp ./example/hyprland.desktop /usr/share/wayland-sessions
```
@ -143,7 +143,7 @@ To apply custom build flags, you'll have to ditch make.
Supported custom build flags:
```
```plain
NO_XWAYLAND - Removes XWayland support
```
@ -153,13 +153,13 @@ Go to the root repo.
Clean before everything and config the root:
```
```plain
make clear && sudo make config
```
Then, configure CMake:
```
```plain
mkdir -p build && cmake --no-warn-unused-cli -DCMAKE_BUILD_TYPE:STRING=Release -D<YOUR_FLAG>:STRING=true -H./ -B./build -G Ninja
```
@ -170,7 +170,7 @@ You can of course also change the `BUILD_TYPE` to `Debug`.
Now, build:
```
```plain
cmake --build ./build --config Release --target all -j 10
```
@ -178,7 +178,7 @@ If you configured in `Debug`, change the `--config` to `Debug` as well.
Now, of course, install manually.
```
```plain
sudo cp ./build/Hyprland /usr/bin && sudo cp ./example/hyprland.desktop /usr/share/wayland-sessions
```

View file

@ -4,18 +4,26 @@ After you've installed Hyprland, you can either launch it from a TTY with
supported, I recommend `SDDM`, as it's been working flawlessly with wayland
compositors.
It is recommended you have `kitty` for terminal access, (example and autogenerated configs have it bound to SUPER+Q) or for you to manually change it in the config before launching hyprland.
It is recommended you have `kitty` for terminal access, (example and
autogenerated configs have it bound to <kbd>SUPER</kbd> + <kbd>Q</kbd>).
Alternatively, manually change it in the config before launching Hyprland.
If you have an Nvidia card, please also take a look at [The nvidia page](https://github.com/hyprwm/Hyprland/wiki/Nvidia) before launching. You should **first** make a wrapper, as described in the section below, then follow the instructions from the Nvidia page, and then continue on with sections below.
If you have an Nvidia card, please also take a look at
[The Nvidia page](../../Nvidia) before
launching. You should **first** make a wrapper, as described in the section
below, then follow the instructions from the Nvidia page, and then continue
on with sections below.
## Wrapping the launcher (recommended)
With Xorg, you get the `.xinitrc`. With Hyprland, you can create your own... kind of.
With Xorg, you get the `.xinitrc`. With Hyprland, you can create your own...
kind of.
Make an executable file somewhere in your `PATH`, for example `~/.local/bin/`, called (for example) `wrappedHl`
Make an executable file somewhere in your `PATH`, for example `~/.local/bin/`,
called (for example) `wrappedhl`
In it, put:
```
#!/bin/bash
```bash
#!/bin/sh
cd ~
@ -25,9 +33,13 @@ export XCURSOR_SIZE=24
exec Hyprland
```
you can add as many exported envvars as you need (nvidia users might need a lot), but I recommend to have *at least* the shown two. You can also change the shell you launch this with, although it shouldn't matter.
You can add as many exported envvars as you need (Nvidia users might need a
lot), but I recommend having *at least* the shown two.
You should now launch Hyprland with `wrappedHl` instead of `Hyprland`. Make sure to edit your .desktop file in `/usr/share/wayland-sessions/` if you use a login manager! (You might need to put the full path in it, as login managers are usually not ran through the user account)
You should now launch Hyprland with `wrappedhl` instead of `Hyprland`. Make
sure to edit your `.desktop` file in `/usr/share/wayland-sessions/` if you use
a login manager! You might need to put the full path in it, as login managers
are usually not ran through the user account.
## Immediate
@ -49,36 +61,40 @@ Use `hyprctl monitors` to list available outputs.
Then, you can configure your outputs with
```
```bash
hyprctl keyword monitor NAME,RES@HZ,OFFSET,SCALE
```
`NAME` is the name of the display, e.g. `DP-1`, can be empty for a global rule.
`NAME` is the name of the display, e.g. `DP-1`. Can be empty for a global rule.
`RES@HZ` is the resolution and refresh rate, e.g. `1920x1080@144`
`RES@HZ` is the resolution and refresh rate, e.g. `1920x1080@144`. Can be
`preferred` for auto-detection.
`OFFSET` is the position of the monitor, e.g. `0x0`
`OFFSET` is the position of the monitor, e.g. `0x0`. Can be `auto` to
automatically add it to the right of the viewport.
`SCALE` is the display scale, e.g. `1`
example command:
```
```plain
hyprctl keyword monitor DP-3,1920x1080@240,1920x0,1
```
**Warning!** These changes are **not** permanent! If you want to make those
{{< hint type=important >}}
These changes are **not** permanent! If you want to make those
changes persist, configure your outputs in the config!
{{< /hint >}}
# Proper configuring
Head onto the
[Master Configuring Wiki Page](https://github.com/hyprwm/Hyprland/wiki/Configuring-Hyprland)
[Configuring Hyprland page](../../Configuring/Configuring-Hyprland)
to learn all about configuring Hyprland to your likings.
# Apps / X11 replacements
See the [Useful Utilities Page](https://github.com/hyprwm/Hyprland/wiki/Useful-utilities) and the
See the [Useful Utilities page](../../Useful-Utilities) and the
[Sway wiki page](https://github.com/swaywm/sway/wiki/Useful-add-ons-for-sway)
just about that.
@ -94,11 +110,11 @@ Exit hyprland, and then:
- `cat /tmp/hypr/$(ls -t /tmp/hypr | head -n 1)/hyprland.log | grep monitor`
will give you a bunch of logs about the connected monitors. Names like `DP-x`
or `HDMI-x` etc are your monitor names.
- edit (with your favorite text editor) `~/.config/hypr/hyprland.conf`
- edit `~/.config/hypr/hyprland.conf`
- replace the `monitor=` line with `monitor=NAME,RES@Hz,OFFSET,SCALE`, for
example `monitor=DP-1,1920x1080@60,0x0,1` (See the above section titled
Monitors for more info about the values) You can also add multiple of those
for multi-mon setups.
example `monitor=DP-1,1920x1080@60,0x0,1` (See [Monitors](#monitors) for
more info about the values). You can also add multiple of those
for multi-montor setups.
After this, upon launching Hyprland again, provided you set an appropriate mode
for your monitors, everything should be fine.
After this, upon launching Hyprland again, everything should be fine,
provided you set an appropriate mode for your monitors.