Skip to content
This repository has been archived by the owner on Jan 21, 2021. It is now read-only.

Commit

Permalink
✨ Fix Adaptive Icons and 📝 update documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
micahlt committed Sep 10, 2020
1 parent 1be16c3 commit 6c1ebe1
Show file tree
Hide file tree
Showing 25 changed files with 2,696 additions and 45 deletions.
9 changes: 5 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ A mobile app for Scratch Client 4 built with Apache Cordova
## Building
### Requirements
- [Git](https://git-scm.org)
- [Node.js](https://nodejs.org) and NPM (most likely bundled with Node.js)
- [Node.js](https://nodejs.org) and NPM (most likely bundled with your Node.js installation)
- The Cordova CLI, install it with `npm install -g cordova`
- Note : [macOS users might need to change directory permisisons if getting a permission error.](https://stackoverflow.com/a/47252840/10074924).
- A JDK, Android Studio, and Gradle. Install them according to [this guide](https://cordova.apache.org/docs/en/latest/guide/platforms/android/index.html).
Expand All @@ -22,18 +22,19 @@ First, clone the repository:
```bash
git clone https://github.com/scratch-client-4/mobile
```
Then go into it:
Then go into it and install all dependencies:
```bash
cd mobile
npm install
```

You should see two version numbers appear. Then run the build script:
```bash
npm run-script build
```
It'll build you the runnable source files (HTML, CSS, and JavaScript) in a directory called `www`. After that you can build the project into an Android APK file:
It'll build you the runnable source files (HTML, CSS, and JavaScript) in a directory called `www`. After that you can build the project into an Android package (APK) file:
```bash
cordova platform add android
cordova build
cordova build android --minSdkVersion=22
```
The last few lines of the output of that command will tell you where the APK is located.
17 changes: 9 additions & 8 deletions config.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version='1.0' encoding='utf-8'?>
<widget id="org.scratchclient4.sc4mobile" version="0.1.2" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
<widget id="org.scratchclient4.sc4mobile" version="0.1.3" android-versionCode="9" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
<name>Itchy</name>
<description>
A Scratch client for Android mobile devices.
Expand All @@ -11,7 +11,7 @@
<!-- Note : Portrait orientation is voluntarily not enforced. -->
<preference name="target-device" value="handset" />
<preference name="DisallowOverscroll" value="true" />
<preference name="android-minSdkVersion" value="19" />
<preference name="android-minSdkVersion" value="22" />
<plugin name="cordova-plugin-whitelist" spec="1" />
<access origin="*" />
<allow-intent href="http://*/*" />
Expand All @@ -21,11 +21,12 @@
<allow-intent href="mailto:*" />
<allow-intent href="geo:*" />
<platform name="android">
<allow-intent href="market:*" />
<icon src="asset/icon.png" />
</platform>
<platform name="ios">
<allow-intent href="itms:*" />
<allow-intent href="itms-apps:*" />
<icon background="resources/android/icon/ldpi-background.png" density="ldpi" foreground="resources/android/icon/ldpi-foreground.png" src="resources/android/icon/drawable-ldpi-icon.png" />
<icon background="resources/android/icon/mdpi-background.png" density="mdpi" foreground="resources/android/icon/mdpi-foreground.png" src="resources/android/icon/drawable-mdpi-icon.png" />
<icon background="resources/android/icon/hdpi-background.png" density="hdpi" foreground="resources/android/icon/hdpi-foreground.png" src="resources/android/icon/drawable-hdpi-icon.png" />
<icon background="resources/android/icon/xhdpi-background.png" density="xhdpi" foreground="resources/android/icon/xhdpi-foreground.png" src="resources/android/icon/drawable-xhdpi-icon.png" />
<icon background="resources/android/icon/xxhdpi-background.png" density="xxhdpi" foreground="resources/android/icon/xxhdpi-foreground.png" src="resources/android/icon/drawable-xxhdpi-icon.png" />
<icon background="resources/android/icon/xxxhdpi-background.png" density="xxxhdpi" foreground="resources/android/icon/xxxhdpi-foreground.png" src="resources/android/icon/drawable-xxxhdpi-icon.png" />
<allow-intent href="market:*" />
</platform>
</widget>
Loading

0 comments on commit 6c1ebe1

Please sign in to comment.