You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+2-86Lines changed: 2 additions & 86 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -3,14 +3,6 @@
3
3
Thank you for your interest in using the Android Runner framework. Android Runner has been built up in iterative steps by bachelor's, master's, PhD students and professors. Our goal is to make performance and energy consumption research on Android devices more accessible and robust. The framework provides many tools and plugins to make this possible.
4
4
5
5
## Table of Contents
6
-
-[Requirements](#requirements)
7
-
-[Setting Up Environment and Dependencies](#setting-up-environment-and-dependencies)
-[Making Changes to Your Forked Repository](#making-changes-to-your-forked-repository)
16
8
-[Commits](#commits)
@@ -19,83 +11,6 @@ Thank you for your interest in using the Android Runner framework. Android Runne
19
11
-[Communication](#communication)
20
12
-[Debugging Tips](#debugging-tips)
21
13
22
-
## Requirements
23
-
- Python 3
24
-
- Linux or macOS
25
-
26
-
Current and former contributors have used Ubuntu 18.04 and Ubuntu 20.04 along with Python 3.6.9 and 3.7.4.
27
-
28
-
## Setting Up Environment and Dependencies
29
-
1. Click on the **Fork** icon in the top right hand corner once you're logged into Github.
30
-
2. Once it finishes loading, click on the green **Code** button. Copy `git clone git@github.com:[your_username]/android-runner.git` and then paste that into your terminal after navigating to the desired local development environment.
31
-
3. Type `cd android-runner` to enter the framework's main directory. Now, add a remote tracker to the parent repository with `git remote add upstream https://github.com/S2-group/android-runner`. This is useful in case any major changes occur to the parent directory that may affect your project. `git remote -vv` should now show *origin* and *upstream*.
32
-
4. Create a virtual environment: `python3 -m venv /path/`. This can be anywhere on your machine. Activate it with `source /path/bin/activate`.
- Download the`sdkmanager` from the latest "command line tools only" package available [here](https://developer.android.com/studio) and unzip the package to your `$HOME` directory.
39
-
- Create a directory called `android-sdk` in your `$HOME` directory and move the unzipped `cmdline-tools` directory there.
40
-
- In the directory `cmdline-tools` create a sub-directory called `latest`.
41
-
- Move all the original contents from `cmdline-tools` into the newly created `latest` directory.
42
-
- cd into `cmdline-tools/latest/bin` and run the following commands to install adb and monkeyrunner:
43
-
```bash
44
-
./sdkmanager "platform-tools"
45
-
./sdkmanager "build-tools;30.0.0"
46
-
```
47
-
- Add the following to your `.bashrc` or `.zshrc` file:
- Reload your `.bashrc` or `.zshrc` settings by running `source ~/.bashrc` or `source ~/.zshrc`
54
-
- To verify if everything works correctly run `adb --version`. This should return its version number and install location. To do the same for Monkey Runner run `monkeyrunner --version`. This should return a `Unrecognized argument: --version`. but no other errors.
55
-
- Install lxml using `sudo apt install python3-lxml` (assuming python3 is being used).
- See [this](https://askubuntu.com/questions/740757/switch-between-multiple-java-versions) for switching between java versions
61
-
- lxml (`sudo apt install python-lxml`)
62
-
#### Other
63
-
- Download Android Studio from [here](https://developer.android.com/studio#downloads).
64
-
- Extract the archive, `cd` into its directory and install Android Studio by running `./bin/studio.sh`
65
-
- During the setup wizard Android Studio will ask you where you want to install the Android SDK. By default it is in`/home/user/Android/Sdk`
66
-
- The Android SDK, including ADB and Monkey Runner, is now installed on your system. To access the Android tools directly via your shell (preferable) add the following to your .bashrc/.zshrc:
67
-
68
-
```
69
-
export ANDROID_HOME=$HOME/Android/Sdk
70
-
export PATH=$PATH:$ANDROID_HOME/tools/bin
71
-
export PATH=$PATH:$ANDROID_HOME/platform-tools
72
-
```
73
-
- Reload your `.bashrc` or `.zshrc` settings by running `source ~/.bashrc` or `source ~/.zshrc`
74
-
- Since MonkeyRunner requires JDK 8 (not JDK 9) we need to install JDK 8: `sudo apt install openjdk-8-jre`.
75
-
- Once JDK 8 is installed we need to actually set it as default. See [here](https://askubuntu.com/questions/740757/switch-between-multiple-java-versions) how to do that.
76
-
- To verify if everything works correctly run `adb --version`. This should return its version number and install location. To do the same for Monkey Runner run `monkeyrunner --version`. This should return a `Unrecognized argument: --version.` but no other errors.
77
-
- Install lxml using `sudo apt install python-lxml`.
78
-
### macOS
79
-
- Make sure you have <a href="https://brew.sh/">Homebrew</a> installed
- Run `java -version`, if you are running a different version than 1.8/8:
83
-
- `brew install jenv`
84
-
- Run `/usr/libexec/java_home -V` to see the location of your Java environments
85
-
- Copy the location of your AdoptOpenJDK8 environment
86
-
- Run `jenv add <AdoptOpenJDK8_path>`
87
-
- Run `jenv global 1.8`
88
-
- Restart terminal and verify your Java version with `java -version`, it should output `openjdk version "1.8.0_265"`
89
-
- Verify that monkeyrunner works with `monkeyrunner --version`, it should output unrecognized argument and no other errors
90
-
2. Within Android Runner's main directory
91
-
- `pip install -r requirements.txt`
92
-
3. For creating or editing unit tests to ensure pull request passes TravisCI
93
-
- `pip install pytest mock`
94
-
95
-
**Note:** It is important that Monkeyrunner shares the same adb the experiment is using. Otherwise, there will be an adb restart and output may be tainted by the notification. You can specify the path to adb and/or Monkeyrunner in the experiment configuration file.
96
-
97
-
**Note 2:** The Batterystats, Trepn and Monsoon plugins have additional dependencies. Refer to the plugin [READMEs](https://github.com/S2-group/android-runner/tree/master/AndroidRunner/Plugins) for more information.
98
-
99
14
## Before You Begin
100
15
It's important for us to make sure that any updates to the framework add value and that the updates adhere to the original goals of the framework. Before spending a lot of time making substantial changes, please raise an `issue` on Github so we're made aware of the changes you'd like to implement. We'll provide feedback to inform you whether we think it's viable.
101
16
@@ -134,4 +49,5 @@ The best way to communicate with the Android Runner team is through:
134
49
- Canvas
135
50
136
51
## Debugging Tips
137
-
[pdb](https://docs.python.org/3/library/pdb.html) is a good library to import if you experience issues that may be hard to resolve with print statements.
52
+
[pdb](https://docs.python.org/3/library/pdb.html) is a good library to import if you experience issues that may be hard to resolve with print statements.
0 commit comments