This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <QStandardPaths> | |
#include <sys/stat.h> | |
#include <sys/types.h> | |
QString GetConfPath() { | |
// Get configuration path for MacOS. | |
std::string directory = QStandardPaths::standardLocations(QStandardPaths::AppDataLocation).at(0).toStdString(); | |
std::string conf_path = directory + "/QtTermTCP.ini"; | |
mkdir(directory.c_str(), 0775); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bool Database::compare_date(const Drink &a, const Drink &b) { | |
/* | |
* Determine if second date is greater than the first date. | |
* @param a: Date from a struct in YYYY-MM-DD format | |
* @param b: Date from b struct in YYYY-MM-DD format | |
* @return: True if second date is more recent than the first date. Else, false. | |
*/ | |
int a_year = std::stoi(a.date.substr(0, 4)); | |
int a_month = std::stoi(a.date.substr(5, 7)); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
############################################################# | |
# # | |
# Configuration file for Dire Wolf # | |
# # | |
# Macintosh version # | |
# # | |
############################################################# | |
# | |
# Consult the User Guide for more details on configuration options. | |
# |
OlderNewer