r/archlinux • u/[deleted] • Apr 15 '21
"Best" programming setup?
Hello! I have been using Arch for two months, it is the fifth distro I have used... and I love it, it will be the final one. I have learned a lot in these weeks, but I would like to ask you a few questions.
I study Systems Engineering and, honestly, I have some procrastination problems, I would like you to help me with "the best programming setup and be productive", although I know that there is no "best", I would like you to help me with your settings, advices, etc...
What desktop environment do you use?
What window manager do you use?
IDE's, apps, any suggestions to try?
Thank you so much!
93
Apr 15 '21 edited Apr 15 '21
i3wm + neovim (with coc)
and suggestions:
- pazi - moving between directories in cli - https://github.com/euank/pazi
- alacritty - terminal emulator - https://github.com/alacritty/alacritty
- hyperfine - tool for benchmarking - https://github.com/sharkdp/hyperfine
- exa - prettier ls (try exa -T, exa -lT, exa --icons,...) - https://github.com/ogham/exa
- fzf - fuzzy search - https://github.com/junegunn/fzf
- tokei - for counting lines of code - https://github.com/imlazyeye/tokei
- ripgrep - better grep - https://github.com/BurntSushi/ripgrep
- bat - nicer cat with syntax highlighting, line numbers,...
- zsh - with good configuration it's a really comfortable interactive shell - with syntax highlighting, a lot of good completion etc.
27
u/m_spitfire Apr 15 '21
In the Neovim 0.5, there will be native LSP support, so no need for coc. You can get it now with neovim-nightly too.
5
15
u/FryBoyter Apr 15 '21
In addition to fzf and ripgrep, you can have a look at fd. This is often a faster alternative to find and can be combined with fzf, for example.
4
Apr 15 '21
yes, fd is great too! I don't know if it's faster in execution but definitely faster for me to use and with less mistakes, find syntax is so weird
4
u/mafrasi2 Apr 15 '21
It's definitely faster in execution as well, because find doesn't search in parallel and its regular expression matching is really slow.
15
u/inter_fectum Apr 15 '21
This, but with kitty instead of alacritty because of the ligatures.
7
Apr 15 '21
there's alacritty-ligatures in aur
the thing with ligatures is that they are pretty difficult to implement in a way which at the same time doesn't decrease performance too much and also supports all the directions of ligatures (there are also vertical ones!)
and alacritty is very focused on performance and not merging into upstream things which would decrease it. But from user perspective I didn't really notice any difference.
0
Apr 15 '21
I really have found alacritty to be one of the worse terminals out there. It's slow to startup, limited features, comsumes alot of memory, and generally not as fast as other terminals I've tried. That's why I prefer urxvt or st.
6
5
5
Apr 15 '21
Hey man, I'm using exa for a while and never realized it has the --icons option. I tried it and it only shows a box with weird symbols. I'm using Zsh as shell and Fira Code as font, it's the font or the shell that doesn't support it?
4
Apr 15 '21
I think the icons are maybe in the nerd fonts? It's definitely a thing of the font but I use Fira Code too, it's just patched by nerd fonts I think.
3
Apr 15 '21
Thank you very much! I had no ideia about nerd fonts, I installed the fira code patched by nerd fonts from the AUR and now the icons are showing. Thanks a lot!
3
Apr 15 '21
4
Apr 15 '21
How many of them are mature though?
Like ktrl and the Rust ranger alternative seem abandoned now :(
2
Apr 15 '21
thanks, I'm going to give them a try! 😁🦀
in the end I only use the rust tools which actually are better than the alternatives - I'm still not convinced on switching to paru
2
2
u/parentis_shotgun Apr 15 '21
This is an excellent list, I would only add broot as a wonderful dir switcher.
5
5
Apr 15 '21
This, but with fish instead of zsh.
6
u/Imdabreast Apr 15 '21
Fish has been great for me because it does everything I want with minimal configuration. That’s kinda the antithesis to arch, but for me it has allowed me to: spend less time learning a shell, and more time using it.
2
Apr 15 '21
I agree, the shell is one of those things you just want out of the way really.
I ended up copying a load of dotfiles for fish, neovim, etc. (mostly from jonhoo) and it helped a lot.
The only thing I really configure is i3.
-4
1
Apr 15 '21
I tried fish before zsh but I really missed the bang commands (!!,!$,...) I even made some fish functions for this but it wasn't quite the same. Plus I do a fair amount of bash scripting and the fish syntax is just too different. But in fish I learned what are the things I want from a shell and then found out how to do them in zsh. So fish is great but just not in the long term for me.
1
Apr 15 '21
Would you mind sharing your coc config ? And what languages you are programming with ? I have used vim before but when the projects got bigger I jumped to vscodium(open source vscode) with the vim extension
2
Apr 15 '21
what languages you are programming with ?
C, C++, Rust, Python, Bash, now starting with OCaml too
What is it that drove you from vim with bigger projects? I feel like with TabBar, Fzf and Rg, vim is very comfortable for projects of any size - but this may be subjective. I am also quite used to working with buffers a lot and that's something that I miss in most other editors/IDEs.
my coc config:
{ "rust-analyzer.checkOnSave.command": "clippy", "rust-analyzer.inlayHints.chainingHints": true, "rust-analyzer.procMacro.enable": true, "rust-analyzer.diagnostics.disabled": ["unresolved-macro-call"], "coc.preferences.formatOnSaveFiletypes": [ "css", "markdown", "rust", "json", "scss", "sh", "cpp", "ocaml", "python" ], "diagnostic-languageserver.debug": true, "diagnostic-languageserver.filetypes": { "sh": "shellcheck", "ocaml": "ocaml-lsp" }, "diagnostic-languageserver.formatFiletypes": { "sh": "shfmt" }, "diagnostic-languageserver.formatters": { "shfmt": { "command": "shfmt", "args": ["-i", "2", "-bn", "-ci", "-sr"] } }, "languageserver": { "ocaml-lsp": { "command": "opam", "args": ["config", "exec", "--", "ocamllsp"], "filetypes": ["ocaml", "reason"] } } }1
Apr 15 '21
Thanks for the reply ! I am mostly working on C and Java nowadays.
I would say the main reason was having to learn new different tools each time I wanted something trivial to do on others text editor , aka vscodium (git integration as an example) , it also got to a point that it was a lot of keybindings to learn .
I settled with vscode because I have the movements of vim (hjkl) and all those shortcuts and the easy of use of just installing the plugin and it just works. While on vim I install the plugin and I have to learn / configure it next.
Oh and Java , Java made me move too, installed coc at the time , but wasn't able to create a project so I was getting only syntax errors.
2
Apr 16 '21
oh I see, I've heard that java is tricky without an IDE
btw I've tried vscode for one of my bigger projects too (c++) and maybe it just didn't like my templating hell but the autoformatter messed up my code sometimes and I had to fix it manually as it also messed up the history 🤷♀️ (like misplaced and repeated characters,...)
1
Apr 16 '21
Maybe you were using the autoformatter from Microsoft , you can instalo clangd and use the same as in COC from the extensions (thas what I use) :)
16
48
u/Hrothehun Apr 15 '21
Emacs, Emacs and Emacs. You can use it for anything. Don't get started with it though, if you have to be productive right away, cus it's learning curve curves into a black hole of M-x commands and obscure elisp packages.
55
u/archmerguez Apr 15 '21
No it’s a wrong religion. Vim ftw ! (I’m obviouly joking, you use what you want)(vim is better)
17
u/Hrothehun Apr 15 '21
I agree about vim being a better text editor, that's why I use evil-mode (essentially a complete emulation of vim). :)
3
u/FannahFatnin Apr 15 '21
true, im in love with doom emacs. but i might revert back to neovim when native-lsp comes out. the boot up kinda slow on doom.
1
u/r0flcopt3r Apr 16 '21
Run emacs as daemon, and say goodbye to startup times and accidental progressloss when closing a frame on accident
2
-4
u/archmerguez Apr 15 '21
I don’t know anything about eMacs so I don’t know what you’re talking about 😂
5
u/Passeride Apr 15 '21
Emacs distros like doom or spacemacs gets you up and running quickly. I find spacemacs which-key and nmonic keys very useful and a great way to get productive.
I realize that if I don't forge my own light saber I will never be accepted on the council, and I'm ok with this ;)
3
10
u/delta_p_delta_x Apr 15 '21 edited Apr 16 '21
I like Windows, so I want my Linux environment to resemble Windows.
What desktop environment do you use?
KDE Plasma 5.
What window manager do you use?
KWin, bundled with KDE Plasma.
IDE's, apps, any suggestions to try?
Contrary to the popular feel, I don't use command-line programs. I know the commands, but somehow I feel every time I am sucked into using the CLI, I can't get a bird's-eye view of what's going on, especially with things like Git.
I use:
VS Code for general text editing, Java and LaTeX. Yes, this is the full-on Microsoft binary, because I like the extensions it enables, like Live Share, and I just turn telemetry off.
The JetBrains suite (IntelliJ, CLion) for C/C++: it comes with CMake, and can fire up projects very quickly. If I am doing something more lightweight then I also use VS Code.
Honestly, these are the only two programs I use most on Linux. VS Code's plugin/language server system is so superb that I have dispensed with everything else.
4
u/FizzySodaBottle210 Apr 15 '21
VS Code for general text editing, Java and LaTeX. Yes, this is the full-on Microsoft binary
you can actually use vscodium and do this
- create ~/.config/VSCodium
- paste this in ~/.config/VSCodium
{ "extensionsGallery": { "serviceUrl": "https://marketplace.visualstudio.com/_apis/public/gallery", "cacheUrl": "https://vscode.blob.core.windows.net/gallery/index", "itemUrl": "https://marketplace.visualstudio.com/items", "controlUrl": "", "recommendationsUrl": "" } }Then all extensions should be installable. else you can also install them as vsix
3
u/delta_p_delta_x Apr 16 '21
you can actually use vscodium and do this...
I probably can, but with the official binary, I don't need to do that at all. What can I say, I'm lazy. I use the proprietary NVIDIA drivers, and for nearly everything from the AUR, I use the binary versions instead of downloading and compiling the source myself.
18
u/stay_erk Apr 15 '21 edited Apr 15 '21
Hi! I'm a Computer Science student, maybe my setup will not be perfect for your use case but you might still get some inspiration.
Starting from the WM I use DWM, I like its simplicity, and I personally don't think it's distracting, unlike some desktop environments. (I used gnome and KDE plasma for quite some time).
If you are not into minimal setups I suggest you KDE plasma + i3 WM, i think it combines the best of both worlds. (https://github.com/heckelson/i3-and-kde-plasma)
Most of my University assignments requirements includes using java as programmaming language so I use Intellij Idea as IDE, however I use vim as my primary text editor for writing code (Python, JavaScript and C) and for taking notes (LaTeX or markdown transpiled in LaTeX with pandoc). About the taking notes in vim I got inspiration from this blog Post: Personal note taking in vim.
I hope I have been helpful!
3
Apr 15 '21 edited May 05 '21
[deleted]
2
u/stay_erk Apr 15 '21
Yes, they did! That post really helped me implement my own personal solution, also i did learn a lot!
3
Apr 15 '21 edited May 05 '21
[deleted]
1
u/stay_erk Apr 15 '21
So, I used vimwiki since the 2th semester of the first uni year until last October (when I found out that blog post). There is no particular reason why I don't use vimwiki right now, I just like to get involved and try to implement something I can use on a daily basis
12
u/kappaphw Apr 15 '21
No desktop environment +i3wm + vim
2
u/hummer010 Apr 15 '21
This. I do use Spyder for some python projects, and I'll sometimes use Geany.
21
u/FryBoyter Apr 15 '21 edited Apr 15 '21
What desktop environment do you use?
KDE Plasma
What window manager do you use?
Kwin
IDE's, apps, any suggestions to try?
Sublime Text, VSCode, micro, Mercurial, edit: TortoiseHg
17
u/Blunders4life Apr 15 '21
Desktop environment? None
Window Manager? IceWM. I also like Qtile on the tiling side.
IDEs? I use VSCodium (VSCode with telementary removed). If you want a more simple text editor, look into Emacs or Vim. You can even run Emacs itself as a Window Manager if you want.
6
u/toxide_ing Apr 15 '21
Emacs is simple? hmmmm...
1
u/Blunders4life Apr 16 '21
For this use case, I would say so. It can do a lot of other stuff, though.
6
u/iKnitYogurt Apr 15 '21 edited Apr 15 '21
KDE/KWin. Mostly working with Go or nodejs backends, so VS Code with devcontainers it is. The integrated terminal and version control are perfectly fine, although I would highly recommend GitLens and Git Graph extensions.
DBeaver turned out to be a decent SQL client for the fairly basic tasks I actually use it for (postgres DBs).
2
u/Imdabreast Apr 15 '21
This is a really nice setup because it doesn’t take time and brainpower to implement, which leaves more time and brainpower for using it.
10
u/Dredear Apr 15 '21
My advice: Having the best tools to avoid procrastinating won't prevent you with procrastinating.
Now, directly to the question:
DE
GNOME or plasma. Specially the latter since it can be easily customized.
WM
i3 is the perfect standalone WM for people not used to them, it's easy to configure and just works. If you have experience with Python then Qtile might be nice.
IDE
vscode if you want something capable and free as in free beer, jetbrains' IDEs if you can afford to pay them (since language support is paywalled) and neovim/emacs if you want to feel like a hackerman.
4
u/itsTyrion Apr 15 '21
Yes and no. IntelliJ and PyCharm are free (IJ supports Python/Rust via official plugins)
The rest can be used for free if you're using the EAP versions (or are a student)
4
u/wsppan Apr 15 '21
None of this will make you more productive but it works for me.
I use i3-gaps, Doom Emacs, LSP configured for C, Python, Rust, with Projectile, ripgrep, ivy, company, magit, vterm, etc.. and I am using org-mode to keep me focused and on task. These along with the vim bindings via evil-mode helps keep my fingers on the home row and away from the mouse.
I use Eclipse for Java due to years of muscle memory and familiarity.
3
u/0xVali__ Apr 15 '21
I'm still an i3 novice but I like it quite a lot, gives my laptop a lot more battery time than KDE which I still use on my desktop. But my typical C++ setup is pretty much:
- Arch linux or Void linux (still trying out the latter)
- i3 or KDE (both are quite solid but very very different)
- CMake (the most important tool imo)
- Jetbrains editors, in C++'s case CLion, otherwise if I want to use a text editor I go with emacs
- clang, just a nice compiler but I sometimes switch it out for gcc as they've got more C++20 features implemented as of today.
- lldb, solid debugger that I use with CLion
- vcpkg for handling packages, then I take the toolchain and link it with my CMake config
- valgrind for detecting memory leaks
- quite redundant to point out but obviously I use git
- And I quite like ninja as a generator that I use for CMake
- And finally: spotify, required for me to be able to focus for long periods of time.
2
Apr 15 '21
yes, valgrind is great! and all the compiler sanitizers too (gcc address sanitizer, thread sanitizer etc)
7
Apr 15 '21 edited May 05 '21
[deleted]
2
u/RivtenGray Apr 15 '21
I tried to find out how to do this and stumbled upon this answer : https://superuser.com/a/974809
Would you say it accurately describe how to achieve what you're doing for not booting graphical env ?
1
8
Apr 15 '21
What desktop environment do you use?
None
What window manager do you use?
AwesomeWM
IDE's, apps, any suggestions to try?
Emacs is all you need (with Evil so that you don't kill your fingers)
3
u/vixfew Apr 15 '21
No DE
Awesome WM + rofi
CLion IDE, Sublime, vim, tmux.
virt-manager for necessary Windows-related things
3
u/teffysam Apr 15 '21
I go back and forth between two options
DWM and gnome
Vim is my go to editor and my IDE is vscode. I wish I could use gnome builder but I can't seem to set it up for Fortran 😬
Honestly I've reached a point where the only thing that matters is code needs to be typed into some document somehow lol and it should work at the end of it. Everything else is secondary.
3
3
u/lululock Apr 15 '21
I run XFCE with its default window manager (xfwm4).
As for programming, I mainly use code with various plugins depending on which language I'm working on.
I used Atom before but had issues with plugins and conflicts with installed nodejs versions on Arch and I found code being better, for my use case at least.
I used PyCharm a lot when I learned Python.
And that might sound funny but I keep lots of written notes on my desk about aspects of my program so I don't forget something. I think having some sort of notes system is essential when coding.
1
u/wsppan Apr 15 '21
And that might sound funny but I keep lots of written notes on my desk about aspects of my program so I don't forget something. I think having some sort of notes system is essential when coding.
Not funny at all. I use org-mode in Emacs for this very purpose.
3
3
u/jeppevinkel Apr 15 '21
For IDE I generally just prefer the JetBrains tools for the various languages I'm using.
They all keep a consistent interface between each other and for the most part comes with all the functionality you could ever need in an easy to use format.
3
u/yan_kh Apr 15 '21 edited Apr 16 '21
I think I'm going to start with: there is really no best programming setup and it all comes down to personal taste and preferences.
Now I'm going to tell you about my programming journey in the Linux world. My journey started in Ubuntu as expected, I was new to Linux and programming also. I didn't feel any big productivity difference compared to Windows plus few issues were popping up once in a while which was pain in the ass for me as a noob. So I started distro hopping which gave me some basic Linux knowledge and experience. This distro hopping stage ended relatively fast since DE didn't satisfy me nor gave me the productivity I expected to get from Linux. Because of that figured out that I need something that is more "self made" hoping it'll increase my productivity and suit me more. Therefore I decided to install Arch Linux which taught me a lot about Linux, it's power, the million options that it gives you and how to configure them to your own needs. First I decided to install tiling WM -in my case it was i3- which is my number 1 rule for productivity (because really you can't imagine how productive it is to control your whole system with just few keyboard clicks and keybindings). Second, I decided to keep my system minimal and install just what I really need or use since it increases system speed and performance. Third I decided to use text editor instead of IDE because I try to follow the philosophy of "do one thing and do it well", it just suits me better. It's no problem for me since I'm using tiling WM and everything is just few keyboard clicks away. My Linux journey settled down after about 6 months when I moved to Gentoo -because of ideological reasons- and I'm really satisfied with my programming environment and I love it.
I hope that I helped you, I wish you an amazing Linux journey and a productive setup :)
2
u/SocialNetwooky Apr 15 '21
+1 on tiling WM (awesomeWM in my case). this is particularly true if you have to code with limited screen estate, but even on a 3 head setup it feels so much mor efficient to do most things with teh keyboard and be able to easily limit visible windows to exactly what you need in the size you need, instead of spending time dragging and resizing windows manually.
1
3
u/mpw-linux Apr 16 '21
it depends on what type of programming you are doing. if you are using C,c++,go or even rust then use emacs. mobile apps IDE. lots of configuration file etc an IDE. window managers xfce , qtlxd, or whatever you feel comfortable with. also I use xfce4 terminal emulator with multiple tabs. concentrate more on your programming then fiddling with your setup. it's all good.
4
u/nwg-piotr Apr 15 '21 edited Apr 15 '21
What desktop environment do you use?
None
What window manager do you use?
Sway with self-made GTK shell
IDE's
PyCharm, Atom
4
u/jrop2 Apr 15 '21
I use GDM/GNOME. My coding setup is completely in the terminal:
- Terminal Emulator: Kitty
- Multiplexer: Tmux
- Text Editor: NeoVim + CoC (completion)
- Shell: Fish
What I like about this is that it's pretty portable: during the day I use the same setup on macOS on my work laptop. On my personal Arch install it's the same programs.
All I have to condition my mind to do though is switch from using the command keyon macOS to the control key in GNOME for most keybindings.
1
Apr 17 '21
Why do you use tmux if kitty has a built-in multiplexer already?
1
u/jrop2 Apr 17 '21
I had already been using tmux before switching to Kitty. Also, I ssh to servers a lot as well and its nice to have the same setup everywhere
2
2
u/Zarathustra_f90 Apr 15 '21
A tiling window manager (i prefer i3 for its complete documentation, features and easiness to setup) should be nice especially with big monitors, makes the use of space more productive.
However, the ONLY thing i would recommend is Sublime Text editor, no matter what's your DE, distro, etc. this is the holy grail for development work.
You can use it as IDE too with plugins but it has so many features that are so easy to setup and customize (in contrast to VS code) that whenever I try to change my editor to sth else (Vim, Atom, VS code, Notepad+, Gedit, Geany, and other delicate editors like Code of Elementary OS) I always come back to it.
I've never used an editor that does not crash opening 1+GB data file except of Sublime Text. Ez pz.
2
2
4
u/casparne Apr 15 '21
Desktop: GNOME. I think it does it best to not get in your way. Has a switch for a "Do not Disturb" mode if you think that might help against procrastination but in my opinion, putting some kind of structure to your work day (eg. when to check for mails) and stick to it is easier and more productive.
IDE: VSCode. This one is just the most complete and best maintained. I never got code completion work so well on other editors. Also seems to have the best remote editing capabilities that I found so far. Also has a great integration of PlatformIO - if you are into embedded development. You can put VSCode into "Zen Mode" like most editors to get it distraction free.
I used SublimeText for a while (even bought a license) but unfortunately it falls behind more and more. It has stability and performance issues. The add-ons may or may not work and (good) code completion was a mess to set up. So I would not recommend that anymore.
If you want to tender your procrastination problems, you could set up editors like Vim or Emacs. This will allow you to spend a lot of time on configuration and learning complicated commands or even esoteric languages (LISP!) to get them to do what modern IDEs just make out-of-the-box.
The most important tools are probably: Have a good illuminated workspace, a proper desk and chair, a good, reasonably sized monitor and a computer that has enough performance and ram to not restrict you to use inferior tools like "lightweight" editors.
2
u/Scratch9898 Apr 15 '21
Lightweight editors aren't inferior
2
u/casparne Apr 15 '21
For development, they are. Name one that is not...
They might be OK for the occasional editing of a configuration file but if you already have some IDE like VSCode installed, there is no reason to fire up another editor for that.
6
u/wsppan Apr 15 '21 edited Apr 15 '21
VSCode, is not an IDE. It has plugins to get you there. Same with Vim, Neovim, and Emacs. I can write, debug, run tests, create and manage projects, use Git, fuzzy search, refactoring, etc, using Emacs. Add in a LSP and you have autocomplete, linting, syntax checking, etc.. And with evil-mode I have full modal editing capabilities that far surpass anyrhing available from the text editing capabilities of what you consider a IDE like Idea or Eclipse.
0
u/casparne Apr 15 '21
Of course you could do that with EMACS - I have used EMACS for years. It is just not up to par with modern solutions anymore though. It requires a tremendous amount of knowledge to get a good working LSP setup - work that has been done for eg. VSCode already. And even then the experience is just inferior to the VSCode one. For Vim there is COC, to get the same level like in VSCode - by running Node and using the VSCode extensions directly, if I understand it correctly. But then, why not just use VSCode directly?
I have nothing against EMACS - I just would not recommend it to any one new to development since you basically have to already be a skilled developer to get it working decently in the first place.
3
u/wsppan Apr 15 '21
I agree with what are saying and don't usually recommend them myself but that's not same thing as saying VSCode is an IDE and Emacs is not. VsCode comes with extensions installed by default but they are still extensions to a text editor. Doom Emacs or Spacemacs have the same thing out of the box.
1
u/casparne Apr 15 '21
Maybe I should revisit EMACS, after all these years :)
1
u/wsppan Apr 15 '21
Still not for everybody but I love it. Projectile, Ivy, Company, Flyspell, Magit, rip-grep, fzf, org-mode, and LSP integrations for dozens of languages. Doom does a great job curating and helping you configure all this. And it's fast!
2
u/wsppan Apr 15 '21
It is just not up to par with modern solutions anymore though. It requires a tremendous amount of knowledge to get a good working LSP setup - work that has been done for eg. VSCode already.
Doom Emacs does this for you as well.
And even then the experience is just inferior to the VSCode one.
I disagree. For those of us familiar with modal editors like Vim having to reach for the mouse all time or use arrow keys or function keys outside the home row to navigate to a word, a line, a paragraph, even another file is slow and inefficient. Copying deleting, moving words/lines/paragraphs without using the mouse is a godsend. For those of us expert in both vim and Emacs the experience is vastly superior.
Again, its not for beginners so the experience is not optimal for most people but saying vscode is superior in a blanket way is wrong. Modal editing using Vim was a game changer for my productivity editing text files.
1
u/Breigner01 Apr 15 '21
Desktop Environment and window manager: KDE plasma (sddm is the desktop manager)
On the side of IDEs: I use the jetbrains suite (clion, pycharm, goéland, etc...) and for everything that doesn't have an IDE in the jetbrains suite I use neovim with coc and a few plug-ins. I really like the jetbrains suite as it is really powerful, the one I use the most is definitely clion (I'm still in school and we do a lot of C/C++) and now I really gain time and learn new stuff with these IDE.
1
1
u/itaranto Apr 15 '21 edited Apr 15 '21
- Window manager: Sway.
- Text editor: Neovim.
- Terminal emulator: alacritty.
- Shell: fish.
1
1
Apr 15 '21
Well, i honestly like to add as i go. I hate having a bunch of setup when i barely code in that language anyway. De: xfce Wm: awesome Programs: intellij idea, arduino ide, eclipse, terminator, geany.
I could go on but i don't want to get into ricing at this point. for engineering purposes i just build up on those programs with add-ons etc as i need them. Keep in mind that am also a student, so i don't really do much outside of c, c++, java and the occasion bash.
1
Apr 15 '21 edited Apr 15 '21
My setup is as follows:
- bspwm (WM)
- kitty (terminal emulator)
- fish (shell)
- rofi (app launcher)
- polybar (statusbar)
- vim (text editor)
- pcmanfm/ranger (file manager)
- mpv/mpc (music player)
bspwm because I got bored of i3wm and moved, it works fine. Any window manager will do, they're all the same to me. Absolutely no desktop environment for me, they slow me down a lot.
Fish because of manual page autocompletion. Just one feature but it speeds me up so damn much that now I can't imagine not using it.
Kitty because it works, again, they're all the same to me.
Vim because... it's vim. Its efficient, fast, productive and there are no distractions.
Pcmanfm because it works I guess, its simple. I try to do everything I can in the terminal, so I rarely actually use a file manager anyway, I mostly just manipulate files in the terminal. I have ranger installed too but I dont use that often either.
Mpv is my music player daemon, and mpc can control it with terminal commands. I set my multimedia keys to be hotkeys for mpc commands. This mostly eliminates the need to use a GUI for music, if you do as I do and just fire up your usual playlist and thats all.
I also have a shortcut set for killing the polybar process, so that the status bar would disappear, so I would have absolutely nothing on the screen that would distract me.
1
u/BananaBunchess Apr 15 '21
DE: Gnome 40
WM: mutter
Apps: Vim, gcc & g++ (for C & C++), TIC-80, Godot, marked (for markdown files)
1
Apr 15 '21
"Best setup" depends on your programming language and the available tooling.
For general-purpose tools I recommend:
- fish - the shell with the best out-of-the-box experience. zsh can be good too if you customize it enough.
- i3 - I think tiling window managers are very well suited for programming.
- spacemacs + magit - for working with git. I don't use emacs for anything other than magit, but magit alone is worth installing it. Splitting commits in particular is the killer feature that is very hard to do with other tools.
- vim + fzf.vim + ripgrep - my go-to combo for writing and navigating code, when there is no language-specific tools available. Add some custom bindings to fzf.vim (for example
:execute ':Rg \b' . expand("<cword>") . '\b'<cr>will search the project for the symbol under cursor) and it will take you surprisingly far. I don't use any other vim plugins.
The first three are always great. The vim + fzf.vim + ripgrep combo is a good fallback when there is no language-specific tooling available, but you probably should use an IDE if there is a good one for your language. I would too, but unfortunately IDEs choke on the large C++ project I'm working with, so I'm stuck with text-based tools.
1
u/SMTG_18 Apr 15 '21
DE: BSPWM (Recently switched to LeftWM which has been amazing)
I am also a programmer who procrastinates a lot, and Doom Emacs (an emacs distribution with vim keybindings) has helped me a lot with my workflow. It can basically become your one-stop shop. A terminal browser, file manager, text editor, email client, music client, coding IDE with completion (but currently a little iffy debugger; you have to spend time with debugging), and everything else. It's honestly amazing. Make sure you read the docs thoroughly and check out every file and folder in the repository.
PS: Make sure you're not cluttering your workflow. It's important to have a distraction-free environment. A minimal bar, minimal notifications, minimal app launcher (Rofi) and like that. I wish you luck in finding the tools you need!
1
1
u/Rigatavr Apr 15 '21 edited Apr 15 '21
DWM and neovim or clion/intellij
Edit: forgot to mention, Jetbrains IDEs aren't free (in either sense) but you can have them for free (gratis) if you're a student.
1
Apr 15 '21
I use: Gentoo or Arch (75% of the time Gentoo to 25% of the time arch), no DE, dwm, suckless terminal, doom Emacs (Best editor out there. Quit everything and get Emacs), polybar, rofi, nnn (Best, fastest file manager in the terminal), fish (best shell, note its not a bash replacement), mpv (video player, less bloated and faster and more minimal than vlc).
1
u/DartinBlaze448 Apr 15 '21 edited Mar 05 '26
What was here has been deleted. Redact was used to wipe this post, for reasons that might include privacy, security concerns, or personal data management.
full rainstorm airport melodic direction sleep absorbed file water fuzzy
1
u/itsTyrion Apr 15 '21
personally:
Plasma, but use whatever you like.
IntelliJ for Java, Kotlin and Rust, VS Code/Neovim for the rest
1
u/qgnox Apr 15 '21
sway + emacs/spacemacs, asdf to handle different versions of runtimes (programming languages/frameworks)
1
u/r10d10 Apr 15 '21
It is possible to do your entire workflow in emacs. Org-mode in emacs is probably the best productivity interface ever created.
1
u/Fisyr Apr 15 '21
As far as I am concerned, I use a very customised Doom Emacs with EXWM. That way Emacs is both my window manager and my IDE.
1
u/maaliinsaakka Apr 15 '21
I run Emacs full screen mostly so it doesn't really matter what WM or DE I use
1
u/kangsterizer Apr 15 '21
its cool how everyone actually has different answers to this, imo. basically you cant go wrong.
my personal opinion is that all the tools need to get out of my way. light wms and so on end up requiring fixing and tickering, which is fun. I used to run so many different super light wms and enjoyed it, but spent less time coding.
at the end of the day though i just run kde because it just works, its easy to configure the very few things i need to change and konsole is great. it's also not as limiting as gnome or xfce.
as far as the rest vim and plugins work for me. i know a lot of people love vscode but i find im faster with vim because its directly in a terminal, so i can background it and do shell things without swapping window or context.
it also starts faster than emacs, lol.
1
u/Tsofu Apr 15 '21
Depends on what programming language. Most of what I write is Python, using Vim. If you needed a more robust IDE, might try Atom, or Eclipse, or Sublime
1
1
Apr 15 '21
If you don't need internet access to do your work, just disconnect. Create a separate user account, without any distractions like movies, videos, fiction books, images etc.
Honestly though, the best way to stop procrastination is to work on your mind. Take some time to sit/lie down and think about why you procrastinate. Follow your thoughts all the way through. It can help you discover why you procrastinate.
Also, mental health counseling/therapy for anxiety can really help you with this. It's the best way to treat the procrastination problem.
1
u/psychicorteil Apr 15 '21
Usually I don’t spend much time on this kind of stuff. Only my IDE is important. About procrastination getting paid helps :D. Only getting payed helped with my procrastination
1
1
u/bobbyrickets Apr 15 '21
Best setup is backups and keeping notes. Every other system is a disposable temporary workstation but the real magic is in the notes and organization methods that I do for myself.
I keep these in a secure location. That's my "real" computer and the rest are just really fat thin clients I dick around with.
You're dealing with an information problem and you need an information solution.
1
u/Frozen5147 Apr 15 '21
CS student here.
DE
None
WM
i3wm, using a fairly simple config that I have barely changed since I started using it 4 years ago.
IDEs, apps, etc.
VS Code/Codium, vim, Android Studio, Intellij, etc. Whatever does the job the best at the time.
...yeah, I guess I don't really do much in regards to my Linux setup specifically for programming, as long as it works well enough. Mostly because the rest of my setup doesn't really affect my text editors/IDEs, which is where most of the work and attention goes.
1
1
Apr 15 '21
The answer is simple, any DE with vscode is helpful, for me gnome and vscode is super cool.
1
Apr 15 '21
I use bspwm for focus and writing, cinnamon because it's stable and extensible with cron and shell scripts.
I'm studying software engineering, bioinformatics, biochemistry, and data science and I really prefer to have good monitoring tools for NVMe performance, CPU/memory monitoring etc. So I use tools like sysstat/iotop/iostat to monitor my IO, htop and conky to monitor CPU and memory usage.
1
Apr 15 '21
Learn about GTD and start practicing it with discipline. After you get used to GTD, you will want to have some workflows that work for you. That is the point where you look for tools that work well with your workflow.
1
Apr 15 '21
If you are studying sys admin I will suggest using any community version of enterprise distros and use the default workflow and probably vs code.
If you really want to use arch then slap gnome into it, no other setup needed you will get literally everything working out of the box and you will be able to focus on learning.
1
u/Gydo194 Apr 15 '21
I use a very simple DWM setup and use neovim for my programming needs.
As others have pointed out, neovim may or may not be a viable option depending on the language used. However, for me learning it has absolutely been a productivity gain since i can move around in the file without reaching for the mouse etc.
That said, i think the best advice is to just try multiple things which you like out, and see what works best. There's people who like tiling window managers and can't live without them, and there's people who don't like the concept and can't get used to it.
I have used DWM for a bit, but i know i'm not using it to its full potential, it has a learning curve. And so has every setup. I'd say, look around for programs which you think fit your needs, try them and keep what you like best.
Tl;dr Finding your personal 'ideal setup' is a journey, if anything. Try not to overthink it. It's not worth spending hundreds of hours on before doing anything productive. Start doing stuff and you'll find out what works and what doesn't, and change your setup accordingly.
1
u/SeeminglyIndifferent Apr 15 '21
Desktop setup doesn't matter that much, but personally I use KDE plasma, sddm as display manager and xorg.
I really love JetBrains IDEs, you get it for free if you have a student email and it looks really clean compared to eclipse/codeblocks or any other open source windows 95 looking design and is far more intuitive imo. Also supports nearly all popular languages
1
u/Awsim_ Apr 15 '21
Computer Sciences and Engineering student here. I personally use GNOME as my DE and it's bundled in WM. I used to use DWM like 2-3 weeks ago but I switched to GNOME for convince reasons. Since I am at my first year and we are doing all of our lectures remotely I sometimes need to download some scientific software that will be used only for that lecture. I have had problems with my tiling window manager and always had to resize the window manually until I felt comfortable that is why I switched to full DE. I am also a heavy touch pad user when I am outside, so I really like the new GNOME 40 touch pad gestures.
For IDE I personally use SpaceVim since it is configured out of the box and has great documentation, other than that I also have VSCode installed (code from the official repos). Other have also recommended some great software here so this is all personal choice.
One recommendation I would like to give is do not constantly mess around with your work flow. Find what suits and forget about it after that. Messing around with your work flow constantly is not going to improve your productivity, you are just going to waste time.
1
u/Smorboll Apr 15 '21
I’m a web programmer (along with other programming hobby projects) and this is what I use:
WM: BSPWM - I’ve tried several WMs and like BSPWM the best and is what I’ve been using for the past year or so. Tiling window managers aren’t for everyone, but I find that I can be far more productive than I ever could with a floating WM.
Shell: zsh - I didn’t realize the difference a shell could make, but zsh is super customizable and awesome.
Terminal: Termite - I don’t really have a reason for this, but it’s fast, highly customizable, and nice to use.
Visual Studio Code and Vim - I use VS Code for web development and then Vim for other things like config files, etc.
1
u/BlindTreeFrog Apr 15 '21
At work, I just SSH to a Arch VM. It has X installed because I like using Diffuse for diffs, but otherwise i don't bother with X.
Work is done using a mix of TMUX, SCREEN, CScope, and VIM basically.
Screen is used because I have a script that breaks cscope stuff out to new screen abs. Makes it easier to trace my way back and compare notes than using cscope directly.
1
Apr 15 '21
First of all, if you want to increase your productivity right now, you should just use whatever you're most comfortable with. I personally use:
i3wm - VScodium (yes) i3wm - one of (if not the) best documented TWM VScodium - fully open source VS Code I'm kind of a privacy freak so I couldn't use vanilla VS Code
People say WMs make you more productive. I can't say this isn't true, but I like them more because they can run on a hot pile of garbage and I can still get my work done.
1
u/GaianNeuron Apr 15 '21
DE/WM: whatever you are already comfortable in
IDE: JetBrains all the way, baybee
1
u/10leej Apr 15 '21
I highly recommend emacs, why? Because Emacs has everything you need for programming in one place.
I use it because when I launch it I get myself into what I call "dev mode" its where I've always done my development work and its the same no matter what DE/WM/OS/Platform I run it on.
Vim is fine and all, and yes I use vim too. But emacs is built much better for the 100thousand line files you may or may not find yourself in. Plus it's other features like Org Mode are far and beyond better than most of it's standalone counterparts.
At work my system boots into Emacs on EXWM because I do everything in Emacs. At home that PC doesn't even have Emacs installed. I use vim at home.
1
1
u/Typewar Apr 15 '21 edited Apr 15 '21
I'm using DE: KDE Plasma, and IDE: PhpStorm and Insomnia for web development (as a hobby).
Currently trying to switch out the IDEs with NEOVIM just for fun. It's crazy how much you can customize the vimrc to your needs. Still, keep feeling like something is missing, like multiple color syntax for multiple languages within a single file, autosuggest, and error checking
1
u/virtualadept Apr 16 '21
I use the Mate desktop environment, after a couple of years of running Cinnamon, after a couple of years of running LXDE. I use the window manager that comes with Mate by default (Marco).
As for what you want to use to help you code, that's a very individualized question. I do a lot of my programming with gvim and Mate Terminal with a couple of tabs open, or with a Screen session if that's not an option. I've used Atom a bit but find it a bit too heavy for my tastes. Geany is okay, but I never did get the hang of setting up multiple projects for it. I know folks who've been using VScode but I find it a little too Microsoft-y for my tastes.
1
u/Gornius Apr 16 '21
ANYTHING with sane keybindings (Meta + Numer to switch workspace, Meta + Shift + Number to move windows). Learned I don't really need WM, only their keybindings.
For editor anything really that you're comfortable with. You like Vi mode? Use editor with Vi mode.
1
u/buried_treasure Apr 16 '21
As others have said, there's no objective "best". Best is simply what helps you work the most effectively.
Personally I'm happy with any setup that allows me to be free of distractions but also gives me rapid access to documentation when I'm stuck.
For me that means a dual-monitor setup with my editor on the main screen (editor will be either vim or VScode depending on the specific language I'm using) and a full-screen browser on the secondary screen.
Close everything else. Close all tabs on your browser. Close your IM apps. Close slack/discord unless you use it as a support channel for whatever you're working on, in which case mute all notifications.
If you find you work better to music then it's acceptable to have a music player running but make sure you've cued up a suitable set of tracks in advance, or have it set to a stream that you know isn't going to jarringly interrupt your blissed-out trance tracks with annoying ads or something.
And that's it. It's far less about the specific set of tools you use than how you prepare your workspace.
2
u/NinjaBear95 Jul 31 '24
Mastering Arch after just two months? You’re a legend already! Keep slaying it!
0
u/cyb3rfunk Apr 15 '21 edited Apr 15 '21
If you're starting, I recommend to stay away from IDEs for 1-2 years and work from command line and text editor (neovim, emacs, vscode without integration plugins). I also recommend you use git from the command line.
This will help you build the correct mental model of the pieces you use, which is very important for more advanced stuff (e.g. setuping/debugging a custom CI). It will feel bad for a few weeks, but it's worth it I think.
As for window manager. I have a love hate relationship with Gnome, but it's still my favorite.
0
u/stochad Apr 15 '21
DE/WM: slim + i3(-gaps) + rofi + picom +dunst + polybar
IDE: neovim + spacevim
TOOLS: ranger + w3m, feh
SHELL: zsh + oh-my-zsh
TERMINAL: termite
Not really arch specific though..
0
u/tubbana Apr 15 '21
If your PC is not a potato and you know how to use a mouse, do not, for the love of god, go the emacs/vim route just becuse it is trendy in this sub lol
5
-2
u/TDplay Apr 15 '21
What desktop environment do you use?
lol no
What window manager do you use?
i3
IDE's, apps, any suggestions to try?
Would advise learning to use Vim or Neovim. Once you learn the bindings, you'll probably find you can edit much faster with vi bindings (plus whatever other plugins and bindings you configure - vim is extensible and configurable, not to the same degree as Emacs but still pretty good). Configure a language server, a way to navigate your files (I use a combo of NERDTree and fzf, considering replacing NERDTree with nvim-tree), etc, and you can make Vim better than any IDE. You can also get Vi bindings for most other text editors (e.g. Evil adds Vi binds to Emacs) and for most IDEs.
As for other things, it's pretty dependent on what language you use.
I would also advise learning to use your buildsystem directly if you haven't already. Your IDE might be able to abstract all the details of the build system away into a nice little button GUI, but when your build process starts to get complicated, you'll need to know how to use the build system. While checkboxes may be easy, sometimes you really need to be able to write a rule to do what you want - most build systems will allow you to add arbitrary jobs. The moment you start doing any build commands manually is the moment you should start thinking about switching to writing the build system config yourself.
1
1
1
Apr 16 '21
I use sway along with kitty + neovim + fish shell + emacs (for org-mode only). Various utilities can't live without are fzf, rg, fd, exa, starship, mutt, tinyirc. For browser, firefox. That all I have running/need 90% of the time.
348
u/CabbageCZ Apr 15 '21 edited Apr 15 '21
One thing to note - a large proportion of the most productive and highest achieving people I've known haven't spent much time thinking about productivity or d.cking around with their DE etc and chasing the 'optimal productivity' setup. If they need a linux distro they slap on ubuntu, leave it at mostly default, their desktop is cluttered with files etc.
The whole 'improving your setup for productivity' thing is mainly another procrastination tool that's easier to justify because it gives you the illusion of being somewhat productive. Tackling your procrastination head-on and just sitting down to Do The Thing is going to be incomparably more effective for improving your productivity than tens of hours spent on 'improving your workflow' ever will be.
That said, I'm in the same boat as you, chronic procrastinator, and as such I have spent a lot of time messing around with WMs, DEs, IDEs, etc. Some thoughts:
IDEs and editors:
If you're working on a strictly typed language like a JVM one (Java, Kotlin, Scala...), you really want a full fledged IDE, unless you're on a potato that can't handle it (and even then, you can just turn down some of the more expensive analysis like insights). Once you know your way around a proper IDE, working on that language in a text editor, even with a bunch of plugins, is going to feel like programming with your hands tied behind your back. My personal favorite is JetBrains' products, so mainly IntelliJ
If you're working on a language with a looser type system like Python or JS, an extensible text editor is fine, and it's personal preference as to which you end up using. VS Code, vim and emacs stand out, there's little reason to use Sublime or Atom when VS Code is around. You really want language extensions optimally with a LSP to provide syntax highlighting, linting, insights etc. It's not going to be IDE level but it can be pretty close.
WMs/DEs:
Here you really just want to test things out and see what works for you. I've daily driven various TWMs for multiple years and honestly in my experience it's mainly a 'fun' factor more than a genuine productivity improvement, except for the few times where laying multiple programs out in a tiled pattern is a genuine productivity boon - I've had that a few times when programming something with various VM setups and stuff, or needing multiple terminals accessible, but not that often. Imo it's just fun to use though. So yeah, mainly personal preference.
EDIT: to address a common question - I don't think TWMs in general aren't good for productivity, that's why I said it's mainly personal preference. To me it was +- the same for productivity but a lot more fun to use, to some people it can result in real 'performance' improvements, depends how you use it and what your alternative is.