Skip Navigation

InitialsDiceBearhttps://github.com/dicebear/dicebearhttps://creativecommons.org/publicdomain/zero/1.0/„Initials” (https://github.com/dicebear/dicebear) by „DiceBear”, licensed under „CC0 1.0” (https://creativecommons.org/publicdomain/zero/1.0/)D
Posts
47
Comments
41
Joined
3 yr. ago

  • That's exactly the reason why I made it only work with user-defined aliases. That way it forces you to think of how to cover the most ground command-wise without needing anything interactive or too much response data. It's slow but it's functional and that's really all I wanted from it. I can have scripts on my server that fix things and just invoke them with this.

  • They're encrypted with a PSK encrypted with either AES128 or AES256. It's built into the Meshtastic firmware so that's not something I have to handle directly, thankfully!

  • I started thinking about using the LoRa protocol directly for this too! My biggest concern is overwhelming the mesh. But I also had no idea what protocol would work so thanks for mentioning PPP. I haven't thought about that since I was a kid! That would be really cool though!

    Maybe just for a POC someday?

    Also: how are you liking MeshCore? Did you have to pay for a license to use it? How expensive is the mesh you're building? That is something I've started thinking about too for this exact reason 😂

  • Ah I see what you mean. Yep I totally misunderstood what you meant. Yes I did think about that but I wanted to be able to control my servers too, hence MeshExec. ☺️

  • Thank you! ☺️

  • I could except it would need Internet access to subscribe or publish to an MQTT broker. I wanted remote control when both I don't have Internet access when I'm away from home, and my home itself has no Internet access.

    For MQTT packets to be forwarded over the mesh, there needs to be at least one MQTT gateway connected to it that has Internet access.

  • Selfhosted @lemmy.world

    I made a way to remotely control my homelab without any internet access required

  • Meshtastic @mander.xyz

    I made a little daemon to let me remotely control servers over the mesh with no internet access required

    github.com /Dark-Alex-17/meshexec
  • Yeah of course! That guy is such a legend for what he did in the PSP modding scene!

  • Sadly no I'm not, but I was very inspired by him when I was in that scene! PSP hacking was my first experience with customizing any kind of device beyond what average users can do and it's what made me fall in love with computers as a kid. I don't think I'd be the software engineer I am today or even in this field if it wasn't for him. My name is Alex so I thought I could pay homage to him by choosing a similar username, since he had such a massive impact on my life ☺️

  • Rust @programming.dev

    Managarr (A Servarr CLI and TUI) now supports Lidarr!

    github.com /Dark-Alex-17/managarr
  • Rust Programming @lemmy.ml

    Managarr (A Servarr CLI and TUI) now supports Lidarr!

    github.com /Dark-Alex-17/managarr
  • commandline @programming.dev

    Managarr (A Servarr CLI and TUI) now supports Lidarr!

    github.com /Dark-Alex-17/managarr
  • Cool GitHub Projects @programming.dev

    Managarr (A Servarr CLI and TUI) now supports Lidarr!

    github.com /Dark-Alex-17/managarr
  • Selfhosted @lemmy.world

    Managarr (A Servarr CLI and TUI) now supports Lidarr!

    github.com /Dark-Alex-17/managarr
  • Open Source @lemmy.ml

    Managarr (A Servarr CLI and TUI) now supports Lidarr!

    github.com /Dark-Alex-17/managarr
  • Sonarr @lemmy.world

    Managarr (A Servarr CLI and TUI) now supports Lidarr!

    github.com /Dark-Alex-17/managarr
  • Radarr @lemmy.world

    Managarr (A Servarr CLI and TUI) now supports Lidarr!

    github.com /Dark-Alex-17/managarr
  • Thanks so much for the other stuff you use! I've been using bm for years, but I haven't used mkcd, so I'm definitely going to add that.

    I'm going to give your library, config, and AoC a good look because that's exactly what I was hoping for in this conversation! :)

    In general: The only time I add it to my ~/.bashrc is when it's either an alias for something simple, or a very simple function. Otherwise, anything that requires more legwork or is bigger than a few lines, I put in dtools. I used to put it all in my ~/.bashrc but that honestly became kind of cumbersome when I have different configs on different servers, or machines for work vs personal, etc. And sometimes the exports would differ making functions work differently and I didn't want to just have to copy that section of my ~/.bashrc as well every time something updated, hence why I created the dtools repo!

    To respond to your other comments, I'm going to do my best to respond in the order they show up:

    printf vs echo through bold() vs $'\e[1m'

    The dtools script is actually compiled, not written by me. So in the vast majority of the project, my code is all in the src directory, not in the dtools script. In fact, my repo without compilation consists of only 3k lines. The compiled code in the script then makes up the completions, coloring, some error handling, validations, filters, help messages, constraints (like conflicting flags), etc.

    So many of the echos you see are from the bashly framework, not my code. I often use heredocs for longer or multiline strings (being SUPER careful when using <<-EOF to make sure my damn editor is using TABs...that's such a nightmare otherwise 😂 ).

    If you look through my code in particular, you'll see I use many of these bash-isms you've mentioned!

    So the One vs Many comment is exactly how the repo works! Each subcommand is its own directory and file. So, for example: All dtools aws commands are in the src/commands/aws directory. And any further subcommands like dtools aws secretsmanager are in another subdirectory where each command has its own individual script!

    Bashisms

    I'm familiar with many of the bashisms you mentioned except the var="$(< file)" one, that's awesome! I've been trying to migrate away from using cat to just output file contents and use more direct, purpose methods that are often built into tools (like jq '.[]' file.json instead of cat file.json | jq '.[]'). However, I'll say that when I'm trying to read each line into an iterable array, I often use readarray too.

    grep | awk | sed

    I've been trying for years to get more people to look into awk because it's amazing! It's so undervalued! sed takes some getting used to with the pattern and hold space but it's worth the initial suffering 😛

    Shellcheck

    I've got my Helix editor set up with Shellcheck! It's awesome! You'll notice if you look at my code directly that there's a number of places I have to do # shellcheck disable=SC2154 (a variable is referencing an undefined value). This is because the framework creates and passes those variables to my scripts for me.

    A Loose Offer

    You seem a lot like me in that you do a LOT of bash scripting! So I'll admit to the fact that I've looked at the compiled code and noted that the most important code is mine, and while there's a lot of things going on in the compiled script, I agree with most of it. But I've also been a bit concerned about how often it's spawning subshells when it doesn't have to.

    I think I can fix some of them with associative arrays if I add a minimum bash version requirement in my config, but I've honestly never tried. I'll check that out now!

    Since you make a solid point about a lot of this that should maybe be updated in the Bashly framework, maybe we should work together to update the framework to have better conventions like you've mentioned?

  • Bash @lemmy.ml

    I've collected all my useful bash scripts and command aliases into one CLI, but I want more!

    github.com /Dark-Alex-17/dtools
  • commandline @programming.dev

    I've collected all my useful bash scripts and command aliases into one CLI, but I want more!

    github.com /Dark-Alex-17/dtools
  • Yep exactly!

  • Model Context Protocol. It's basically APIs designed specifically for AIs to use to extend their capabilities. Think of it like, instead of building tools for models to call yourself, the creators of your favorite services make the tools for you and expose them as APIs. All you have to do it point the model at their API to use it.

  • LocalLLaMA @sh.itjust.works

    Loki - An All-in-One, Batteries Included LLM CLI

  • Rust @programming.dev

    Loki - An All-in-One, Batteries Included LLM CLI

  • Rust Programming @lemmy.ml

    Loki - An All-in-One, Batteries Included LLM CLI

  • commandline @programming.dev

    Loki - An All-In-One, Batteries Included LLM CLI

  • Radarr @lemmy.world

    Managarr v0.6.0 is Out and now supports Themes, Vim keybindings, custom API headers, and more!

    github.com /Dark-Alex-17/managarr
  • Sonarr @lemmy.world

    Managarr v0.6.0 is Out and now supports Themes, Vim keybindings, custom API headers, and more!

    github.com /Dark-Alex-17/managarr
  • Open Source @lemmy.ml

    Managarr v0.6.0 is Out and now supports Themes, Vim keybindings, custom API headers, and more!

    github.com /Dark-Alex-17/managarr
  • Selfhosted @lemmy.world

    Managarr v0.6.0 is Out and now supports Themes, Vim keybindings, custom API headers, and more!

    github.com /Dark-Alex-17/managarr
  • Sadly no I'm not, but I was very inspired by him when I was in that scene! PSP hacking was my first experience with customizing any kind of device beyond what average users can do and it's what made me fall in love with computers as a kid. I don't think I'd be the software engineer I am today or even in this field if it wasn't for him. My name is Alex so I thought I could pay homage to him by choosing a similar username, since he had such a massive impact on my life ☺️

  • To answer your question, I built it for a few reasons:

    • I wanted to learn Rust, so I used this project to do that
    • I really love TUI's and I pretty much live in my command line at work, and since I already automate everything I can to make my work life easier, I wanted to be able to do the same with my homelab
    • I think it looks cool
    • For fun. If no one else ever gets use out of it, that's okay! I just really enjoyed building it and I'm excited to build out more of it.

    But also: Why not? ☺️

    So really, you would only use this if you like TUIs or want a command line tool for interacting with your Servarrs. If you have no use for it, that's totally fine too!

    The one actual use I've found people say they use it for is people who don't want to expose the web interface to interact with their Servarrs and only interact via SSH. Then they like to use this instead.

  • To answer your question, I built it for a few reasons:

    • I wanted to learn Rust, so I used this project to do that
    • I really love TUI's and I pretty much live in my command line at work, and since I already automate everything I can to make my work life easier, I wanted to be able to do the same with my homelab
    • I think it looks cool
    • For fun. If no one else ever gets use out of it, that's okay! I just really enjoyed building it and I'm excited to build out more of it.

    But also: Why not? ☺️

    So really, you would only use this if you like TUIs or want a command line tool for interacting with your Servarrs. If you have no use for it, that's totally fine too!

    The one actual use I've found people say they use it for is people who don't want to expose the web interface to interact with their Servarrs and only interact via SSH. Then they like to use this instead.

  • ... Well that's... Concerning...😅

    What browser are you using? I want to try to recreate it!

  • Sorry for the confusion! I was trying to be a little cheeky and I guess I didn't realize how that may come across!

  • I saw that the PR was merged. Let me know when it's available and I'll add the nix-env -i managarr to the README

  • Thanks for doing the legwork on this! I would definitely be a bit out of my depth on that PR without actually having Nix installed 😂.

    Once it's merged I'll update the README to mention the Nix installation method.

  • Sounds good, let me know! Also give me some links to track it too so I can also add it to the repo!