Husband, father, kabab lover, history buff, chess fan and software engineer. Believes creating software must resemble art: intuitive creation and joyful discovery.

🌎 linktr.ee/bahmanm

Views are my own.

  • 12 Posts
  • 57 Comments
Joined 1 year ago
cake
Cake day: June 26th, 2023

help-circle



  • RE Go: Others have already mentioned the right way, thought I'd personally prefer ~/opt/go over what was suggested.


    RE Perl: To instruct Perl to install to another directory, for example to ~/opt/perl5, put the following lines somewhere in your bash init files.

    export PERL5LIB="$HOME/opt/perl5/lib/perl5${PERL5LIB:+:${PERL5LIB}}"
    export PERL_LOCAL_LIB_ROOT="$HOME/opt/perl5${PERL_LOCAL_LIB_ROOT:+:${PERL_LOCAL_LIB_ROOT}}"
    export PERL_MB_OPT="--install_base \"$HOME/opt/perl5\""
    export PERL_MM_OPT="INSTALL_BASE=$HOME/opt/perl5"
    export PATH="$HOME/opt/perl5/bin${PATH:+:${PATH}}"
    

    Though you need to re-install the Perl packages you had previously installed.




















  • That’s a good question 💯 In my case too, it took me some time (read years 😂) to figure out what I’m comfortable w/.

    I can think of 3 major ways that you can navigate the filesystem while being able to drop to a shell when you need it:

    • If you’re familiar w/ Emacs, you can either:
      • Use dired and tramp on your machine to access/navigate the target machine.
      • Install Emacs (emacs-nox) on the target machine, SSH and then run emacs-nox and voila! No need for tramp in this scenario.
    • Use Midnight Commander (mc) which offers a TUI pretty much like Norton Commander (nc) from the days of yore.
    • Get used to the semi-standard structure of the file system and just use plain Bash (cd, pushd & popd) to move around. That is
      • Understand what usually goes into common directories (like /usr/share or /opt) and try to follow the same pattern when rolling your own software installations.
      • Learn how to use your distro’s package manager to query packages and find out where things, like configurations and docs, are stored. Something as simple as rpm -q --list is what you usually need.

    HTH