Staartvin / Autorank-2

Autorank is a Spigot/Bukkit plugin for automatically ranking players based on requirements
Other
56 stars 61 forks source link

Enhance import functionality #690

Closed Staartvin closed 4 years ago

Staartvin commented 4 years ago

The import method should be able to do the following separately:

New arguments that have been added:

DarkObscurity commented 4 years ago

Add an option to the general config "serverName:" where people can define a server name. This could be used to save the flatfile named [serverName]-autorank.sql or something. Then you can put flatfiles in a folder called "import".

You can use the command "/ar import" and then autorank will import all flatfiles in which are currently in the "import" folder.

Then there are 5 parameters for the "import" command: --db will add the time which is being imported to the current flatfile but also to the database. --db-only will only import the time and add it to the database --overwrite will overwrite all data in the flatfile and database --overwrite-flatfile will overwrite all data in the flatfile --overwrite-db will overwrite all data in the database

It would be awesome if the parameters could be used together, so then --database --overwrite-flatfile will import the data and overwrite the flatfile, but will "add" the value's to the database and not overwrite the current value's in the database.