Regular Expressions 101

Community Library Entry

0

Regular Expression
PCRE (PHP <7.3)

/
^(?P<major>0|[1-9]\d*)\.(?P<minor>0|[1-9]\d*)\.(?P<patch>0|[1-9]\d*)(?:-(?P<prerelease>(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+(?P<buildmetadata>[0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$
/
gm

Description

actions-runner-win-x64-2.300.2.zipDownload We recommend configuring the runner under "\actions-runner". This will help avoid issues related to service identity folder permissions and long path restrictions on Windows.

Create a folder under the drive root

$ mkdir actions-runner; cd actions-runner# Download the latest runner package $ Invoke-WebRequest -Uri https://github.com/actions/runner/releases/download/v2.300.2/actions-runner-win-x64-2.300.2.zip -OutFile actions-runner-win-x64-2.300.2.zip# Optional: Validate the hash $ if((Get-FileHash -Path actions-runner-win-x64-2.300.2.zip -Algorithm SHA256).Hash.ToUpper() -ne '54a37c9c78ca2dafe8912e633e8ff1740b9acf705169f240e3ee962b231a9f76'.ToUpper()){ throw 'Computed checksum did not match' }# Extract the installer $ Add-Type -AssemblyName System.IO.Compression.FileSystem ; [System.IO.Compression.ZipFile]::ExtractToDirectory("$PWD/actions-runner-win-x64-2.300.2.zip", "$PWD") Configure

Create the runner and start the configuration experience

$ ./config.cmd --url https://github.com/AriesTriputranto9/datasets --token AYC56HRTW24HAY5UDYNGDRDDYU5DE# Run it! $ ./run.cmd Using your self-hosted runner

Use this YAML in your workflow file for each job

runs-on: self-hosted

Submitted by AriesTriputranto - 2 years ago