12 votes

What programming/technical projects have you been working on?

This is a recurring post to discuss programming or other technical projects that we've been working on. Tell us about one of your recent projects, either at work or personal projects. What's interesting about it? Are you having trouble with anything?

21 comments

  1. [4]
    goose
    Link
    On my Windows hosts, I use Cygwin as my pseudo-Linux shell, plus my preferred ssh client to my Linux hosts. On my Linux hosts, I use Debian, and can use the netselect-apt tool to find the fastest...

    On my Windows hosts, I use Cygwin as my pseudo-Linux shell, plus my preferred ssh client to my Linux hosts.

    On my Linux hosts, I use Debian, and can use the netselect-apt tool to find the fastest aptitude mirrors for me.

    I was wondering if there's a similar tool for Cygwin mirrors. Some google-ing led me to a very old Sourceforge perl script, which did not work for me.

    So I whipped a modernized python script to serve the purpose, instead!

    https://github.com/goose-ws/cygwin-mirror-test

    11 votes
    1. 0x29A
      Link Parent
      I love those moments where something you need doesn't exist and that is the impetus for creating it, which then everyone can benefit from. Solid!

      I love those moments where something you need doesn't exist and that is the impetus for creating it, which then everyone can benefit from. Solid!

      3 votes
    2. [2]
      qwed113
      Link Parent
      I'm not sure if it would suit your needs, but have you looked into using WSL2 (Windows Subsystem for Linux) instead of using Cygwin? It puts a native Linux system right inside your Windows OS that...

      I'm not sure if it would suit your needs, but have you looked into using WSL2 (Windows Subsystem for Linux) instead of using Cygwin? It puts a native Linux system right inside your Windows OS that you can easily access with Windows Terminal. Performance is excellent and it allows you to use all your favorite linux commands

      2 votes
      1. goose
        Link Parent
        I've heard of this, yes, but haven't looked into it. I've been using Cygwin for my needs since sometime around 2012? Given it already does what I want it to do, I didn't see a need to switch, even...

        I've heard of this, yes, but haven't looked into it. I've been using Cygwin for my needs since sometime around 2012? Given it already does what I want it to do, I didn't see a need to switch, even for a more "native" solution.

        1 vote
  2. [5]
    kari
    Link
    I've mentioned this on here a couple of times before, but I've been working on a window manager for the River Wayland compositor's newly-stable river-window-management protocol to write my own...

    I've mentioned this on here a couple of times before, but I've been working on a window manager for the River Wayland compositor's newly-stable river-window-management protocol to write my own window manager, beansprout.

    Right now, it's not really daily-driveable, but you can actually spawn tiled windows and move them between tags, select different tags, etc. Ultimately, I'm probably just going to recreate most of the existing functionality in what is now called river-classic's WM (with a master-stack layout), but I'll see where it takes me.

    Specifically, the most recent thing I've done has been working on adding support for a config file. I decided to go with kdl for the config language and I'm using this parsing library to handle it. I still need to figure out how to actually handle keybinds in kdl but I think I came up with an idea before bed last night that I'm going to try to implement after work today.

    Also, I always forget how much I enjoy writing Zig. It just feels so good to write to me.

    6 votes
    1. [4]
      ogre
      Link Parent
      This is awesome! Was it easy to get started with the river protocol or did it take some work to navigate because it’s still pretty new? Kdl is a good choice for config. I would’ve gone down a...

      This is awesome! Was it easy to get started with the river protocol or did it take some work to navigate because it’s still pretty new?

      Kdl is a good choice for config. I would’ve gone down a custom config DSL rabbit hole and never get to the actual window manager part :P

      Thanks for pinging me to keep me updated! I’m glad you’re able to work on passion projects outside of work. And using zig. Because it is the best language.

      2 votes
      1. [3]
        kari
        Link Parent
        The harder part to start was probably just remembering how to work with the Wayland, to be honest. The protocol is pretty decent at explaining what the event loop is/should be so once I got a few...

        Was it easy to get started with the river protocol or did it take some work to navigate because it’s still pretty new?

        The harder part to start was probably just remembering how to work with the Wayland, to be honest. The protocol is pretty decent at explaining what the event loop is/should be so once I got a few of the basic bits set up (and looked at some other WMs), the protocol has become fairly straightforward. The people on the river IRC channel are all pretty helpful for the couple of questions where I genuinely had no clue what to do on my own.

        I would’ve gone down a custom config DSL rabbit hole and never get to the actual window manager part :P

        I feel like I'm still spending a lot more time than I expected on the config part xD but I'm enjoying what I've got so far.

        1 vote
        1. [2]
          ogre
          Link Parent
          Hah, small world, I tried to answer one of your questions in the zig IRC but quickly hit the limits of my experience with the language. This made me check your codeberg, you’ve got quite a few...

          Hah, small world, I tried to answer one of your questions in the zig IRC but quickly hit the limits of my experience with the language.

          The harder part to start was probably just remembering how to work with the Wayland, to be honest

          This made me check your codeberg, you’ve got quite a few Wayland programs, that’s sick. There’s a whole bean ecosystem lol.

          1 vote
          1. kari
            Link Parent
            Haha yeah, but I’m hoping to integrate beanbag and beanclock into this wm at some point. Beanbag I initially just made as a clone of wbg written in Zig because it sounded fun but beanclock was...

            There’s a whole bean ecosystem lol

            Haha yeah, but I’m hoping to integrate beanbag and beanclock into this wm at some point. Beanbag I initially just made as a clone of wbg written in Zig because it sounded fun but beanclock was just something I actually wanted!

            1 vote
  3. [3]
    Apos
    Link
    I participated in a local gamejam as a team with 3 other people two weeks ago. (We were 3 programmers with 1 guy also doing the music + sound effects, and 1 graphics artist.) We had 40 hours from...

    I participated in a local gamejam as a team with 3 other people two weeks ago. (We were 3 programmers with 1 guy also doing the music + sound effects, and 1 graphics artist.) We had 40 hours from start to finish.

    Today they announced the winners and my team got second place which gave us a prize of $1k. That was pretty awesome considering I pretty much forced (joke) the others to learn to work with MonoGame on the spot. Our artist had never worked on a game before but she was a beast. Our composer had a sort of synthesiser keyboard which was really cool.

    MonoGame is a code first approach to making games unlike something like Unity that provides a visual editor. (Though I personally find it a lot easier to work with than Unity. You don't tend to fight MonoGame the same way, it mostly stays out of your way.)

    The theme for the jam was "ship" so we made a sort of space invader-based game where you have to defend earth from aliens. Each wave, you can spend your money to build a town. The buildings were a house to get more HP, a mining rig for passive income, a bank to get paid more per alien kill, a windmill to shoot faster, a cannon that can auto shoot.

    The balance wasn't perfect but we finished the game loop, had a fully functional menu with keybind options and credits, no game breaking bugs.

    In total, 17 teams participated in that gamejam. It was crazy because 40 hours is already short but the rules also required us to make a trailer and a document to explain the game, the way we created it, etc.

    5 votes
    1. [2]
      Zorind
      Link Parent
      I’ve now seen monogame pop up in a couple comments across tildes and/or mastodon, and would love to hear more about your thoughts on using it. I’m a software developer professionally, and have...

      I’ve now seen monogame pop up in a couple comments across tildes and/or mastodon, and would love to hear more about your thoughts on using it.

      I’m a software developer professionally, and have dabbled with Godot on the side just for fun, mostly when work is slow & not exercising the programming part of my brain. I’ve been thinking about maybe looking into Monogame instead, and was wondering if there were any helpful resources you used for it, or any thoughts you might be willing to share about your experience using it?

      2 votes
      1. Apos
        Link Parent
        I've been using it since 2016 though I used XNA before that around 2013. If you just want to get started quickly, check out their 2D tutorial. It's really high quality. What I like about MonoGame...

        I've been using it since 2016 though I used XNA before that around 2013. If you just want to get started quickly, check out their 2D tutorial. It's really high quality.

        What I like about MonoGame is that it's real C#. You don't have to fight an editor or layers of abstraction. If you want to create a quick little game, you can have all your code be in a single file if you want. How the code is organised is completely up to you. Using MonoGame makes you become a better coder.

        The MonoGame community is really nice. There are people that spend hours helping others that are stuck. It's also inspiring to see what everyone is working on. It feels like the early Internet.

        The MonoGame project is rather conservative, it's really rare that the API breaks between versions. This means that it's rather trivial to support a game over many years. (Also this means that 10+ years old tutorials are still relevant.)

        Overall I'd say go for it. The cost of entry is really low.

        1 vote
  4. [2]
    UntouchedWagons
    Link
    Earlier this evening I worked on changing a docker container I made to be based on Alpine 3 instead of Debian Trixie, reducing image size from 72MB down to 7MB

    Earlier this evening I worked on changing a docker container I made to be based on Alpine 3 instead of Debian Trixie, reducing image size from 72MB down to 7MB

    5 votes
    1. goose
      Link Parent
      Nice! I recently submitted a PR to a repo for an image I use, switching to to alpine/nginx/php-fpm, and trimming the image from 500 MB down to 80 MB. Hoping the author accepts it!

      Nice! I recently submitted a PR to a repo for an image I use, switching to to alpine/nginx/php-fpm, and trimming the image from 500 MB down to 80 MB. Hoping the author accepts it!

      2 votes
  5. [2]
    rungus
    Link
    I made online chess - it's chess but online. I only have the one board though, so you'll all need to share. This is by far the dumbest thing I've ever made but I had fun making it. Currently the...

    I made online chess - it's chess but online. I only have the one board though, so you'll all need to share.

    This is by far the dumbest thing I've ever made but I had fun making it. Currently the cooldown for moving pieces is 1 second which should (hopefully) become longer as more people make moves. Makes for some interesting gameplay.

    Future plans so far may be to restrict players to only be able to move one side's pieces, and maybe a democracy mode. Not sure yet though.

    4 votes
    1. Weldawadyathink
      Link Parent
      This is interesting! Fun little toy. Did you program in castling? I tried to short castle black, but it didn’t give me the option. It’s possible that the king or rook moved back to the original...

      This is interesting! Fun little toy.

      Did you program in castling? I tried to short castle black, but it didn’t give me the option. It’s possible that the king or rook moved back to the original space, so I can’t say for sure if it was a bug. Perhaps a move history list could be a useful feature?

      Ninja edit: looks like castling is there, so black must have moved back home. I was able to long castle white a few turns later.

  6. ShroudedScribe
    Link
    I set up a pretty convoluted chain of systems to get my internal git repository activity statistics on my website and updated daily. It involves grafana, python, podman, and some other...

    I set up a pretty convoluted chain of systems to get my internal git repository activity statistics on my website and updated daily. It involves grafana, python, podman, and some other integrations. I wrote a blog post on the whole thing.

    2 votes
  7. em-dash
    Link
    I'm writing firmware for my little combat robot control board. It's a STM32 microcontroller, an ELRS radio receiver, 8 half-bridges of onboard motor drivers (configurable for whatever arbitrary...

    I'm writing firmware for my little combat robot control board. It's a STM32 microcontroller, an ELRS radio receiver, 8 half-bridges of onboard motor drivers (configurable for whatever arbitrary combination of motors one wants to attach to them), and some extra PWM outputs for controlling servos or bigger motor drivers (the onboard drivers are intended for wheel motors; spinny weapon motors typically want more power than they can provide). The whole thing is a few square centimeters, the size of a Malenki Nano but with more stuff shoved into the same space. Designing PCBs zoomed in on a large screen and then seeing them at actual very-tiny size in your hands never ceases to be a weird experience.

    I started out wanting to play with embedded Rust and Embassy, but the Rust toolchain seems to not get along with this board for whatever reason, and I decided I really just wanted to get on with making thing go spinny instead of debugging that, so I fell back to C++. I don't actually need an RTOS for what I'm doing, I suppose; as long as I can run the main loop at a few hundred hertz

    The other problem I have is that I only ordered a pile of 3.3V voltage regulators because the board is mostly 3.3V, but the radio receiver needs 5V, so I haven't gotten the remote control part working yet. So tonight I am going to order some of the 5V ones, and then probably do a ridiculous bodge involving very thin wires to get 5V to the receiver, so I can start on the code to talk to it.

    2 votes
  8. skybrian
    Link
    My personal link website is coming along well. It now links directly to the Tildes “post a new topic” forms (when logged in as me) and I save links there before posting them here. Links are tagged...

    My personal link website is coming along well. It now links directly to the Tildes “post a new topic” forms (when logged in as me) and I save links there before posting them here. Links are tagged similarly to Tildes, with special support for “facets” such as hierarchical place names. There is no full-text search yet, but you can search on tag names.

    You can view it at skybrian-links.exe.xyz and here’s an example search result for artificial intelligence, metaphors. (One day I decided to collect all the commonly used metaphors like “stochastic parrot.”)

    Shelley and I have implemented 19 design docs so far. I’ve gotten in the habit of asking it to make mockups before implementing new UI features. Sometimes it’s a bit rubbish at coming up with good designs, but then we iterate.

    Pretty soon I want to start back-filling the links I’ve posted to Tildes over the years so I have more data to play with.

    2 votes
  9. ivanb
    Link
    "Working on" is probably an overstatement in my case as I've been stuck in the ideation phase, but I've felt for quite some time now that online communities will shift more and more towards small...

    "Working on" is probably an overstatement in my case as I've been stuck in the ideation phase, but I've felt for quite some time now that online communities will shift more and more towards small private groups. And while solutions abound for preexisting groups (Discord, Slack, etc), there's no way to find new ones.

    For example, I'm very interested in biographies of people who pushed forward our approach to food but are largely forgotten (such as Nicholas Saunders). If I meet someone interested in the same, I would probably like to discuss broader topics with them: restaurant and book recommendations, traditional food from their place, etc. It's these "very specific" interest that often act as strong indicators of broader alignment.

    Right now, you have three options:

    1. Posting on reddit and such, which is obviously pointless
    2. Starting a Substack / YT channel / etc. on that topic, hoping you catch the attention of people you can then connect to. This seems to work, and many "content creators" claim that this kind of community building has been the main benefit of what they do. But it takes extreme time investment, luck and skill (and very different skills than what you need later when talking to people directly).
    3. Joining a community around some such creator, if they exist. Problem is that current platforms usually mix "content consumers" and "community members", and by pushing for higher numbers in the former, they often destroy the latter.

    Some platforms around community building exist, but are primarily built for courses, and end up getting eaten by self-help/fin bros.

    My background being in LLMs, I'm thinking of a simple platform allowing users to describe their interests in detail, then being matched into small groups automatically for introductions. No monetisation (apart from small fees to cover the operating costs), with users incentivized to move their comms to other platforms if they hit off.

    If someone wants to build it so I don't have to, please do, as my time is very tight these days - I'd love to share my "plans"!

    2 votes
  10. Thomas-C
    Link
    I decided a couple of weeks ago to take a further step into Linux, from a Fedora based distribution (Bazzite) to one based on Arch (CachyOS). Along with that, I set up Docker and VirtualBox,...

    I decided a couple of weeks ago to take a further step into Linux, from a Fedora based distribution (Bazzite) to one based on Arch (CachyOS). Along with that, I set up Docker and VirtualBox, because I've been interested in learning more about both. For various reasons, mostly user error, I had a bad time trying to do that in Bazzite, but with CachyOS it went off without a hitch so, onward I go. I've been really interested in learning more about building and maintaining bigger systems, eventually so I can self host a bunch of services, but I lack the means to get a bunch of hardware. I figured I'd do what I could virtually until I can snag some. I've got my primary machine and two junker laptops I can test stuff with.

    One of my goals has been to separate my activities from each other, to assist with modifying my habits toward better security/privacy. Gaming is a big part of what I use the machine for, so that is like the one thing that isn't in some kind of box or container. I will try anyway eventually, just to know how to do it. Everything else has its place. A box for productivity, a box for creativity, a box for content, a box for research/searching around, a box for...seabound acquisitions, let's say. A shared directory for moving stuff between them, when I need to. I decided to kill all the birds with my stone and do different kinds of Linux for each kind of task, to build more familiarity with what does what in what. I know that probably sounds like a nightmare, it probably is/will be, but most of what I need to be doing doesn't involve a computer at all so there's room for tweaking and fiddling. What's critical for me is well preserved in backups and images.

    Docker I haven't gone into as deeply but I'm powerfully interested. My eventual goal, I think, I hope, is to construct a little system of containers to host stuff for myself, and see if I can make a thing all my boxes can connect to and do stuff with. I don't have a particularly beefy system but it is enough to have a bunch of small setups going. My background is more hardware and theory of systems as opposed to, say, computer science. I know a little coding from game modding and tech support, did coursework that dealt with symbolic logic and cybernetics, but I can't say I know any programming languages, for example. The concepts make sense, I just don't have expertise. I can sorta figure out what things are doing, if I know what they're supposed to be doing, but I want to be more proficient than that. If I have a big thing to keep up the motivation will be there to work out what I need to know.

    What I'd eventually like to do is build a server for my family to have all their stuff on, but I want to be able to service that system without subjecting them to the first attempt. If I can get to that, and do it well, my assumption is the experience will be valuable enough to be leveraged elsewhere, when time passes and I have to find something else to get the bills paid.

    1 vote