-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Dockerized version of the count-lines-docker action
- Loading branch information
1 parent
be30b6e
commit 68a07fb
Showing
3 changed files
with
40 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
name: "Count Lines Docker" | ||
description: "Counts the number of lines in a specified directory and outputs the result." | ||
inputs: | ||
target_directory: | ||
description: "The directory to count lines in" | ||
required: true | ||
ignore_rule: | ||
description: "Rule to apply for ignoring files: 'git' for .gitignore, 'hidden' for hidden directories, or 'none' for no exclusions." | ||
required: true | ||
default: "git" | ||
outputs: | ||
line_count: | ||
description: "The number of lines counted in the directory" | ||
runs: | ||
using: docker | ||
image: ../../scripts/count-lines.Dockerfile | ||
args: | ||
- ${{ inputs.target_directory }} | ||
- ${{ inputs.ignore_rule }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
FROM alpine:3.10 | ||
|
||
RUN apk add --no-cache bash git findutils coreutils tree | ||
|
||
COPY ./count-lines.sh /entrypoint.sh | ||
|
||
ENTRYPOINT ["/entrypoint.sh"] |