Skip to content

Commit 63b028f

Browse files
Fix fetch for ci but not publish (#2745)
* grep in ci only but not publish
1 parent 3b96de8 commit 63b028f

File tree

2 files changed

+11
-4
lines changed

2 files changed

+11
-4
lines changed

.github/workflows/master.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,3 +14,4 @@ jobs:
1414
env:
1515
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
1616
VSCE_TOKEN: ${{ secrets.VSCE_TOKEN }}
17+
PUBLISH: true

packages/quicktype-core/env.sh

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,14 @@
11
#!/usr/bin/env bash
22

3-
if [[ $CI ]]
4-
then
5-
grep -rl '$fetch' src | xargs sed -i '' -e 's/$fetch/$fetch.ci/g'
3+
if [[ $PUBLISH == true ]]; then
4+
echo 'HAS PUBLISH, exit'
5+
exit 0
66
fi
77

8-
exit 0
8+
if [[ $CI ]]; then
9+
if [[ "$OSTYPE" == "darwin"* ]]; then
10+
grep -rl '$fetch' src | xargs sed -i '' -e 's/$fetch/$fetch.ci/g'
11+
else
12+
grep -rl '$fetch' src | xargs sed -i -e 's/$fetch/$fetch.ci/g'
13+
fi
14+
fi

0 commit comments

Comments
 (0)