Skip to content

Commit 3bd3c97

Browse files
matanbaruchsebthom
authored andcommitted
Add exclude-current to inputs in action
1 parent 10c10f7 commit 3bd3c97

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

action.yml

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,13 @@ branding:
1111
icon: settings
1212

1313
inputs:
14-
healthchecks: { default: "20", description: "Number of mirrors from the mirrors list to check for availability and up-to-dateness." }
15-
speedtests: { default: "10", description: "Maximum number of healthy mirrors to test for speed." }
16-
parallel: { default: "2", description: "Number of parallel speed tests. May result in incorrect results because of competing connections but finds a suitable mirror faster." }
17-
sample-size: { default: "1024", description: "Number of kilobytes to download during the speed from each mirror." }
18-
sample-time: { default: "3", description: "Maximum number of seconds within the sample download from a mirror must finish." }
19-
14+
healthchecks: { default: "20", description: "Number of mirrors from the mirrors list to check for availability and up-to-dateness." }
15+
speedtests: { default: "10", description: "Maximum number of healthy mirrors to test for speed." }
16+
parallel: { default: "2", description: "Number of parallel speed tests. May result in incorrect results because of competing connections but finds a suitable mirror faster." }
17+
sample-size: { default: "1024", description: "Number of kilobytes to download during the speed from each mirror." }
18+
sample-time: { default: "3", description: "Maximum number of seconds within the sample download from a mirror must finish." }
19+
exclude-current: { default: "false", description: "Don't include the current APT mirror in the speed tests." }
20+
2021
repo-name: { default: "vegardit/fast-apt-mirror.sh", description: "Repository containing the fast-apt-mirror.sh script" }
2122
repo-branch: { default: "v1", description: "Version (i.e. github branch) of the fast-apt-mirror.sh script to use" }
2223

@@ -43,7 +44,8 @@ runs:
4344
--speedtests ${{ inputs.speedtests }} \
4445
--parallel ${{ inputs.parallel }} \
4546
--sample-size ${{ inputs.sample-size }} \
46-
--sample-time ${{ inputs.sample-time }}
47+
--sample-time ${{ inputs.sample-time }} \
48+
${{ inputs.exclude-current && '--exclude-current' || '' }}
4749
fi || exit 0 # don't fail action if APT mirror detection failed for whatever reason
4850
fi
4951

0 commit comments

Comments
 (0)