Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 84671188 authored by AVINASH GUSAIN's avatar AVINASH GUSAIN Committed by Weblate
Browse files

Translated using Weblate (German)

Currently translated at 17.3% (18 of 104 strings)

Translation: /e/ support center/Pages/Easy-Installer-Contribute
Translate-URL: https://i18n.e.foundation/projects/e-support-center/pageseasy-installer-contribute/de/
parent 92cafbe9
Loading
Loading
Loading
Loading
+61 −36
Original line number Diff line number Diff line
@@ -55,25 +55,17 @@ von den "buildSrc"- und "flash-scripts"-Ordnern in das Build.
Es benutzt das ["badass jlink plugin"](https://badass-jlink-plugin.beryx.org/releases/latest/#_properties)


## Funktions-Idee
- make `./gradlew dist` to create a build for one platform at a time depending on a param.
i.e: `./gradlew dist windows` or `./gradlew dist linux`
## Feature idea
- **Add support for a new device**
    - You need to own the device
    - First step is to create configuration files for the Easy Installer
    - If necessary, create the missing scripts to be able to achieve the installation

1. Ich möchte helfen **/e/ auf Windows zu portieren**
    - Sie können uns helfen, Skripte für Windows zu übersetzen.
    - wenn Sie etwas Wissen mitbringen, um Windows-Anwendungen zu paketieren (wie wir mit Snap auf Linux gemacht haben)
    - Sobald die 2 vorherigen Punkte erledigt sind, können Sie testen, ob alles unter Windows genauso läuft wie unter Linux

1. Ich möchte helfen, **/e/ auf MacOS zu portieren**
    - Sie können überprüfen, ob unsere Skripte mit MacOS kompatibel sind
    - wenn Sie Wissen mitbringen, MacOS-Anwendungen zu paketieren (wie wir mit Snap auf Linux gemacht haben)
    - Sobald die 2 vorherigen Punkte erledigt sind, können Sie testen, ob alles unter MacOS genauso läuft wie unter Linux

1. Ich möchte **Unterstützung für ein neues Gerät hinzufügen**
    - Sie müssen das Gerät besitzen
    - Erstellen Sie als erstes Konfigurationsdateien für den Easy-Installer
    - Erstellen Sie, wenn nötig, die fehlenden Skripten, um die Installation durchführen zu können

## How to support or add a new device ?

The easy-installer uses two configuration files for each device.
@@ -143,10 +135,8 @@ _example: `herolte` for S7, `hero2lte` for S7 edge, `dreamlte` for S8, ..._
- `script` contains the name of the flash-script to call. There is no extension because it is defined at runtime (this allows to use either ".sh" for linux and mac or ".bat" for windows)
- `parameters` contains a map of parameters to use when the script is called. The order should be the one expected by the script. There are two types of values for a parameter:

	1. a fixed parameter which is a raw string.
	_example: `my_key: foobar`_
	2. a changing parameter which is defined at runtime. Then its value must be the key - in uppercase - wrapped in '{' and starts with '$'.
	_example: `my_key: ${MY_KEY}`_
- `Name` defines the codename of the device. This value is a simple String.
_example: `herolte` for S7, `hero2lte` for S7 edge, `dreamlte` for S8, ..._

- `codes` contains two sub lists: `ok` corresponds to script's exit when the step succeeds, and `ko` corresponds to script's exit when there is an error.
The codes returned by the script are always numeric value.
@@ -221,10 +211,38 @@ Each different files that needs to be downloaded should be specified here.
Use a key to identify it :
_example: `rom`, `twrp`, `vendor`, `patch`, ..._

- `url` specifies the url that points to the resource.
	_example: `url: https://path/to/the/file.extension`_
``` yaml
sources:
   rom:
        url: https://images.ecloud.global/stable/herolte/e-latest-herolte.zip
        filePath: e-latest-herolte.zip
   twrp:         
        url: https://images.ecloud.global/stable/twrp/herolte/twrp-3.2.3-0-herolte.img
        filePath: twrp-3.2.3-0-herolte.img
flash:
    f1:
        ui:
            type: action
            title: stepTitle1On7
            instruction:
            - install_instr_turnOff
            - install_instr_startDownload
            - install_instr_acceptWarning
            stepNumber: 1/7
            titleIcon: Download.png
            instructionImg: group2.png
    f2:
        ui:
            type: load
            title: stepTitle2On7
            instruction:
            - install_instr_oemUnlock
            stepNumber: 2/7
            averageTime: 8
...
```

-`filePath` specifies the file's name on the user's computer once it has been downloaded
It contains two parts: `sources` which specifies files that need to be downloaded and `flash` which defines UI for the different steps.


__/!\ files must have a sha256sum to check integrity. The sha256 should be the exact filename(with extension) +".sha256sum". The sha256sum should be in the same folder as the target file. It will be automaticaly downloaded.__
@@ -232,9 +250,10 @@ __/!\ files must have a sha256sum to check integrity. The sha256 should be the e

#### `flash`

Uses the exact same key as in the first file. They must be identical.
- `url` specifies the url that points to the resource.
	_example: `url: https://path/to/the/file.extension`_

`ui` contains an element which defines what is displayed during the step.
-`filePath` specifies the file's name on the user's computer once it has been downloaded

There are three types of UI (user interface): `action`, `load` and `askAccount`

@@ -284,9 +303,7 @@ It is also used to identify pictures to display along with the instruction. Pict



#### `askAccount` type
It's a special type, which only contains `type: askAccount`.
Its step key (f<number>) should fit with the one which defines "script: askAccount" in the first file.
- `instruction` is the same as for `action` type except that it must have only one instruction.

#### Good practice:
- '~': is used for empty or null value.
@@ -296,7 +313,9 @@ Its step key (f<number>) should fit with the one which defines "script: askAccou
## Lets make the translation file


### What is the translation file?
#### `askAccount` type
It's a special type, which only contains `type: askAccount`.
Its step key (f<number>) should fit with the one which defines "script: askAccount" in the first file.

A translation file has extension ".properties".

@@ -327,12 +346,11 @@ a Row is structured with the following pattern: `reference=value`

_example:_ trad_1_title=first title of the translation

_note:_ if you add a space between the `=` and the first character of your translation, the displayed message will include this space too.
But you can add a space between the reference and the `=`  without any problem.
_one row = one translation

#### a. Line break
In most case, you should let the application decide to break line or not.
If you really need a line break, use `\n`.
a Row is structured with the following pattern: `reference=value`
- `reference` is the code used to load the value.
- `value` is the raw text that will be display to the user

_example_: trad-example=firstline\nsecondline

@@ -342,15 +360,17 @@ firstline
secondline
```

### How to choose `reference` for a translation
In order to have easy to maintain translation's file,
We'll define `reference` following a defined pattern.
_example_: trad-example=firstline\nsecondline

Each part of the pattern will be separated by `"_"`

1. First part is an identifier for the UI which use the button.

2. Second part is an element type identifier. Is it a simple label ? a title ? a button ?
Result:
```
firstline
secondline
```

3. third part is a unique identifier

@@ -405,7 +425,12 @@ The incremental value restart from 0 for each UI's identifier and each element t

or use a text identifier.

or no unique identifier if this is the only one element of this type
- Main title : `mTitle`
- title: `title`
- subtitle : `sbTitle`
- Label : `lbl`
- Button : `btn`
- instruction: `instr`

#### d. Real example
_note_: in the following example, the value describe the position or the content, but it can be anything else.