Skip to content

Commit 0c5e956

Browse files
authored
Merge pull request #237 from cnumr/cms
refactor: suppression du script de construction obsolète dans le work…
2 parents 64218db + 652a6b5 commit 0c5e956

3 files changed

Lines changed: 20 additions & 23 deletions

File tree

.github/workflows/retype-action.yml

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -25,29 +25,6 @@ jobs:
2525
with:
2626
config_path: ./docs/retype.yml
2727

28-
- uses: 1arp/create-a-file-action@0.4.5
29-
with:
30-
path: '.'
31-
isAbsolutePath: false
32-
file: 'script.sh'
33-
content: |
34-
#!/bin/bash
35-
36-
# https://vercel.com/guides/how-do-i-use-the-ignored-build-step-field-on-vercel
37-
38-
echo "VERCEL_GIT_COMMIT_REF: $VERCEL_GIT_COMMIT_REF"
39-
40-
if [[ "$VERCEL_GIT_COMMIT_REF" == "main" || "$VERCEL_GIT_COMMIT_REF" == "cms" || "$VERCEL_GIT_COMMIT_REF" == "feat/cms" ]] ; then
41-
# Proceed with the build
42-
echo "✅ - Build can proceed"
43-
exit 1;
44-
45-
else
46-
# Don't build
47-
echo "🛑 - Build cancelled"
48-
exit 0;
49-
fi
50-
5128
- uses: retypeapp/action-github-pages@latest
5229
with:
5330
update-branch: true

docs/retype.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,3 +28,7 @@ edit:
2828
base: './docs' # Optional base path to a directory within repo
2929
branch: 'main' # Point to a custom branch within the repo
3030
label: 'Modifier sur GitHub' # A custom label for the generated link
31+
32+
include: # Files or folders to include in the build
33+
# See also: exclude
34+
- 'script.sh' # Wildcards are valid

docs/script.sh

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
#!/bin/bash
2+
3+
# https://vercel.com/guides/how-do-i-use-the-ignored-build-step-field-on-vercel
4+
5+
echo "VERCEL_GIT_COMMIT_REF: $VERCEL_GIT_COMMIT_REF"
6+
7+
if [[ "$VERCEL_GIT_COMMIT_REF" == "main" || "$VERCEL_GIT_COMMIT_REF" == "cms" || "$VERCEL_GIT_COMMIT_REF" == "feat/cms" ]] ; then
8+
# Proceed with the build
9+
echo "✅ - Build can proceed"
10+
exit 1;
11+
12+
else
13+
# Don't build
14+
echo "🛑 - Build cancelled"
15+
exit 0;
16+
fi

0 commit comments

Comments
 (0)