chmod a+x code example

Example 1: how to set execute permission in linux

chmod +x script-name-here.sh #Change the "script-name-here" to the name of your .sh file.

Example 2: chmod a+x

// Change the permissions of a file for all users via Mac terminal

// CD into the exe folder where your file is stored and run:
chmod a+x example.txt 

// chmod: change mode (permissions) of a file.
// a+x: for all (a) users, add (+) the execute (x) permission.
// example.txt: the name of the file which is to be modified.

Example 3: how to set execute permission in linux

chmod -x script-name-here.sh #Change the "script-name-here" to the name of your .sh file.