Suckless - "Do one thing and do it well"

Discussion in 'Everything else' started by ClockworkCoder, Jan 24, 2018.

  1. ClockworkCoder

    ClockworkCoder Chaotic Neutral

    Joined:
    Jan 21, 2016
    Messages:
    1,097
    Location:
    Menzoberranzan
    I've recently come across suckless.org. Initially attracted by st (simple/suckless terminal), and I like the philosophy: no bloat, and if you want extra features, or to configure anything, then you have to build your own version.

    They also have a windows manager (dwm) which intrigues me, and browser (surf) amongst others.

    As I'm now more seriously trying to get in to c/c++, and also that I like minimalism, seems an ideal place to get to grips with hacking existing code, "best practices", etc. Part of this motivation is that I'd like to contribute, if I can, more proactively towards development/software for the Pyra (and other, Arduino-based hardware).

    What's everyone opinion on suckless? Do they apply good programming principles? Are there other similar/better sets of libraries?

    https://suckless.org/
     
    Last edited: Jan 24, 2018
    Tags:
    rygD likes this.
  2. Caine

    Caine Hardcore Member

    Joined:
    Jun 5, 2008
    Messages:
    4,081
    Location:
    Netherlands
    I have not studied their code, though I do use some of their tools in combination with Awesome Wm.

    Do one thing and do it well is the Unix philosophy, which is not unreasonable.

    Don't over-focus on good principles, just get started. That way you build up experience and develop a feeling of why those principles may or may not be a good idea.
     
  3. ClockworkCoder

    ClockworkCoder Chaotic Neutral

    Joined:
    Jan 21, 2016
    Messages:
    1,097
    Location:
    Menzoberranzan
    Of course, you're correct. My title is a little misleading. Probably the suckless philosophy goes a bit further, as it's designed for and by programmers, and many people dislike the lack of config files.

    Technically I think I'm also "cheating" by using tmux (with tmux-urlview) on top of st to add scrolling and link navigation...

    Sound advice, thanks. I'm also well aware that Google, StackExchange, et al are enemies of well written, secure code. I'll try to avoid getting into bad habits though: spent too long retaining myself in the past with other languages to go through that again.
     
  4. Magic Sam

    Magic Sam Forever Homebrew

    Joined:
    Aug 10, 2007
    Messages:
    2,214
    Location:
    Innsmouth, MA
    Hi all :)

    I stumbled upon suckless.org some time ago, and it indeed looks like an interesting project (I disagree with some of their opinions though: https://suckless.org/sucks/). I even started to port most of their tools to the Pandora at some point. If there is any interest from the community, I'll resume my work on that package ASAP.

    WARNING - SELF PROMOTION: @ClockworkCoder : if you are into minimalism, you might also want to try Plan 9 and / or Inferno on the Pandora:

    http://repo.openpandora.org/?page=detail&app=plan9port-magicsam
    http://repo.openpandora.org/?page=detail&app=inferno-magicsam

    Cheers, Magic Sam
     
    rygD, ___, Alperoot and 1 other person like this.
  5. JDTAY

    JDTAY Half Pepperoni, All Cheese

    Joined:
    Sep 15, 2015
    Messages:
    710
    Location:
    North Carolina, USA
    Awww man, I've been meaning to find ways to suck less, but using C instead of C++ and finding a compiler other than GCC? Sucking less seems pretty hard. :(
     
    rygD likes this.
  6. PowerGod

    PowerGod Advanced Member

    Joined:
    Jun 20, 2011
    Messages:
    3,041
    You didn't posted the link :eek: how can I click it ?! o_O
     
  7. Elw3

    Elw3 ƐʍlƎ

    Joined:
    Jul 21, 2013
    Messages:
    955
    On the bright side: You cant suck more.
     
    rygD likes this.
  8. ClockworkCoder

    ClockworkCoder Chaotic Neutral

    Joined:
    Jan 21, 2016
    Messages:
    1,097
    Location:
    Menzoberranzan
    Sorry about that :)
     
  9. JDTAY

    JDTAY Half Pepperoni, All Cheese

    Joined:
    Sep 15, 2015
    Messages:
    710
    Location:
    North Carolina, USA
    Okay, so um, I'm ready to try sucking less, and suckless recommends tinycc to do so. I wanna start using tinycc, but the git at http://repo.or.cz/w/tinycc.git doesn't appear to have any binaries, which brings me to a question... Would it suck to use a non-tinycc compiler to compile tinycc? >_>
     
  10. Yori

    Yori Hi, how was your day?

    Joined:
    Oct 9, 2016
    Messages:
    98
    Location:
    Venice, Florida
    Tcc is wonderful and I have been using it my self for my own projects.
    '-run' is one of the best features of it in my opinion :D!

    You can find prebuilt binarys at: https://bellard.org/tcc/

    but if you need c++ I would look at using Clang.
    It's faster & a bit more user friendly than GCC.

    The one thing I have to agree with suckless is that C/C++ build systems suck.
    Man Cmake can be pain at times.

    For smaller tools I make for my self I just write in one file and have no build system.
    But if I need one I use make.
     
    Last edited: Jan 24, 2018
    rygD and ClockworkCoder like this.
  11. edgex004

    edgex004 Advanced Member

    Joined:
    Jan 5, 2008
    Messages:
    1,166
    I use some suckless tools on the Pandora, such as dmenu. I tried compiling surf for the Pandora, but couldn't get it to work.
     
    rygD likes this.
  12. ible

    ible professional vim user

    Joined:
    Mar 24, 2014
    Messages:
    2,174
    Location:
    Seattle, WA
    i wanted to build my own text editor, and sandy was a nice starting point for ideas, though i think i'm going back to building somewhat from scratch. (also a project on the backburner.)

    i didn't like how they integrated it with the dmenu thing, i wanted everything to be in-terminal. in fact, i dislike almost everything about dmenu. i prefer opening up a terminal for any new commands, where i have my custom bash functions and PATH at the ready.

    i like the philosophy, though, i guess...?
     
  13. Grench

    Grench Forum Addict!

    Joined:
    Oct 3, 2008
    Messages:
    6,139
    Did anyone else assume this topic was spam until they saw the posted by user name?
     
    CommanderB, Klumpen and PokeParadox like this.
  14. levi

    levi Still fresh, damnit!

    Joined:
    Oct 6, 2008
    Messages:
    11,230
    Location:
    Somewhere off the coast of the EU
    My github repo is full of things that I took so a certain point then gave up on. I should really try to stick with one thing until it works at the very least. One of my bigger projects is stuck in merge resolution hell after I backed out of a big design change. A few are really screaming out for GUIs but at least they so something useful in the terminal. And others are just false starts that never went anywhere - I should really delete those or find some way to hide them better.
     
  15. rygD

    rygD Nihilistic Mystic

    Joined:
    Feb 28, 2014
    Messages:
    7,360
    Location:
    Everywhere
    When I am checking for spam I first look if the avatar is a Pyra keymat. If not, certain username patterns are common. In the end I always check the post (and sometimes poll).

    Plus I had come across suckless before. Also The Fuck.
     
  16. Young Ace

    Young Ace Still Fresh

    Joined:
    Oct 20, 2015
    Messages:
    12
    Location:
    United States
  17. pmprog

    pmprog Advanced Member

    Joined:
    Apr 25, 2011
    Messages:
    3,861
    This always makes me chuckle. I think I remember the Roslyn dotNet compiler said it was compiled by itself, I was like "So you can run source code directly on the CPU now?" :)
    The compiler always has to be compiled by something other than itself... At least in the very first instance, then I suppose you could use your new compiled version to recompile the source to give you another version
     
  18. ClockworkCoder

    ClockworkCoder Chaotic Neutral

    Joined:
    Jan 21, 2016
    Messages:
    1,097
    Location:
    Menzoberranzan
    That's a useful one, although using something like 'oops' may be more work safe.
     
    Yori likes this.
  19. ClockworkCoder

    ClockworkCoder Chaotic Neutral

    Joined:
    Jan 21, 2016
    Messages:
    1,097
    Location:
    Menzoberranzan
    That's like reprap 3d printers...

    Or similarly, Quines https://en.m.wikipedia.org/wiki/Quine_(computing)
     
  20. rygD

    rygD Nihilistic Mystic

    Joined:
    Feb 28, 2014
    Messages:
    7,360
    Location:
    Everywhere
    I have been in workplaces where I never heard oops, but the expected word was pretty common. I guess it depends on the people.
     

Share This Page

Loading...