Commit 572fc992 authored by alep's avatar alep

fix: support legacy GitLab CI syntax

parent 15c60941
Pipeline #690 failed
...@@ -8,7 +8,7 @@ variables: ...@@ -8,7 +8,7 @@ variables:
ANDROID_HOME: "/Users/alypmustaqim/Library/Android/sdk" ANDROID_HOME: "/Users/alypmustaqim/Library/Android/sdk"
ANDROID_SDK_ROOT: "/Users/alypmustaqim/Library/Android/sdk" ANDROID_SDK_ROOT: "/Users/alypmustaqim/Library/Android/sdk"
default: .common:
tags: tags:
- shell - shell
...@@ -21,14 +21,13 @@ default: ...@@ -21,14 +21,13 @@ default:
- yarn --version - yarn --version
cache: cache:
key: key: "$CI_COMMIT_REF_SLUG"
files:
- yarn.lock
paths: paths:
- node_modules/ - node_modules/
- android/.gradle/ - android/.gradle/
install_dependencies: install_dependencies:
extends: .common
stage: install stage: install
script: script:
- yarn install --frozen-lockfile - yarn install --frozen-lockfile
...@@ -38,28 +37,28 @@ install_dependencies: ...@@ -38,28 +37,28 @@ install_dependencies:
expire_in: 1 hour expire_in: 1 hour
lint: lint:
extends: .common
stage: test stage: test
needs: dependencies:
- job: install_dependencies - install_dependencies
artifacts: true
script: script:
- yarn lint - yarn lint
allow_failure: false allow_failure: false
test: test:
extends: .common
stage: test stage: test
needs: dependencies:
- job: install_dependencies - install_dependencies
artifacts: true
script: script:
- yarn test --watchAll=false --passWithNoTests - yarn test --watchAll=false --passWithNoTests
allow_failure: false allow_failure: false
build_android: build_android:
extends: .common
stage: build stage: build
needs: dependencies:
- job: install_dependencies - install_dependencies
artifacts: true
script: script:
- echo "ANDROID_HOME=$ANDROID_HOME" - echo "ANDROID_HOME=$ANDROID_HOME"
...@@ -78,5 +77,5 @@ build_android: ...@@ -78,5 +77,5 @@ build_android:
- android/app/build/outputs/apk/debug/*.apk - android/app/build/outputs/apk/debug/*.apk
expire_in: 7 days expire_in: 7 days
rules: only:
- if: '$CI_COMMIT_BRANCH == "main"' - main
\ No newline at end of file \ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment