From 1ecf10883477c2a106a99d2c99d5faa2dfa43ade Mon Sep 17 00:00:00 2001 From: noviicee_U Date: Wed, 24 Aug 2022 23:06:54 +0530 Subject: [PATCH 1/5] added correct commands for steps on Creating a Docker container action page --- .../creating-a-docker-container-action.md | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/content/actions/creating-actions/creating-a-docker-container-action.md b/content/actions/creating-actions/creating-a-docker-container-action.md index 28423b98204b..4358ddfd7a04 100644 --- a/content/actions/creating-actions/creating-a-docker-container-action.md +++ b/content/actions/creating-actions/creating-a-docker-container-action.md @@ -120,12 +120,27 @@ Next, the script gets the current time and sets it as an output variable that ac ``` 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)." -1. Make your `entrypoint.sh` file executable by running the following command on your system. + +3. Make your `entrypoint.sh` file executable by following the below commands on your system. + +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. +
The command works as below. + + ```shell{:copy} + $ git update-index --chmod=+x entrypoint.sh + ``` + +The permission mode of the file in the git index can be checked by running following command. ```shell{:copy} - $ chmod +x entrypoint.sh + $ git ls-files --stage entrypoint.sh ``` +If you receive an output like this-
+`100755 e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 0 entrypoint.sh` + +it means that the file has the executable permission. (Here `755` denotes the executable permission) + ## Creating a README To let people know how to use your action, you can create a README file. A README is most helpful when you plan to share your action publicly, but is also a great way to remind you or your team how to use the action. From e3f9d2cc37041c476f73e5723b199ffd573aeb47 Mon Sep 17 00:00:00 2001 From: Joe Clark <31087804+jc-clark@users.noreply.github.com> Date: Wed, 28 Sep 2022 12:30:51 -0700 Subject: [PATCH 2/5] Update content/actions/creating-actions/creating-a-docker-container-action.md --- .../creating-actions/creating-a-docker-container-action.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/actions/creating-actions/creating-a-docker-container-action.md b/content/actions/creating-actions/creating-a-docker-container-action.md index 4358ddfd7a04..cfb19047d5cf 100644 --- a/content/actions/creating-actions/creating-a-docker-container-action.md +++ b/content/actions/creating-actions/creating-a-docker-container-action.md @@ -121,7 +121,7 @@ Next, the script gets the current time and sets it as an output variable that ac 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)." -3. Make your `entrypoint.sh` file executable by following the below commands on your system. +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. 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.
The command works as below. From ec585bf4b11be92d464fe4a5a43fd95f26e304a5 Mon Sep 17 00:00:00 2001 From: Joe Clark <31087804+jc-clark@users.noreply.github.com> Date: Wed, 28 Sep 2022 12:45:37 -0700 Subject: [PATCH 3/5] Update content/actions/creating-actions/creating-a-docker-container-action.md --- .../creating-a-docker-container-action.md | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/content/actions/creating-actions/creating-a-docker-container-action.md b/content/actions/creating-actions/creating-a-docker-container-action.md index cfb19047d5cf..6520a213eb48 100644 --- a/content/actions/creating-actions/creating-a-docker-container-action.md +++ b/content/actions/creating-actions/creating-a-docker-container-action.md @@ -123,14 +123,8 @@ Next, the script gets the current time and sets it as an output variable that ac 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. -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. -
The command works as below. - ```shell{:copy} - $ git update-index --chmod=+x entrypoint.sh - ``` - -The permission mode of the file in the git index can be checked by running following command. + $ git update-index —chmod=+x entrypoint.sh ```shell{:copy} $ git ls-files --stage entrypoint.sh From 29e0014d8ffc27be08b7a7d248a5205d209d4c4c Mon Sep 17 00:00:00 2001 From: Joe Clark <31087804+jc-clark@users.noreply.github.com> Date: Wed, 28 Sep 2022 12:45:47 -0700 Subject: [PATCH 4/5] Update content/actions/creating-actions/creating-a-docker-container-action.md --- .../creating-actions/creating-a-docker-container-action.md | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/content/actions/creating-actions/creating-a-docker-container-action.md b/content/actions/creating-actions/creating-a-docker-container-action.md index 6520a213eb48..40d8ffc9fa60 100644 --- a/content/actions/creating-actions/creating-a-docker-container-action.md +++ b/content/actions/creating-actions/creating-a-docker-container-action.md @@ -130,10 +130,7 @@ Next, the script gets the current time and sets it as an output variable that ac $ git ls-files --stage entrypoint.sh ``` -If you receive an output like this-
-`100755 e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 0 entrypoint.sh` - -it means that the file has the executable permission. (Here `755` denotes the executable permission) + An output like `100755 e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 0 entrypoint.sh` means the file has the executable permission. In this example, `755` denotes the executable permission. ## Creating a README From bfc4edc28b4c20d1065fa57512dd4e9e1e03921a Mon Sep 17 00:00:00 2001 From: Joe Clark <31087804+jc-clark@users.noreply.github.com> Date: Wed, 28 Sep 2022 13:52:31 -0700 Subject: [PATCH 5/5] Update content/actions/creating-actions/creating-a-docker-container-action.md --- .../creating-actions/creating-a-docker-container-action.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/content/actions/creating-actions/creating-a-docker-container-action.md b/content/actions/creating-actions/creating-a-docker-container-action.md index 40d8ffc9fa60..2edc36c2cb42 100644 --- a/content/actions/creating-actions/creating-a-docker-container-action.md +++ b/content/actions/creating-actions/creating-a-docker-container-action.md @@ -125,6 +125,9 @@ Next, the script gets the current time and sets it as an output variable that ac ```shell{:copy} $ git update-index —chmod=+x entrypoint.sh + ``` + +1. Optionally, to check the permission mode of the file in the git index, run the following command. ```shell{:copy} $ git ls-files --stage entrypoint.sh