Skip to content

Commit 2fc4004

Browse files
authored
Merge pull request #20132 from noviicee/noviicee
Added correct commands for steps on Creating a Docker container action page
2 parents 61e5460 + 4236682 commit 2fc4004

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

content/actions/creating-actions/creating-a-docker-container-action.md

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,11 +120,20 @@ Next, the script gets the current time and sets it as an output variable that ac
120120
```
121121
If `entrypoint.sh` executes without any errors, the action's status is set to `success`. You can also explicitly set exit codes in your action's code to provide an action's status. For more information, see "[Setting exit codes for actions](/actions/creating-actions/setting-exit-codes-for-actions)."
122122

123-
1. Make your `entrypoint.sh` file executable by running the following command on your system.
123+
124+
1. Make your `entrypoint.sh` file executable. Git provides a way to explicitly change the permission mode of a file so that it doesn’t get reset every time there is a clone/fork.
124125

125126
```shell{:copy}
126-
$ chmod +x entrypoint.sh
127+
$ git update-index —chmod=+x entrypoint.sh
127128
```
129+
130+
1. Optionally, to check the permission mode of the file in the git index, run the following command.
131+
132+
```shell{:copy}
133+
$ git ls-files --stage entrypoint.sh
134+
```
135+
136+
An output like `100755 e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 0 entrypoint.sh` means the file has the executable permission. In this example, `755` denotes the executable permission.
128137

129138
## Creating a README
130139

0 commit comments

Comments
 (0)