Skip to content

Commit

Permalink
feat(assets): add graphic resources and translations (#16)
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaelje authored and ajsb85 committed Jul 17, 2017
1 parent 81f42fb commit 83f0afd
Show file tree
Hide file tree
Showing 97 changed files with 559 additions and 80 deletions.
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -75,3 +75,7 @@ build
gradle/
gradlew
gradlew.bat

#fastlane
/fastlane/README.md
/fastlane/report.xml
22 changes: 18 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,22 @@
language: android
android:
components:
- build-tools-22.0.1
- android-16

- build-tools-$BUILD_TOOL
- android-$ANDROID_API
- extra-android-m2repository
install:
- rvm install 2.3.4
- gem install fastlane
after_success:
- "./ci/deploy.sh"
notifications:
webhooks: https://fathomless-fjord-24024.herokuapp.com/notify
webhooks: https://fathomless-fjord-24024.herokuapp.com/notify
env:
global:
- BUILD_TOOL=22.0.1
- ANDROID_API=16
- secure: jhEI4J9G7OrxfHbv8Z10wXoQxXWklFakZcs3ze/U2CcxfYKN73xD5rpj5gaP45fFkKFZXccpZahWcmbpMjPRznJLmklGL8oNEdlD/zRmy7wr+d0TO1Bs3n8TskSJYQTF7iMjp14vuxANrpM3SHvpukp69uep0rOknCEqSp/kq7ARvjKVu3n7cMpkLdwXuHsLfA8mChY+E5eK3wPDW6Riz+YOARbmf48O44bGPgl+mzMdFMVGelRbtuTnvqX8WRfRbFHBX+VAwSFuIlQuJiikAzfxdSq6iaOKjFKXlC9rgFD2lZBWS9jDTBS/lP2qycCj8GveUbjQHw3x6P4XsKegC5LT0Ft/3KvCjySzs4Uwlbr7zbVE8u16X4jTpE1/3GcokM9q3Dv30T+lZTolI5KAGwDg+jJT4J/hRAjxMQBLApmx+eAeIQW2ZW8sRlTeUNAvXu4IbwU2/vEJJfYyGHGSs6dDUGyV/MJtZaWa2rZ+cwJDw/ne0pi660lVs6sTEHIdLs1DZIhL46XX4397CwdBHl9J+FpxdRASvurXCM0dFGr/UA9tyPLHO5sc35+B/CSAUuU5XacFTzU8l6KIvcae9jImdwcRyRw0lNnniWZSEYrt7jn6sRbRmcptSR6Wc/cM1A8QVqGogtrrz9eEe001U4zycyMpO8I8HAUYeBuFmfg=
- secure: Vu164TlxUBVLDm6qqleNKRAP6ttT4/Msu5YYOZCWjZS2WAgCp7xHlFloGRgGiJ12+j9umXZVDLMZbyeFdq22N8ncWKS/bW0njaH3UMcJ2+EMdYo4KDq/sFg3WER864oAUOohlDmGk923r2e4jvpqPcbHM7k3SPuNkxthbfVroNhIHgvKj6nDVxVUcGnn1blUBq7RcEnjpezPuXmE87o0Jl71Q9T83QhL/7uEz34Cq0wPlVKY3jZyfbo8gNdeiX3AxHmbXp+42vR4buGSupY1v67iK+RIr0be5aA27lLR+9zW4wCDN/5GbTMtKxSu/iNcdxA77iaMGDb/3V/RUgmYjD8OQynvF6IBP/4HsgGTrfnWzEI5iXIjogKIgrfiAAfAx5wd9dwsCWzJ5YURU4Qr0yFDyyCLz9mIlxSyXuSJEqtc8tivHTDZWcDPQioRkkWkFRW5Nn8QbgDvHRYJjcMnBlbGHt9YcgI1R1GtMJaqBBnfX7yhPH4D3InzXxEa8EB1fqkpos+Oq1mfDjb2sg51JULtdHOSaAqKQdmOHS24gYadqioiL1Rr3CH+kndvdlGJ1Gw3h3BasF5glPOyP7AzbTFS5FSSihRBy6WsSRZI1WmTqnFGmw00vtP9brIHdYkTTnZNuWyfw8QHiwPtuMR3Dwhzp/wTKrqlgMgqm3sZGEs=
before_install:
- openssl aes-256-cbc -K $encrypted_068c9b6f4b86_key -iv $encrypted_068c9b6f4b86_iv
-in google.tar.gz.enc -out ci/google.tar.gz -d
1 change: 1 addition & 0 deletions app/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/build
68 changes: 68 additions & 0 deletions app/build.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
apply plugin: 'com.android.application'

android {
compileSdkVersion 16
buildToolsVersion "22.0.1"

defaultConfig {
applicationId "org.flyve.inventory.agent"
minSdkVersion 12
targetSdkVersion 12
}

lintOptions {
checkReleaseBuilds false
abortOnError false
}

buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
}
}
}

repositories {
maven {
url 'https://dl.bintray.com/flyve-mdm/inventory'
}
}

dependencies {
compile 'com.flyvemdm:inventory:1.0.2@aar'
}

import java.util.regex.Pattern

task('increaseVersionCode') << {
def manifestFile = file("src/main/AndroidManifest.xml")
def pattern = Pattern.compile("versionCode=\"(\\d+)\"")
def manifestText = manifestFile.getText()
def matcher = pattern.matcher(manifestText)
matcher.find()
def versionCode = Integer.parseInt(matcher.group(1))
def manifestContent = matcher.replaceAll("versionCode=\"" + ++versionCode + "\"")
manifestFile.write(manifestContent)
}

task('incrementVersionName') << {
def manifestFile = file("src/main/AndroidManifest.xml")
def patternVersionNumber = Pattern.compile("versionName=\"(\\d+)\\.(\\d+)\\.(\\d+)\"")
def manifestText = manifestFile.getText()
def matcherVersionNumber = patternVersionNumber.matcher(manifestText)
matcherVersionNumber.find()
def majorVersion = Integer.parseInt(matcherVersionNumber.group(1))
def minorVersion = Integer.parseInt(matcherVersionNumber.group(2))
def pointVersion = Integer.parseInt(matcherVersionNumber.group(3))
def mNextVersionName = majorVersion + "." + minorVersion + "." + (pointVersion+1)
def manifestContent = matcherVersionNumber.replaceAll("versionName=\"" + mNextVersionName + "\"")
manifestFile.write(manifestContent)
}

tasks.whenTaskAdded { task ->
if (task.name == 'generateReleaseBuildConfig' || task.name == 'generateDebugBuildConfig') {
task.dependsOn 'increaseVersionCode'
task.dependsOn 'incrementVersionName'
}
}
29 changes: 15 additions & 14 deletions src/main/AndroidManifest.xml → app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="org.flyve.inventory.agent"
android:versionCode="1"
android:versionName="1.0">
<uses-sdk android:minSdkVersion="12"/>
android:versionName="1.0.16"
android:versionCode="24">

<!-- Permissions -->
<uses-permission
android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
Expand Down Expand Up @@ -41,18 +41,25 @@
android:vmSafeMode="true"
android:theme="@style/AppTheme"
android:icon="@drawable/icon">
<activity
android:name="org.flyve.inventory.agent.Accueil"
android:label="@string/app_name" android:launchMode="standard">
</activity>
<activity android:name=".SplashActivity">
<activity android:name=".SplashActivity"
android:theme="@style/NoActionBar"
>
<intent-filter>
<action
android:name="android.intent.action.MAIN" />
<category
android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name="org.flyve.inventory.agent.Accueil"
android:label="@string/app_name" android:launchMode="standard">
</activity>
<activity
android:name="org.flyve.inventory.agent.Settings"
android:launchMode="singleInstance"
android:label="@string/agent_settings">
</activity>
<service
android:enabled="true"
android:label="Inventory Agent"
Expand Down Expand Up @@ -90,11 +97,5 @@
android:name="android.intent.category.HOME" />
</intent-filter>
</receiver>
<activity
android:name="org.flyve.inventory.agent.Settings"
android:launchMode="singleInstance"
android:label="@string/agent_settings"></activity>
</application>


</manifest>
Binary file added app/src/main/res/drawable-hdpi/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/src/main/res/drawable-hdpi/logoinventory.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/src/main/res/drawable-hdpi/logoteclib.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/src/main/res/drawable-mdpi/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/src/main/res/drawable-xhdpi/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/src/main/res/drawable-xxhdpi/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added app/src/main/res/drawable-xxxhdpi/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
27 changes: 27 additions & 0 deletions app/src/main/res/layout/activity_splash.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
>

<ImageView
android:id="@+id/imgInventory"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@drawable/logoinventory"
android:layout_centerHorizontal="true"
android:layout_centerVertical="true"
/>

<ImageView
android:id="@+id/imgLogoTeclib"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@drawable/logoteclib"
android:layout_alignParentBottom="true"
android:layout_marginBottom="40dp"
android:layout_centerHorizontal="true"
/>

</RelativeLayout>
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
39 changes: 39 additions & 0 deletions app/src/main/res/values-es/strings.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="agent_started">Inventory Agent esta comenzando</string>
<string name="agent_stopped">Inventory Agent se detuvo</string>
<string name="agent_reboot">Inventory Agent se esta reiniciando</string>
<string name="agent_description">El agente esta en proceso de fondo</string>
<string name="button_start_inventory">Comenzando el Inventario</string>
<string name="menu_settings">Configuración</string>
<string name="menu_clearlog">Limpiar Historial</string>
<string name="menu_send">Enviar</string>
<string name="menu_getinv">Obtener Inventario</string>
<string name="all_permissions">Grant all possible permissions</string>
<string name="agent_connected">Conectado al servicio</string>
<string name="agent_disconnected">Desconectado del servicio</string>
<string name="inventory_started">Comenzando el inventario...</string>
<string name="inventory_sended">Enviando el inventario...</string>
<string name="inventory_ended">Fin del inventario.</string>
<string name="button_connect_agent">Agente Conectado</string>
<string name="button_disconnect_agent">Agente Desconectado</string>
<string name="error_inventory">No se completo el Inventario</string>
<string name="ok_inventory">Inventario completo</string>
<string name="error_send_inventoryi">El inventario no fue enviado</string>
<string name="ok_send_inventory">Inventario enviado</string>
<string name="service_notif_id">Inventory Agent</string>
<string-array name="agent_status">
<item>El agente espera una orden ...</item>
<item>El agent esta organizando el inventario ...</item>
</string-array>
<string name="agent_settings">Configuración del Agent</string>
<string name="phone_boot">El agente puede ser activido luego de reiniciar</string>
<string name="manual_launch">El agente debe ser activado manualmente</string>
<string name="boot_options">Opciones de reinicio</string>
<string name="inventory_server">Servidor de Inventario</string>
<string name="log_text">Respuesta del servidor</string>
<string name="authentication_credentials">Credenciales de autorización HTTP</string>
<string name="login">Usuario</string>
<string name="password">Contraseña</string>
<string name="tag">Etiqueta</string>
</resources>
40 changes: 40 additions & 0 deletions app/src/main/res/values-es/strings_pref_accueil.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>

<!-- Accueil Preferences -->

<string name="AccueilTitle">Configuración de la aplicación</string>

<!-- Inventory part -->

<string name="AccueilInventoryTitle">Inventario</string>
<string name="AccueilInventorySummaryOn">Click para desactivar el inventario</string>
<string name="AccueilInventorySummaryOff">Click para activar el inventario</string>
<string name="AccueilInventoryRun">Correr el inventario ahora!</string>
<string name="AccueilInventoryRunSummary">Correr ahora!</string>
<string name="AccueilInventoryParam">Parametros del inventario</string>
<string name="AccueilInventoryParamSummary">Frecuencia del inventario</string>

<!-- Remote view part -->

<string name="AccueilRemoteTitle">Vista remota</string>
<string name="AccueilRemoteSummaryOn">Click para desactivar la vista remota</string>
<string name="AccueilRemoteSummaryOff">Click para activar la vista remota</string>
<string name="AccueilRemoteParam">Parametros de la vista remota</string>
<string name="AccueilRemoteParamSummary">Configurar la vista remota</string>

<!-- SSH part -->

<string name="AccueilSshTitle">Secure Shell</string>
<string name="AccueilSshSummaryOn">Click para desactivar SSH</string>
<string name="AccueilSshSummaryOff">Click para activar SSH</string>

<!-- global part -->

<string name="AccueilGlobalTitle">Global</string>
<string name="AccueilGlobalParam">Configuración Global</string>
<string name="AccueilGlobalParamSummary">Configurar certificados, servidores ...</string>



</resources>
30 changes: 30 additions & 0 deletions app/src/main/res/values-es/strings_pref_global.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>

<!-- Global settings part -->

<string name="GlobalCat">Global</string>

<string name="GlobalBoot">Opciones de reinicio</string>
<string name="GlobalBootSummaryOn">Click para desactivar el reinicio automatico</string>
<string name="GlobalBootSummaryOff">Click para activar el reinicio automatico</string>

<string name="GlobalNotif">Notificaciones</string>
<string name="GlobalNotifSummaryOn">Click para desactivar las notificaciones</string>
<string name="GlobalNotifSummaryOff">Click para activar las notificaciones</string>

<string name="GlobalCatSet">Configuracion del servidor</string>

<string name="GlobalServer">Dirección del Servidor</string>
<string name="GlobalServerSummary">Define la dirección del servidor</string>

<string name="GlobalService">Autenticación</string>
<string name="GlobalServiceSummary">Configura contraseñas, llaves públicas ...</string>

<string name="GlobalCatAdvanced">Configuración Advanzada</string>

<string name="GlobalAdvanced">Configuración avanzada</string>
<string name="GlobalAdvancedSummary">Configura daemon settings, dirección de binarios ...</string>

</resources>

17 changes: 17 additions & 0 deletions app/src/main/res/values-es/strings_pref_inventory.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>

<!-- Inventory Preferences -->

<string name="InventoryCat">Inventario</string>

<string name="InventoryAuto">Inventario automatico</string>
<string name="InventoryAutoSummaryOn">Click para desactivar el inventario automatico</string>
<string name="InventoryAutoSummaryOff">Click para activar el inventario automatico</string>

<string name="InventoryFrequency">Frecuencia</string>
<string name="InventoryFrequencyDialog">Cada :</string>
<string name="InventoryFrequencySummary">Define la frecuencia</string>

</resources>

14 changes: 14 additions & 0 deletions app/src/main/res/values-es/value_time.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string-array name="Time">
<item>día</item>
<item>semana</item>
<item>mes</item>
</string-array>
<string-array name="TimeValue">
<item>Día</item>
<item>Semana</item>
<item>Mes</item>
</string-array>
</resources>

Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string
name="app_name"
>Inventory Agent</string>
<string
name="agent_started"
>L\'agent Inventory est démarré</string>
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="app_name">Inventory Agent</string>
<string name="app_name">Inventory</string>
<string name="agent_started">Inventory Agent is started</string>
<string name="agent_stopped">Inventory Agent is stopped</string>
<string name="agent_reboot">Inventory Agent is restarted</string>
Expand Down
File renamed without changes.
File renamed without changes.
9 changes: 9 additions & 0 deletions app/src/main/res/values/styles.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<resources>
<style name="AppTheme" parent="android:Theme.Holo.Light"/>

<style name="NoActionBar" parent="android:Theme.Holo.Light">
<item name="android:windowActionBar">false</item>
<item name="android:windowNoTitle">true</item>
</style>

</resources>
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading

0 comments on commit 83f0afd

Please sign in to comment.