# ApplicationSatelliteDatabaseCLI

This application is a toolbox for AMSATList project. It's help to work with xml file. 
 

## Context
 


## prerequisite 

Java installed on your computer 

 

 

 


## Installation

Retreive jar file from [electrolab Github](https://code.electrolab.fr/xtof/josast/) 



## Usage

 

To launch the application 

```java 

java -jar ApplicationSatelliteDatabaseCli.jar

```

To launch the application with option :

```
java -jar ApplicationSatelliteDatabaseCli -h

```
```
AppCli 0.72
usage: -h [-C] [-h] [-i <InputFile>] [-I <InputRepository>] [-M] [-O
       <OutputDirectory>] [-o <OutputFile>] [-U] [-V]
 -C,--Check                                verify AmsatList File data
 -h,--help                                 display help message
 -i,--InputFile <InputFile>                Input file
 -I,--Input Directory <InputRepository>    Input directory with all input
                                           xml files (*.xml)
 -M,--Merge                                Merge all input folder to new
                                           Directoy to ouput xml file
 -O,--Output Directory <OutputDirectory>   Output directory with all input
                                           xml files (*.xml)
 -o,--OutputFile <OutputFile>              output file
 -U,--Update                               update AmsatList File data
 -V,--Version                              Return application version
```

### Merge ###

Merge Satellite XML file from a folder to one file.

```
java -jar ApplicationSatelliteDatabaseCli.jar  -M -I ../DatabaseFile  -o  ../Data/AmsatList.xml
```

### Check ###

```
java -jar ApplicationSatelliteDatabaseCli.jar  -C -i src/test/data/FileIn/AmsatList.xml
```
 
 
### Update ###

Update files from on folder to an other. 

Updated data :
 - Satellite status
 - 
 
```
java -jar ApplicationSatelliteDatabaseCli.jar -U -I src/test/data/in  -O src/test/data/ou
```


## Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

## License
[GNU Lesser General Public License v2.1](http://choosealicense.com/licenses/lgpl-2.1/)
