Если я не ошибаюсь, некоторые «корпоративные» компании Linux, такие как Novell, делают реальные деньги, продавая проприетарное программное обеспечение, которое делает именно это. (И еще ... / etc / skel не поддерживает обновление существующих учетных записей.)
Поскольку вы добавили разрешения на выполнение (для каждой группы пользователей) в файл helloworld.sh, вы должны выполнить ./helloworld.sh или bash helloworld.sh для выполнения файла bash:
sudo chmod a+x hello_world.sh # Adding excution permissions
./helloworld.sh # option 1
bash helloworld.sh # option 2
Однако , если вы не сделали chmod a+x hello_world.sh, вы все равно можете выполнить файл bash, набрав bash helloworld.sh:
bash helloworld.sh # Without adding excution permissions
# to any user group
Поскольку вы добавили разрешения на выполнение (для каждой группы пользователей) в файл helloworld.sh, вы должны выполнить ./helloworld.sh или bash helloworld.sh для выполнения файла bash:
sudo chmod a+x hello_world.sh # Adding excution permissions
./helloworld.sh # option 1
bash helloworld.sh # option 2
Однако , если вы не сделали chmod a+x hello_world.sh, вы все равно можете выполнить файл bash, набрав bash helloworld.sh:
bash helloworld.sh # Without adding excution permissions
# to any user group
Поскольку вы добавили разрешения на выполнение (для каждой группы пользователей) в файл helloworld.sh, вы должны выполнить ./helloworld.sh или bash helloworld.sh для выполнения файла bash:
sudo chmod a+x hello_world.sh # Adding excution permissions
./helloworld.sh # option 1
bash helloworld.sh # option 2
Однако , если вы не сделали chmod a+x hello_world.sh, вы все равно можете выполнить файл bash, набрав bash helloworld.sh:
bash helloworld.sh # Without adding excution permissions
# to any user group
Выполнить с помощью
./helloworld.sh
, как указано @Yerong Li или
sh helloworld.sh
Выполнить с помощью
./helloworld.sh
, как указано @Yerong Li или
sh helloworld.sh
Выполнить с помощью
./helloworld.sh
, как указано @Yerong Li или
sh helloworld.sh