Skip to content

Update directly executed scripts inside workflows #1107

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Apr 26, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,16 +27,16 @@ jobs:

- name: Generate Go sources, CRDs and schemas
run: |
./docker-run.sh ./build.sh
bash ./docker-run.sh ./build.sh
if [[ ! -z $(git status -s) ]]
then
echo 'Command `./docker-run.sh ./build.sh` did introduce changes, which should not be the case if it had been run as part of the PR. Please run it locally and check in the results as part of your PR.'
echo 'Command `bash ./docker-run.sh ./build.sh` did introduce changes, which should not be the case if it had been run as part of the PR. Please run it locally and check in the results as part of your PR.'
git --no-pager diff
exit 1
fi

- name: Validate samples against schemas
run: ./docker-run.sh ./validate-samples.sh
run: bash ./docker-run.sh ./validate-samples.sh

- name: Run GO tests
run: go test -coverprofile cover.out -v ./...
Expand All @@ -45,7 +45,7 @@ jobs:
uses: codecov/codecov-action@v2.1.0

- name: Check typescript model generation
run: ./build/typescript-model/generate.sh
run: bash ./build/typescript-model/generate.sh

- name: Check GO mod state
run: |
Expand Down Expand Up @@ -75,7 +75,7 @@ jobs:
run: |
export PATH=$PATH:$(go env GOPATH)/bin
go install github.com/securego/gosec/v2/cmd/gosec@v2.14.0
./run_gosec.sh
bash ./run_gosec.sh
if [[ $? != 0 ]]
then
echo "gosec scanner failed to run "
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-typescript-models.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:

- name: Generate typescript model
run: |
./build/typescript-model/generate.sh
bash ./build/typescript-model/generate.sh
cp -r ./build/typescript-model/workdir/typescript-models ../
working-directory: api

Expand Down
2 changes: 1 addition & 1 deletion build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ onError() {
}
trap 'onError' ERR

"${BASE_DIR}"/build-generator.sh
bash "${BASE_DIR}"/build-generator.sh

cd "${BASE_DIR}"

Expand Down
2 changes: 1 addition & 1 deletion build/typescript-model/generate.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ EOF
echo "[INFO] Lauching gen to generate typescript files based on swagger json"
export OPENAPI_SKIP_FETCH_SPEC=true
export OPENAPI_GENERATOR_COMMIT="v6.3.0"
$WORK_DIR/gen/openapi/typescript.sh $WORK_DIR/typescript-models $WORK_DIR/config.sh
bash $WORK_DIR/gen/openapi/typescript.sh $WORK_DIR/typescript-models $WORK_DIR/config.sh

sed -i 's/\"name\": \".*\"/"name": "@devfile\/api"/g' $WORK_DIR/typescript-models/package.json
sed -i 's/\"description\": \".*\"/"description": "Typescript types for devfile api"/g' $WORK_DIR/typescript-models/package.json
Expand Down
2 changes: 1 addition & 1 deletion make-release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ setVersionAndBuild() {
apply_sed "s#jsonschema:version=.*#jsonschema:version=${SCHEMA_VERSION}#g" pkg/apis/workspaces/$K8S_VERSION/doc.go #src/constants.ts

# Generate the schema
./build.sh
bash ./build.sh
}

commitChanges() {
Expand Down