Page 2 of 2 FirstFirst 12
Results 11 to 12 of 12

Thread: Where do I put scripts to make them work?

  1. #11
    Join Date
    Jun 2019
    Lubuntu 20.04 Focal Fossa

    Re: Where do I put scripts to make them work?

    OK, I put on my thinking hat.

    I'll leave this script in /usr/local/sbin for several reasons:
    1: it's a script for the main/sudo user only, and all other settings for this user are also in /usr/share. "Normal" users have their settings in $HOME subdirs.
    2: it's a sudo script, which tells me that sbin, not bin is the right place.
    3: there must be a reason that /usr/local/sbin exists (a bit weak, but...)

    Other scripts that are for all/other users and do not need sudo rights I'll have to think about.

    Thanks for your help everybody.
    Last edited by ml9104; October 1st, 2021 at 11:36 PM.

  2. #12
    Join Date
    Apr 2007

    Re: Where do I put scripts to make them work?

    Put your personal scripts in either `~/.local/share/bin` or `~/bin`.

    Put scripts that need to be available to any user in the system in `/usr/local/bin`. `/usr/local/sbin` indeed is a suited location for your custom administrative scripts.
    Last edited by vanadium; October 2nd, 2021 at 12:42 PM. Reason: Removed comment on sudo inside script

Page 2 of 2 FirstFirst 12


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts