Update main.yml
This commit is contained in:
@@ -36,7 +36,7 @@ jobs:
|
|||||||
- name: Backup local .txt files
|
- name: Backup local .txt files
|
||||||
run: |
|
run: |
|
||||||
mkdir backup
|
mkdir backup
|
||||||
if [ -e *.txt ]; then
|
if ls *.txt &> /dev/null; then
|
||||||
cp *.txt backup/
|
cp *.txt backup/
|
||||||
else
|
else
|
||||||
echo "No .txt files to backup"
|
echo "No .txt files to backup"
|
||||||
@@ -51,7 +51,7 @@ jobs:
|
|||||||
# Restore local .txt files and delete backup
|
# Restore local .txt files and delete backup
|
||||||
- name: Restore local .txt files and delete backup
|
- name: Restore local .txt files and delete backup
|
||||||
run: |
|
run: |
|
||||||
if [ -e backup/*.txt ]; then
|
if ls backup/*.txt &> /dev/null; then
|
||||||
cp backup/*.txt .
|
cp backup/*.txt .
|
||||||
rm -rf backup
|
rm -rf backup
|
||||||
else
|
else
|
||||||
|
|||||||
Reference in New Issue
Block a user