BREAKING CHANGE: Update inputs for multi src and pattern args
parent
bfa025c10c
commit
98ee38d52e
|
@ -2,7 +2,7 @@ name: e2e Test
|
|||
|
||||
on:
|
||||
push:
|
||||
branches: [ 'main' ]
|
||||
branches: [ 'feature/multi-src' ]
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
ARGS:
|
||||
|
@ -63,6 +63,9 @@ jobs:
|
|||
|
||||
- name: Create project file
|
||||
run: |
|
||||
mkdir test_project2 && cd "$_"
|
||||
truncate -s 5MB info2.txt
|
||||
cd ../
|
||||
mkdir test_project && cd "$_"
|
||||
touch index.html
|
||||
date +"%Y-%m-%d %H:%M:%S,%3N" >> index.html
|
||||
|
@ -77,7 +80,7 @@ jobs:
|
|||
echo "skip_dir:" && ls -l skip_dir
|
||||
|
||||
- name: e2e Test published ssh-deploy action
|
||||
uses: easingthemes/ssh-deploy@main
|
||||
uses: easingthemes/ssh-deploy@feature/multi-src
|
||||
env:
|
||||
# ENV Vars created in previous steps:
|
||||
# SSH_PRIVATE_KEY: $EXAMPLE_SSH_PRIVATE_KEY
|
||||
|
@ -85,7 +88,7 @@ jobs:
|
|||
REMOTE_USER: ${{ env.TEST_USER }}
|
||||
ARGS: ${{ github.event.inputs.ARGS || '-rltgoDzvO --delete --chmod=ugo=rwX --progress' }}
|
||||
SSH_CMD_ARGS: ${{ github.event.inputs.SSH_CMD_ARGS || '-o StrictHostKeyChecking=no, -o UserKnownHostsFile=/dev/null' }}
|
||||
SOURCE: "test_project/"
|
||||
SOURCE: ["test_project/, test_project2/"]
|
||||
TARGET: "/var/www/html/"
|
||||
EXCLUDE: ${{ github.event.inputs.EXCLUDE || 'skip_dir/, /node_modules/' }}
|
||||
SCRIPT_BEFORE: |
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -29,11 +29,10 @@ inputNames.forEach((input) => {
|
|||
let extendedVal = validVal;
|
||||
// eslint-disable-next-line default-case
|
||||
switch (inputName) {
|
||||
case 'source':
|
||||
extendedVal = `${githubWorkspace}/${validVal}`;
|
||||
case 'args':
|
||||
extendedVal = validVal.split(' ');
|
||||
break;
|
||||
case 'exclude':
|
||||
case 'args':
|
||||
case 'sshCmdArgs':
|
||||
extendedVal = validVal.split(',').map((item) => item.trim());
|
||||
break;
|
||||
|
|
Loading…
Reference in New Issue