2019-12-11 18:06:54 +03:00
|
|
|
#ifndef DEPLOYCONFIG_H
|
|
|
|
#define DEPLOYCONFIG_H
|
|
|
|
#include "deploy_global.h"
|
|
|
|
|
2019-12-13 23:05:07 +03:00
|
|
|
#include "distromodule.h"
|
2019-12-23 10:12:23 +03:00
|
|
|
#include "extra.h"
|
2019-12-11 18:06:54 +03:00
|
|
|
#include "ignorerule.h"
|
2019-12-23 10:12:23 +03:00
|
|
|
#include "qtdir.h"
|
2019-12-11 18:06:54 +03:00
|
|
|
#include "targetinfo.h"
|
|
|
|
|
2019-12-12 22:50:04 +03:00
|
|
|
class DEPLOYSHARED_EXPORT DeployConfig {
|
2019-12-11 18:06:54 +03:00
|
|
|
|
2019-12-12 22:50:04 +03:00
|
|
|
public:
|
2019-12-11 18:06:54 +03:00
|
|
|
/**
|
|
|
|
* @brief depchLimit - recursive search limit
|
|
|
|
*/
|
|
|
|
int depchLimit = 0;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @brief deployQml - enable or disable deploing of qml files.
|
|
|
|
*/
|
|
|
|
bool deployQml = false;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @brief ignoreList - list with ignore files
|
|
|
|
*/
|
|
|
|
IgnoreRule ignoreList;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @brief appDir - it is cqtdeployer library location for ignre cqtdeployr libraries
|
|
|
|
*/
|
|
|
|
QString appDir;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @brief qtDir - conteins all qt pathes
|
|
|
|
*/
|
|
|
|
QtDir qtDir;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @brief extraPaths - it is list with filters for extra pathes, files or libraries
|
|
|
|
*/
|
|
|
|
Extra extraPaths;
|
2019-12-13 23:05:07 +03:00
|
|
|
|
2020-10-14 20:32:38 +03:00
|
|
|
/**
|
|
|
|
* @brief allowedPaths - it is list with filters for allowed pathes, files or libraries
|
|
|
|
*/
|
|
|
|
Extra allowedPaths;
|
|
|
|
|
2019-12-11 18:06:54 +03:00
|
|
|
/**
|
|
|
|
* @brief envirement - envirement for find libraries
|
|
|
|
*/
|
|
|
|
Envirement envirement;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @brief reset config file to default
|
|
|
|
*/
|
|
|
|
void reset();
|
|
|
|
QHash<QString, TargetInfo *> getTargetsListByFilter(const QString& filter);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @brief targetPath
|
|
|
|
* @param target
|
2019-12-12 22:50:04 +03:00
|
|
|
* @return path to deployement root dir of target.
|
|
|
|
* If target value well be empty then return main root of all targets.
|
2019-12-11 18:06:54 +03:00
|
|
|
*/
|
2019-12-12 22:50:04 +03:00
|
|
|
QString getTargetDir(const QString& target = "") const;
|
2020-04-25 18:16:02 +03:00
|
|
|
|
|
|
|
/**
|
|
|
|
* @brief setTargetDir
|
|
|
|
* @param target
|
|
|
|
*/
|
2019-12-14 17:38:43 +03:00
|
|
|
void setTargetDir(const QString& target);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @brief getDistro
|
|
|
|
* @param target
|
|
|
|
* @return
|
|
|
|
*/
|
2020-01-02 19:27:40 +03:00
|
|
|
DistroModule getDistro(const QString& target) const;
|
2019-12-12 22:50:04 +03:00
|
|
|
|
2019-12-15 18:30:24 +03:00
|
|
|
/**
|
2020-01-27 20:02:25 +03:00
|
|
|
* @brief getDistroFromPackage
|
|
|
|
* @param package
|
|
|
|
* @return distro struct from package
|
2019-12-15 18:30:24 +03:00
|
|
|
*/
|
2020-01-27 20:02:25 +03:00
|
|
|
DistroModule getDistroFromPackage(const QString& package) const;
|
2020-01-02 19:27:40 +03:00
|
|
|
|
|
|
|
const QHash<QString, TargetInfo>& targets() const;
|
2020-01-27 20:02:25 +03:00
|
|
|
const QHash<QString, DistroModule>& packages() const;
|
2020-01-02 19:27:40 +03:00
|
|
|
|
|
|
|
QHash<QString, TargetInfo>& targetsEdit();
|
2020-01-27 20:02:25 +03:00
|
|
|
QHash<QString, DistroModule>& packagesEdit();
|
2019-12-15 18:30:24 +03:00
|
|
|
|
2020-10-12 22:23:36 +03:00
|
|
|
/**
|
|
|
|
* @brief getPlatform This method return a platform of distribution.
|
|
|
|
* If you set a pacakge name then this method return platform of package.
|
|
|
|
* @param package This is name of pacakge. Set this parameter to empty string for get a distribution of all pacakges.
|
|
|
|
* @return platform of distribution.
|
|
|
|
*/
|
2020-07-04 18:13:32 +03:00
|
|
|
Platform getPlatform(const QString& package) const;
|
2020-07-02 16:00:34 +03:00
|
|
|
|
2020-10-14 13:17:26 +03:00
|
|
|
/**
|
|
|
|
* @brief getPlatformOfAll This method return paltform of all targets of distributuon.
|
|
|
|
* @return platform of all targets.
|
|
|
|
*/
|
|
|
|
Platform getPlatformOfAll() const;
|
|
|
|
|
2019-12-12 22:50:04 +03:00
|
|
|
private:
|
|
|
|
|
2020-01-02 19:27:40 +03:00
|
|
|
/**
|
|
|
|
* @brief targets
|
|
|
|
* key - path
|
|
|
|
* value - create wrapper
|
|
|
|
*/
|
|
|
|
QHash<QString, TargetInfo> _targets;
|
|
|
|
|
|
|
|
/**
|
2020-01-27 20:02:25 +03:00
|
|
|
* @brief packages
|
|
|
|
* key - package
|
|
|
|
* value struvture of package
|
|
|
|
* default package is empty value
|
2020-01-02 19:27:40 +03:00
|
|
|
*/
|
2020-01-27 20:02:25 +03:00
|
|
|
QHash<QString, DistroModule> _packages;
|
2020-01-02 19:27:40 +03:00
|
|
|
|
2019-12-12 22:50:04 +03:00
|
|
|
/**
|
|
|
|
* @brief targetDir - targe directory (this folder conteins all files of distrebution kit)
|
|
|
|
*/
|
|
|
|
QString targetDir = "";
|
|
|
|
|
2019-12-11 18:06:54 +03:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
#endif // DEPLOYCONFIG_H
|