Skip to content

Commit 573d375

Browse files
committed
Add: sample application link and updated config.
also remove the step by step.
1 parent 8bb6f53 commit 573d375

File tree

1 file changed

+18
-33
lines changed

1 file changed

+18
-33
lines changed

jekyll/_cci2/language-android.md

Lines changed: 18 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -38,58 +38,43 @@ Studio](https://developer.android.com/studio).
3838

3939
## Sample Configuration
4040

41+
The below is a sample configuration for an [Android sample application](https://github.com/CircleCI-Public/MoodTracker/blob/master/.circleci/config.yml).
42+
4143
{% raw %}
4244

4345
```yaml
4446
version: 2.1 # set the version of your config to enable use of orbs.
4547

4648
orbs: # orbs provide lots of bundled functionality for your specific config.
47-
android: circleci/android@0.2.0
49+
android: circleci/android@0.2.1
4850

4951
jobs:
5052
build: # setup a "build job
5153
executor: android/android # set our executor using the `android` orb declared above
5254
steps:
5355
- checkout # download your code from your VCS
56+
- android/restore-build-cache # restore dependency cache if it exists.
5457
- run:
55-
command: ./gradlew lint test # run a test run.
56-
57-
workflows:
58+
name: Download Dependencies
59+
command: ./gradlew androidDependencies
60+
- android/save-build-cache # Cache our dependencies
61+
- run:
62+
command: ./gradlew lint test
63+
- store_artifacts: # for display in Artifacts: https://circleci.com/docs/2.0/artifacts/
64+
path: app/build/reports
65+
destination: reports
66+
- store_test_results: # for display in Test Summary: https://circleci.com/docs/2.0/collect-test-data/
67+
path: app/build/test-results
68+
# See https://circleci.com/docs/2.0/deployment-integrations/ for deploy examples
69+
70+
workflows:
5871
build:
5972
jobs:
6073
- build
61-
```
62-
63-
{% endraw %}
64-
65-
## Config Walkthrough
66-
67-
We always start with the version.
6874

69-
```yaml
70-
version: 2.1
7175
```
7276

73-
In this sample application, we use the [Android
74-
orb](https://circleci.com/orbs/registry/orb/circleci/android). Next, we have a
75-
jobs key. Each job represents a phase in your Build-Test-Deploy process. Our
76-
sample app only needs a build job, so everything else is going to live under
77-
that key.
78-
79-
For the Android orb, you can pull in the recommended CircleCI `cimg` base docker
80-
image for [android](https://hub.docker.com/r/cimg/android) simply by calling
81-
`android/android` under the `executor` key.
82-
83-
84-
```yaml
85-
jobs:
86-
build:
87-
executor: android/android
88-
```
89-
90-
91-
Then `./gradlew lint test` runs the unit tests, and runs the built in linting
92-
tools to check your code for style issues.
77+
{% endraw %}
9378

9479
## Docker Images
9580

0 commit comments

Comments
 (0)