Sway on Arch Linux: Installation and Configuration

Поделиться
HTML-код
  • Опубликовано: 31 янв 2025

Комментарии • 115

  • @diego_sandoval
    @diego_sandoval  3 года назад +16

    If Alacritty doesn't want to launch, it's probably because you haven't created the /etc/locale.conf file.
    That file defines your language, for example, if you want English US, the file should contain the following line:
    LANG=en_US.UTF-8
    After you create it, reboot and log into Sway. Then, Alacritty should work correctly.

    • @mumin1643
      @mumin1643 3 года назад

      not work alacritty. i use foot

    • @whodis5774
      @whodis5774 2 года назад +1

      @@mumin1643 I had a similar issue here,
      I simply had not set the right $term variable in .config/sway/config.
      It was just trying to open a terminal that is not installed on my system...

  • @okdoomer620
    @okdoomer620 4 года назад +7

    You've got to be kidding me... This is pretty much the perfect tutorial for me, it actually got kind of spooky when you swapped escape and caps, and deactivated mouse acceleration (I guess you are a vim user and play first person shooter as well)... Thanks, you saved me a lot of time!

  • @Rand0081
    @Rand0081 3 года назад +2

    Thanks to this video I finally approached the world of tiling WMs, and I've learnt how to manage configuration files.
    A note for anyone who may need it: if after reboot you find that fonts and graphics are all blurred, just remove the --custom flag.

  • @HashCollision
    @HashCollision 3 года назад +1

    Thank you. This helped me get Sway up and running without first having to scroll through hundreds of lines of documentation, on that note; I appreciate that you showed where the doucmentation is. Most channels just regurgitate old information without ensuring accuracy and relevance let alone pointing users to good sources. Earned a sub

  • @VZR_
    @VZR_ 2 года назад

    this has been the most useful linux tutorial i've seen in awhile, great stuff bro

  • @Spectrsounds91
    @Spectrsounds91 3 года назад +1

    Thank you for this video which is easy to understand and follow. Everybody's talking how Wayland is unstable and and all, but so far, out of all WMs, Sway worked without any problems on my hardware!

  • @Octelly
    @Octelly 3 года назад +7

    quick, concise and to the point
    impressive stuff, good job!

  • @nkozi
    @nkozi 2 года назад +1

    This is such a good tutorial! I'm making the switch to Linux and wanted to use Arch/Sway- this was so easy to follow even with my rasp-pi only Linix experience

  • @user-tm3fz7qx3s
    @user-tm3fz7qx3s 4 года назад +11

    This guy knows what he's doing! Please share this video!

  • @DevilDriver665
    @DevilDriver665 4 года назад +16

    Nice, sway videos are hard to find. Keep em coming. Btw :x is faster than :wq ;-) I know its a habit once you get used its hard to get rid of...

    • @vikassm
      @vikassm 4 года назад

      I'm an absolute beginner to linux and coding, tips like these help quite a lot!! Thank you

    • @xXUkanlosXx
      @xXUkanlosXx 2 года назад

      Then try the key combination ZZ. Does the exact same as :x you save one keystroke and prevents one more potential miss on the keyboard. ZQ is the equivalent to :q!

  • @scottkiesling1661
    @scottkiesling1661 Год назад +1

    Nice tutorial, very clear! Thanks so much for making it.

  • @bertkortenbosch9485
    @bertkortenbosch9485 2 года назад +1

    Tried the setup at 19.03.2022 on VirtualBox on an Intel PowerBook, do not forget enable 3D acceleration in the display setting, not doing so will not give you the sway background.
    Also alacritty is not the default terminal program anymore it is foot, so also install foot, otherwise keying mod enter will not give you a terminal.
    Thanks for the video it is a great introduction to sway and using a tiling window manager

  • @Oswee
    @Oswee 4 года назад +4

    Great video. Just switched to sway on Fedora and like what i see. :) This was pretty helpful.

  • @shashanksharma21
    @shashanksharma21 4 года назад +6

    super useful and very detailed. Thank you! subscribed right away :)

  • @MormonJesus69420
    @MormonJesus69420 3 года назад +1

    Thank you very much for this video, it was very easy to follow, it was good at introducing the basics in accessible format, even to people like me who have zero experience with Wayland and other Window Managers like i3. You also give good information and pointers to go further into the topic and learn more about Wayland. I think I'll give it a try, it might not be my number one environment to work in, as i still like KDE Plasma a lot, but i think it's gonna be nice to know something more lightweight like Sway

  • @nodidog
    @nodidog 2 года назад +1

    Thanks! I was having a hard time with absolutely tiny text on a 4k monitor. Very helpful 👍

  • @夕阳-n1h
    @夕阳-n1h 3 года назад +1

    Great video 👍
    To the point and clear audio and video with timestamps

  • @booga2059
    @booga2059 10 месяцев назад +1

    Great tutorial, learnt a lot from that, thank you.

  • @maximus6884
    @maximus6884 Год назад +1

    This is still a fantastic video!!

  • @drjscheur
    @drjscheur 3 года назад +1

    Really like this video - keep up the good work - Thank you !

  • @aalokthakkar7884
    @aalokthakkar7884 3 года назад +1

    Excellent. Donno why you have so few subscribers.

  • @56phil020244
    @56phil020244 2 года назад +2

    Great video. Thank you.

  • @lorenzocabrini
    @lorenzocabrini 4 года назад +2

    A bit late to the comment section perhaps, but from the first time I installed it, I've been in love with Sway. Similar to i3, but not at all as laggy. I'm too old to play around with window managers, I just need something that fits my workflow and Sway is exactly that.

  • @Slyndc
    @Slyndc Год назад +1

    We need you to make more videos 👋🏽

  • @momomaniac1234
    @momomaniac1234 3 года назад +1

    Thank you so much i learned much from this video 😃

  • @luthfisolahudin8850
    @luthfisolahudin8850 4 года назад +2

    This is very helpful. Thank you

  • @cosmicvoid2207
    @cosmicvoid2207 4 года назад +2

    This channel is going to be a rising star!
    By the way, is setting it up the same on other distros? Specifically, I want to install it on Gentoo but I'm still not sure. Any thoughts?

    • @diego_sandoval
      @diego_sandoval  4 года назад +2

      Thanks. To be honest I have not used Gentoo, so I don't know about that.

  • @imnemo2327
    @imnemo2327 2 года назад +1

    Fantastic!! Thanks a lot

  • @davidharder4588
    @davidharder4588 4 года назад +1

    Thanks for the walk-through

  • @see-sharp
    @see-sharp 3 года назад +1

    Amazing video man, thank you

  • @nobodystech
    @nobodystech 3 года назад +1

    Very useful bro!

  • @SirFisho
    @SirFisho 4 года назад +2

    Awesome video, i think i will give sway and wayland a try after watching this!!
    Could you make a video to show how to get a display manager like lightdm or sddm? Booting in a tty isn’t really “stilish” ahah

    • @baka_geddy
      @baka_geddy 3 года назад

      Use ly display manager

  • @archttila
    @archttila 4 года назад +1

    Very useful guide!
    Thanks mate :)

  • @jegkompletson1698
    @jegkompletson1698 4 года назад +1

    Amazing vid mate, cheers!

  • @wxtlpog
    @wxtlpog 3 года назад +1

    When I typed "sway" into my terminal, my everything froze. Is that supposed to happen?

  • @caleb.39
    @caleb.39 3 года назад +1

    Hey, I seem to not be able to open the alacritty terminal, when I press windows + enter nothing happens, but when I press windows + "any number" it does change the workspace. I thought it was a problem with recognizing the mod key, so using the arch tty I changed it to the Alt like you did on 3:25, but I still have the same problem, if I press Alt + enter nothing happens, but if I press Alt + "any number" it changes the workspace. Do you have any idea on what might be wrong?

    • @diego_sandoval
      @diego_sandoval  3 года назад +1

      Yes. I do have an idea of what it could be. I think the problem is that Alacritty doesn't find the /etc/locale.conf file
      Log into Arch and before launching sway, do this:
      1. Create a file in /etc/locale.conf
      2. Put the following contents in the file:
      LANG=en_US.UTF-8
      If you want another locale, obviously replace en_US.UTF-8 with your preferred country and language.
      These actions need to be run as sudo.
      Then, reboot, log into sway and everything should work fine.
      Tell me if it worked.

    • @caleb.39
      @caleb.39 3 года назад +1

      @@diego_sandoval Wow, it worked, thank you and also thank you for the quickness to reply. I had just given up and installed dwm on xorg, now I have two window managers xD. I thought I already had created locale.conf like that, but maybe I put it in a wrong directory or something. thank you so much

  • @sardinesardine2824
    @sardinesardine2824 3 года назад +1

    Thanks great video ! :)
    Just a small critics : next time add the keyboard layout configuration step first for the none qwerty keyboard user :)
    add to /home/user/.config/sway/config :
    input * xkb_layout "fr" # "fr" for french, "de" for Gemany...

  • @abhishekmore6674
    @abhishekmore6674 4 года назад +2

    Hello,
    Great video I did the arch installation on my Virtual box and followed this tutorial for sway and really appreciate the video, I'm having a problem where mod + Enter key won't work to bring up the terminal.
    But using mod key to switch my workspace works greatly can you please help here and even if I try to run Alacritty terminal using wofi launcher or using the mod + Enter it won't come up.
    A help would be appreciated.
    Thank You!!!!!

    • @diego_sandoval
      @diego_sandoval  4 года назад +2

      I think I had this same problem at some point. I think the problem is that Alacritty doesn't find the /etc/locale.conf file
      Log into Arch and before launching sway, do this:
      1. Create a file in /etc/locale.conf
      2. Put the following contents in the file:
      LANG=en_US.UTF-8
      These actions need to be run as sudo.
      Then, reboot, log into sway and everything should work fine.

    • @abhishekmore6674
      @abhishekmore6674 4 года назад +2

      @@diego_sandoval Great Cheers!!!! Thank You for your help this helped me. Great channel expecting more such videos 👍🏼...🍻

  • @noel_curray
    @noel_curray 2 года назад

    It has an error when I try to run `sway`
    I install `pacman -S polkit` and it `sway` run.
    next problem is that + key doesn't show the terminal.

  • @MrFooSteven
    @MrFooSteven 3 года назад

    Great video man. I've recently finished installed Arch 2 days ago, and using Gnome 3.38 and the default 'Mutter' WM. How do I go about changing the start up from that to run Swap when linux boots?

  • @daol03
    @daol03 3 года назад +1

    how do you setup audio and brightness keys on sway when using a laptop?

  • @JWayn596
    @JWayn596 3 года назад +1

    How did you get Alacritty to work in Virtualbox if Virtualbox's graphics driver doesn't have OpenGL 3.30? When using Virtualbox and Arch I have to switch the terminal to Termite for the terminal to work in SwayWM.

    • @diego_sandoval
      @diego_sandoval  3 года назад +2

      It used to work, and now it doesn't work by default. I don't know if Virtualbox changed or Alacritty, but I found a fix:
      I add the following line to /etc/environment:
      LIBGL_ALWAYS_SOFTWARE=1
      And then Alacritty launches correctly (after rebooting).

    • @JWayn596
      @JWayn596 3 года назад +1

      @@diego_sandoval OKAY! So after some tinkering, before starting sway, you have to copy the config file and edit it before starting sway, from there, you have to add LIGL_ALWAYS_SOFTWARE=1 before the selected terminal emulator (alacritty).
      EXAMPLE IN SWAY CONFIG: set $term LIBL_ALWAYS_SOFTWARE=1 alacritty
      This way you don't have to set this environment variable for the entire system but alacritty will still work in sway.
      I'm sure you could add that to the entire environment, thanks for that! This is just an alternate way I found. Thanks again!

    • @GFUNKzero
      @GFUNKzero 3 года назад +1

      @@diego_sandoval I had the same issue, I also had to add a variable to get the mouse cursor to show in virtualbox:
      WLR_NO_HARDWARE_CURSORS=1

  • @Moister356
    @Moister356 2 года назад

    Fantastic video man, mannage to get it working on Void. One problem I'm have only with Sway is lxappeareance not saving it's configuration. It just resets back to the original state like nothing happen. Is there a way to get gapps working with Sway like with I3-Gapps too? They are way too close to each other for my liking.

  • @CristianMolina
    @CristianMolina 3 года назад

    On dual GPU machines, like laptops with Intel+Nvidia, Sway does not support NVidia and don't detect correctly my Intel card. ... I'm still trying with commands like " WLR_DRM_DEVICES=/dev/dri/card1 sway "

  • @misaroorasim
    @misaroorasim 3 года назад

    For some reason I can't get my keyboard to respond on sway on my macbook running arch. Even with a USB Windows keyboard

  • @jaakkohintsala2597
    @jaakkohintsala2597 3 года назад

    is it possible to have both wayland and xorg on the same machine relatively painlessly?
    I am thinking of trying such a setup on my laptop (using either startx or sway after login)

  • @106perezbautistadidieralex2
    @106perezbautistadidieralex2 3 года назад

    Good evening, I would like to know how to set the keyboard in another language ... I tried to modify the .config file .... I look forward to your answers...

  • @nathanruben3372
    @nathanruben3372 3 года назад

    I planning to switch from kde to pure wayland sway environment. How can I hadle system tray?

  • @TheUros1234
    @TheUros1234 3 года назад

    After installing sway and alacritty and after running sway in terminal, my vm just froze ? It says on the top "Running" but it wont power up the sway ?
    Any idea why does it happens ?

    • @TheUros1234
      @TheUros1234 3 года назад +1

      Okay, i fixed it. In VirtualBox, you have to enable 3D Acceleration to make it work...

  • @ahmadyogi1340
    @ahmadyogi1340 3 года назад

    Is sway already has compositor? If it is, can the compositor be like picom, you know some fancy effects like blur, animation etc

  • @Becoming-Human
    @Becoming-Human 4 года назад

    @Root Labs , would you please consider creating a video that shows how to install the text based display manager, "Ly", (available in the AUR) in conjunction with Sway in Arch Linux? If "Ly" ends up not working out so well, then maybe show how to integrate SDDM or LightDM or tuigreet with Sway? Thank you, and great video! Also, bonus points if you can show Sway and Ly/SDDM/LightDM/tuigreet configured in Arch Linux using a ZFS root mirror installation! :-)

    • @diego_sandoval
      @diego_sandoval  4 года назад +1

      Thank you. I'll consider Ly for a next video (which may take long to publish, since I'm a little busy right now) but don't promise anything.

  • @Robertass2000
    @Robertass2000 3 года назад

    for some reasons bindsym Mod1+Ctrl+b does not work on debian11.

  • @MaKaNufilms
    @MaKaNufilms 4 года назад

    what am I doing wrong, if after running sway none of the shortcuts are working? Just installed with the bare arch (but in BIOS) and sway aswell alacritty

    • @diego_sandoval
      @diego_sandoval  4 года назад

      Mmm... to be honest, I don't know. Maybe something to do with your keyboard.

    • @MaKaNufilms
      @MaKaNufilms 4 года назад

      @@diego_sandoval sadly you are right, I have tested on a different system with ordinary Logitech K120 and it worked. Any suggestion to get my HyperX AlloyFPS running? Or no hope with this propretary shit?

    • @MaKaNufilms
      @MaKaNufilms 4 года назад

      Maybe I found a solution by myself: github.com/swaywm/sway/issues/3847 It sems to be the nrollover problem.

    • @diego_sandoval
      @diego_sandoval  4 года назад

      @@MaKaNufilms I don't know much about USB keyboards. Does the AlloyFPS work well under other desktop environments? Maybe it's a problem on the software side of the keyboard-OS communication.

    • @MaKaNufilms
      @MaKaNufilms 4 года назад

      @@diego_sandoval sadly don't have much experience beside windows with this keyboard

  • @lucygrund6060
    @lucygrund6060 2 года назад

    Me: *seriously considering using sway*
    Me: *also just wants to get the pc running again after the install was broken by a wild accidental sudo rm rf*

  • @SyedAhmed-lv3kh
    @SyedAhmed-lv3kh 3 года назад

    could you please help me, im not using a vm. Whenever i boot up sway i dont have a cursor. And another issue is that the waybar is way too big for my screen

    • @diego_sandoval
      @diego_sandoval  3 года назад +1

      about Waybar: I have another video in my channel where I show how to configure it, including the size. And about the cursor, I don't really know.

    • @carson5706
      @carson5706 2 месяца назад

      for cursor missing: `WLR_NO_HARDWARE_CURSORS=1`
      run sway example: `WLR_NO_HARDWARE_CURSORS=1 SDL_VIDEODRIVER=wayland _JAVA_AWT_WM_NONREPARENTING=1 QT_QPA_PLATFORM=wayland XDG_CURRENT_DESKTOP=sway sway --unsupported-gpu`
      it's better to save above as `~/launch_sway` and use tty login and then `source launch_sway`

  • @zx6407
    @zx6407 4 года назад

    please make a tutorial on how to use 'wallset' for live wallpapers on sway

    • @diego_sandoval
      @diego_sandoval  4 года назад

      I'm not a big fan of live wallpapers but I'll keep it in mind it if I make another sway video.

  • @noyalmessi1386
    @noyalmessi1386 3 года назад

    So next time I power on my PC will sway be loaded or should I type sway to launch it?

    • @diego_sandoval
      @diego_sandoval  3 года назад +1

      You need to type sway.
      If you want sway to be loaded automatically, you should look into installing a display manager.

  • @moris7361
    @moris7361 3 года назад

    installed this on an arch vm in VirtManager and everything looks washed out, does anyone have an idea why?

  • @Miguelocod
    @Miguelocod 4 года назад +1

    what advantages has Sway over i3?

    • @diego_sandoval
      @diego_sandoval  4 года назад +2

      The fact that it uses Wayland as a display protocol instead of X11.
      Wayland eliminates screen tearing and is the future of Linux, but not all apps run well with it and there's still no standard way to do screen-sharing and that sort of thing, so it's both an advantage and a disadvantage.
      If you have no problems with using X11, then it's totally fine (and probably better) to keep using i3.
      If you want to feel the warm and cozy feeling of knowing that your display protocol is well designed, then use Sway.

    • @Miguelocod
      @Miguelocod 4 года назад

      @@diego_sandoval great answer, I've read something about the Wayland and X11 issue, I might give Sway a try then.
      Really great content in your channel by the way, keep it up!

    • @diego_sandoval
      @diego_sandoval  4 года назад

      @@Miguelocod Thank you.

    • @Basheski
      @Basheski 3 года назад

      You could also install XWayland to get X11 compatibility when needed...
      btw, thanks for the very nice video!
      and.. another btw - maybe you can take a look at Wayfire (another Wayland-based WM - wayfire.org/)?

  • @ajinkyax
    @ajinkyax 4 года назад

    Can I install this if I have Manjaro gnome with non-free (nvidia) drivers

    • @diego_sandoval
      @diego_sandoval  4 года назад

      Sway doesn't support the proprietary Nvidia drivers, because Nvidia drivers use a different Kernel interface than all other graphics drivers in Linux. You can install the package, but it probably won't work.
      See more: github.com/swaywm/sway/wiki
      and drewdevault.com/2017/10/26/Fuck-you-nvidia.html (warning: strong language)

  • @captive8670
    @captive8670 3 года назад

    Can you test Wayfire on ArchLinux it's the same developer if i'm not wrong

  • @DrVektor
    @DrVektor 2 года назад

    can you make a tutorial about "Labwc" . Labwc is wayland clone of openbox. There is windows buttons and desktop rendering. more user friendly then this. i wanted to try but i didnt find any tutoriial. No one didnt tryed thank you.

  • @karlsonalex5026
    @karlsonalex5026 4 года назад +1

    +++ супер

  • @dragonek_gnu_linux_pl
    @dragonek_gnu_linux_pl 3 года назад

    hmmm.... we need to change alot of things in wayland before we switch from xorg lol. Ewerything is diffrent, apps etc.. For now i still want xorg

  • @jimxu1963
    @jimxu1963 3 года назад

    Does feel like i3

    • @diego_sandoval
      @diego_sandoval  3 года назад

      It was created as a Wayland replacement for i3.

  • @VidarrKerr
    @VidarrKerr 3 года назад

    LOL. You have to be joking me. "Alacritty is the recommended terminal for Sway". Alacritty doesn't even support Wayland. Which is what Sway IS FOR, running with Wayland. This sht cracks me up. Your video is really good though, that is not your fault.

  • @SyedAhmed-lv3kh
    @SyedAhmed-lv3kh 3 года назад

    and could you please upload these files on github!

    • @diego_sandoval
      @diego_sandoval  3 года назад +1

      They sway and alacritty config files are in github.com/sandov/sway-configs
      The repository also includes my custom waybar configuration files, but you can ignore those if you only want the configurations that I use in this video.

  • @afkhere4168
    @afkhere4168 Год назад

    rtfm

  • @LittleDavid85
    @LittleDavid85 3 года назад

    You are definitely not a Emacs user

  • @jimmihenry
    @jimmihenry 4 года назад

    WTF is Wayland???

    • @tru0067
      @tru0067 4 года назад +1

      Wayland is a protocol for how the compositor (in this case sway) communicates with its clients (terminals, browsers, anything you open in a 'window'). It is intended to replace the current protocol X11.
      Wayland has a couple of benefits over X11 (eliminates screen tearing, is generally faster, significantly more secure and will be easier to maintain), though it is still being developed. It should be noted that wayland is intended to be different from X11, so some things such as screen sharing/recording, as well as global hotkeys require substantially more effort to set up - this is a consequence of the increased security (any application having access to your entire screen or keyboard input is perhaps somewhat of a reasonable security concern).

    • @jimmihenry
      @jimmihenry 4 года назад

      @@tru0067 It is the successor to x window system. Thank you for clearing this up! :)

  • @71GA
    @71GA 3 года назад

    Useless... Tray does not work...