bot: refactor and clean up old code
fix: crash when saving old format pwf on hlds bot: moved sdk headers to separate submodule nav: improved unstuck and avoidance (thanks @commandcobra7) code bot: use correct path slashes depending on platform for all data cfg: removed simplified chines' translation, as it's too outdated
This commit is contained in:
parent
48e157c7b4
commit
7b58d51973
42 changed files with 365 additions and 3805 deletions
|
|
@ -17,31 +17,54 @@
|
|||
|
||||
// simple class for bot internal information
|
||||
class Product final : public Singleton <Product> {
|
||||
public:
|
||||
explicit constexpr Product () = default;
|
||||
~Product () = default;
|
||||
|
||||
public:
|
||||
struct Build {
|
||||
StringRef hash { MODULE_COMMIT_COUNT };
|
||||
StringRef count { MODULE_COMMIT_HASH };
|
||||
StringRef author { MODULE_AUTHOR };
|
||||
StringRef machine { MODULE_MACHINE };
|
||||
StringRef compiler { MODULE_COMPILER };
|
||||
StringRef id { MODULE_BUILD_ID };
|
||||
static constexpr StringRef hash { MODULE_COMMIT_COUNT };
|
||||
static constexpr StringRef count { MODULE_COMMIT_HASH };
|
||||
static constexpr StringRef author { MODULE_AUTHOR };
|
||||
static constexpr StringRef machine { MODULE_MACHINE };
|
||||
static constexpr StringRef compiler { MODULE_COMPILER };
|
||||
static constexpr StringRef id { MODULE_BUILD_ID };
|
||||
} build {};
|
||||
|
||||
public:
|
||||
StringRef name { "YaPB" };
|
||||
StringRef year { &__DATE__[7] };
|
||||
StringRef author { "YaPB Project" };
|
||||
StringRef email { "yapb@jeefo.net" };
|
||||
StringRef url { "https://yapb.jeefo.net/" };
|
||||
StringRef download { "yapb.jeefo.net" };
|
||||
StringRef folder { "yapb" };
|
||||
StringRef logtag { "YB" };
|
||||
StringRef dtime { __DATE__ " " __TIME__ };
|
||||
StringRef date { __DATE__ };
|
||||
StringRef version { MODULE_VERSION "." MODULE_COMMIT_COUNT };
|
||||
StringRef cmdPri { "yb" };
|
||||
StringRef cmdSec { "yapb" };
|
||||
static constexpr StringRef name { "YaPB" };
|
||||
static constexpr StringRef nameLower { "yapb" };
|
||||
static constexpr StringRef year { &__DATE__[7] };
|
||||
static constexpr StringRef author { "YaPB Project" };
|
||||
static constexpr StringRef email { "yapb@jeefo.net" };
|
||||
static constexpr StringRef url { "https://yapb.jeefo.net/" };
|
||||
static constexpr StringRef download { "yapb.jeefo.net" };
|
||||
static constexpr StringRef logtag { "YB" };
|
||||
static constexpr StringRef dtime { __DATE__ " " __TIME__ };
|
||||
static constexpr StringRef date { __DATE__ };
|
||||
static constexpr StringRef version { MODULE_VERSION "." MODULE_COMMIT_COUNT };
|
||||
static constexpr StringRef cmdPri { "yb" };
|
||||
static constexpr StringRef cmdSec { "yapb" };
|
||||
};
|
||||
|
||||
class Folders final : public Singleton <Folders> {
|
||||
public:
|
||||
explicit constexpr Folders () = default;
|
||||
~Folders () = default;
|
||||
|
||||
public:
|
||||
static constexpr StringRef bot { "yapb" };
|
||||
static constexpr StringRef addons { "addons" };
|
||||
static constexpr StringRef config { "conf" };
|
||||
static constexpr StringRef data { "data" };
|
||||
static constexpr StringRef lang { "lang" };
|
||||
static constexpr StringRef logs { "logs" };
|
||||
static constexpr StringRef train { "train" };
|
||||
static constexpr StringRef graph { "graph" };
|
||||
static constexpr StringRef podbot { "pwf" };
|
||||
static constexpr StringRef ebot { "ewp" };
|
||||
};
|
||||
|
||||
// expose product info
|
||||
CR_EXPOSE_GLOBAL_SINGLETON (Product, product);
|
||||
CR_EXPOSE_GLOBAL_SINGLETON (Folders, folders);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue