I think I have a pretty good developer env going on, but I’m always looking for more things I haven’t thought of.

So does anybody have any uber useful, or fun, or just a general favorite shell/terminal setup or tool?

  • z3rOR0ne@lemmy.ml
    link
    fedilink
    arrow-up
    6
    ·
    edit-2
    2 months ago

    Making a directory and then immediately navigating into it is such a common occurrence, eventually on stackoverflow I found this:

    alias mkcd='{ IFS= read -r d && mkdir "$d" && cd "$d"; } <<<'
    
  • tetris11@lemmy.ml
    link
    fedilink
    arrow-up
    5
    ·
    edit-2
    2 months ago

    A have it so that my shell always opens tmux, unless it’s a login shell or dumb shell.

    # ~/.bashrc
    ## Top of your RC
    [[ $- != *i* ]] && return          # If not running interactively, don't do anything
    [ -z "$PS1" ] && return            # If not running interactively, don't do anything
    [[ $TERM == dumb ]] && return      # If called from emacs, don't do anything
    
    ## Put the rest of your code here
    
    ## Bottom of RC
    shopt -q login_shell && return       ## If this is a login shell, load all except tmux
    
    if command -v tmux &> /dev/null && [ -n "$PS1" ] && [[ ! "$TERM" =~ screen ]] && [[ ! "$TERM" =~ tmux ]] && [ -z "$TMUX" ]; then
        tmux attach || exec tmux new-session 
    fi
    

    That way, I always have persistent terminal sessions and don’t need a terminal emulator that has tabs since I can just do multiplexing in tmux

  • CameronDev@programming.dev
    link
    fedilink
    arrow-up
    4
    ·
    2 months ago

    I have an alias venv, which checks if “./.venv” exists, and if not, creates a virtualenv there, and then activates it.

  • toastal@lemmy.ml
    link
    fedilink
    arrow-up
    2
    ·
    2 months ago

    Kitty’s builtin functions are pretty darn useful. I use the icat & ssh functions daily as well as the Unicode insert (tho I wish they would strip that ‘Nerd Font’ noise). Also still a long-time fan of fish’s completions.

    • tetris11@lemmy.ml
      link
      fedilink
      arrow-up
      2
      ·
      edit-2
      2 months ago

      icat

      I wish alacritty would just implement sixel already. I love the project but the dev can be hostile towards features that other terminals have had since years.

      That being said, it’s his project, and he shouldn’t be bound to the whims of the fanbase

      • toastal@lemmy.ml
        link
        fedilink
        arrow-up
        2
        ·
        2 months ago

        Would be nice, but sixel has some pretty obvious limitations Kitty tries to solve

            • tetris11@lemmy.ml
              link
              fedilink
              arrow-up
              1
              ·
              2 months ago

              please don’t write “Microsoft Github”. I know it’s been true for years, but just out of respect for what it once was, can you just call it “Github”

              • toastal@lemmy.ml
                link
                fedilink
                arrow-up
                2
                ·
                edit-2
                2 months ago

                Microsoft Windows. Microsoft Exchange. Microsoft Office. Microsoft Word. Microsoft Teams. Microsoft SwiftKey. Microsoft Bing. Microsoft SQL Server. …So yes, Microsoft GitHub unless we want to fail to recognize their neo-EEE strategy of purchasing/creating of as well npm, Azure, LinkedIn, VSCode, Language Server Protocol, TypeScript, etc. & trying to create “the ecosystem”.

                But also, zero respect for MS GitHub. Code forges now turned into a social media & marketing platforms, you have starhacking, anxiety for how green your chart is, pressure to build a portfolio on a proprietary + non-self-hosted platform. They have always required you create an account to submit patches. They also invented the horrible pull request model that doesn’t scale + blocks/slows teams down significantly; it also turns maintainers into commenters instead of merging patches & changing to fit their nits later instead putting all of the onus on contributors that usually just want a fix in—not to understand the maintainers whole process or even chosen programming language. It is bad. Gaining the seemingly-unshakable popularity the platfrom has, even the alternatives continue to copy MS GitHub’s bad ideas & propagate these ideas for ‘compatibility’ offering very little beyond X but FOSS (folks wonder why not a lot of others are moving to Forgejo, well, it doesn’t offer anything new or solves actual UX & workflow problems to be better (rather literally moved from Gitea’s CI to copying all the grossness of Microsoft GitHub’s Actions)). The only thing it did that was good was making free software cool while ironically on a totally proprietary platform.

                • tetris11@lemmy.ml
                  link
                  fedilink
                  arrow-up
                  1
                  ·
                  2 months ago

                  Github used to be such a great place to discover new coding projects that weren’t corporate monorepos, no other platform came close in that sense of discover ability and the communities that developed around small niche projects.

                  Also, what’s wrong with PRs? and what’s the alternative?

            • tetris11@lemmy.ml
              link
              fedilink
              arrow-up
              1
              ·
              edit-2
              2 months ago

              I just read the thread - it sounds like Kitty’s image protocol is better, but it does seem tone deaf to not implement Sixel (as a safe Rust library or whatnot) after so many terminals have.