Skip to content

Commit

Permalink
Version 6.0.4
Browse files Browse the repository at this point in the history
  • Loading branch information
Bionus committed Aug 5, 2018
2 parents 63251cb + be23d91 commit a35b805
Show file tree
Hide file tree
Showing 338 changed files with 8,019 additions and 6,992 deletions.
6 changes: 4 additions & 2 deletions .codecov.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,11 @@ coverage:
changes: false

ignore:
- "tests/*"
- "vendor/*"
- "build/*"
- "CrashReporter/*"
- "e2e/*"
- "lib/src/vendor/*"
- "tests/*"

comment:
layout: "header, diff"
Expand Down
22 changes: 0 additions & 22 deletions .github/ISSUE_TEMPLATE.md

This file was deleted.

40 changes: 40 additions & 0 deletions .github/ISSUE_TEMPLATE/bug-report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
---
name: Bug report
about: Report a bug to help us fix it
---

**Bug description**

A clear and concise description of what the bug is.

**Steps to reproduce**

1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error

**Expected behavior**

A clear and concise description of what you expected to happen.

**Context**

* Provide your `main.log` file to see if any obvious error occured.
* Providing your `settings.ini` file will greatly help maintainers reproduce your problem if it may be caused by your configuration.
* If the bug occured during a download, make sure to provide said download as an `.igl` file that Grabber can generate by clicking the `Save` button of the `Downloads` tab.

Note that both `main.log` and `settings.ini` files can be found in `C:/Users/%USERNAME%/AppData/Local/Bionus/Grabber` in Windows, and in the installation directory on Linux.

**Screenshots**

If applicable, add screenshots to help explain your problem.

**System information**

- OS: [e.g. Windows 10]
- Grabber version: [e.g. 6.0.3]

**Additional context**

Add any other context about the bug report here.
33 changes: 33 additions & 0 deletions .github/ISSUE_TEMPLATE/crash-report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
---
name: Crash report
about: Report a program crash to help us fix it
---

**Steps to reproduce**

1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error

**Context**

* Provide your `main.log` file to see if any obvious error occured.
* Providing your `settings.ini` file will greatly help maintainers reproduce your problem if it may be caused by your configuration.
* If the crash occured during a download, make sure to provide said download as an `.igl` file that Grabber can generate by clicking the `Save` button of the `Downloads` tab.
* Provide the crash dump that was linked by the Crash Reporter tool.

Note that both `main.log` and `settings.ini` files can be found in `C:/Users/%USERNAME%/AppData/Local/Bionus/Grabber` in Windows, and in the installation directory on Linux.

**Screenshots**

If applicable, add screenshots to help explain your problem.

**System information**

- OS: [e.g. Windows 10]
- Grabber version: [e.g. 6.0.3]

**Additional context**

Add any other context about the crash report here.
20 changes: 20 additions & 0 deletions .github/ISSUE_TEMPLATE/feature-request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
name: Feature request
about: Suggest an idea for this project
---

**Is your feature request related to a problem? Please describe**

A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

**Describe the solution you'd like**

A clear and concise description of what you want to happen.

**Describe alternatives you've considered**

A clear and concise description of any alternative solutions or features you've considered.

**Additional context**

Add any other context or screenshots about the feature request here.
12 changes: 11 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,12 @@ addons:
- sshpass
- lcov

# Install coveralls sender
before_install:
- if [[ "$TRAVIS_OS_NAME" == "linux" ]] && [[ "$TRAVIS_PULL_REQUEST" == "false" ]]; then
pip install --user cpp-coveralls
; fi

# Qt packages for OS X
install:
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
Expand Down Expand Up @@ -61,13 +67,17 @@ script:
- ./build/tests/tests

after_success:
# Upload code coverage
# Upload code coverage (codecov)
- if [[ "$TRAVIS_OS_NAME" == "linux" ]] && [[ "$TRAVIS_PULL_REQUEST" == "false" ]]; then
lcov --directory . --capture --output-file coverage.info &&
lcov --remove coverage.info '/usr/*' --output-file coverage.info &&
lcov --list coverage.info &&
bash <(curl -s https://codecov.io/bash)
; fi
# Upload code coverage (coveralls)
- if [[ "$TRAVIS_OS_NAME" == "linux" ]] && [[ "$TRAVIS_PULL_REQUEST" == "false" ]]; then
coveralls --exclude build --exclude e2e --exclude tests --exclude CrashReporter --gcov-options '\-lp'
; fi
# Generate release name
- if [[ "$TRAVIS_TAG" == "" ]]; then
export BUILD_LABEL=$TRAVIS_BRANCH
Expand Down
8 changes: 7 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ endif()
project(Grabber)
set(USE_SSL 1)

add_definitions(-DVERSION="6.0.3")
add_definitions(-DVERSION="6.0.4")
add_definitions(-DPROJECT_WEBSITE_URL="https://bionus.github.io/imgbrd-grabber/")
add_definitions(-DPROJECT_GITHUB_URL="https://github.com/Bionus/imgbrd-grabber")
add_definitions(-DSOURCE_ISSUES_URL="https://raw.githubusercontent.com/wiki/Bionus/imgbrd-grabber/SourceIssues.md")
Expand All @@ -50,6 +50,12 @@ if((DEFINED ENV{TRAVIS}) AND UNIX AND NOT APPLE AND CMAKE_COMPILER_IS_GNUCXX)
include(cmake/CodeCoverage.cmake)
setup_target_for_coverage(coverage tests coverage)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g -O0 -fprofile-arcs -ftest-coverage")
add_definitions(-DTRAVIS=1)
if("$ENV{TRAVIS_OS_NAME}" STREQUAL "osx")
add_definitions(-DTRAVIS_OS_OSX=1)
elseif("$ENV{TRAVIS_OS_NAME}" STREQUAL "linux")
add_definitions(-DTRAVIS_OS_LINUX=1)
endif()
endif()

add_subdirectory(lib)
Expand Down
9 changes: 5 additions & 4 deletions CrashReporter/crash-reporter-window.cpp
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
#include <QApplication>
#include <QDesktopServices>
#include <QUrl>
#include <QFile>
#include <QDir>
#include <QProcess>
#include <QMainWindow>
#include <QSettings>
#include <QTranslator>
#include "crash-reporter-window.h"
Expand All @@ -15,7 +16,7 @@ QString savePath(const QString &file, bool exists = false)
Q_UNUSED(exists);
return QDir::toNativeSeparators(QDir::currentPath()+"/tests/resources/"+file);
#else
QString check = exists ? file : "settings.ini";
const QString &check = exists ? file : "settings.ini";
if (QFile(QDir::toNativeSeparators(qApp->applicationDirPath()+"/"+check)).exists())
{ return QDir::toNativeSeparators(qApp->applicationDirPath()+"/"+file); }
if (QFile(QDir::toNativeSeparators(QDir::currentPath()+"/"+check)).exists())
Expand All @@ -35,8 +36,8 @@ CrashReporterWindow::CrashReporterWindow(QWidget *parent) : QMainWindow(parent),
QSettings settings(savePath("settings.ini"), QSettings::IniFormat);

// Translate UI
QString lang = settings.value("language", "English").toString();
QLocale locale = QLocale(lang);
const QString lang = settings.value("language", "English").toString();
const QLocale locale = QLocale(lang);
QLocale::setDefault(locale);
auto *translator = new QTranslator(this);
if (translator->load("crashreporter/"+lang))
Expand Down
2 changes: 1 addition & 1 deletion CrashReporter/crash-reporter-window.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ class CrashReporterWindow : public QMainWindow
Q_OBJECT

public:
explicit CrashReporterWindow(QWidget *parent = Q_NULLPTR);
explicit CrashReporterWindow(QWidget *parent = nullptr);
~CrashReporterWindow() override;

public slots:
Expand Down
40 changes: 20 additions & 20 deletions cli/src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,21 +22,21 @@ int main(int argc, char *argv[])
parser.addHelpOption();
parser.addVersionOption();

QCommandLineOption tagsOption(QStringList() << "t" << "tags", "Tags to search for.", "tags");
QCommandLineOption sourceOption(QStringList() << "s" << "sources", "Source websites.", "sources");
QCommandLineOption pageOption(QStringList() << "p" << "page", "Starting page.", "page", "1");
QCommandLineOption limitOption(QStringList() << "m" << "max", "Maximum of returned images.", "count");
QCommandLineOption perPageOption(QStringList() << "i" << "perpage", "Number of images per page.", "count", "20");
QCommandLineOption pathOption(QStringList() << "l" << "location", "Location to save the results.", "path");
QCommandLineOption filenameOption(QStringList() << "f" << "filename", "Filename to save the results.", "filename");
QCommandLineOption userOption(QStringList() << "u" << "user", "Username to connect to the source.", "user");
QCommandLineOption passwordOption(QStringList() << "w" << "password", "Password to connect to the source.", "password");
QCommandLineOption blacklistOption(QStringList() << "b" << "blacklist", "Download blacklisted images.");
QCommandLineOption postFilteringOption(QStringList() << "r" << "postfilter", "Filter results.", "filter");
QCommandLineOption noDuplicatesOption(QStringList() << "n" << "no-duplicates", "Remove duplicates from results.");
QCommandLineOption verboseOption(QStringList() << "d" << "debug", "Show debug messages.");
QCommandLineOption tagsMinOption(QStringList() << "tm" << "tags-min", "Minimum count for tags to be returned.", "count", "0");
QCommandLineOption tagsFormatOption(QStringList() << "tf" << "tags-format", "Format for returning tags.", "format", "%tag\t%count\t%type");
const QCommandLineOption tagsOption(QStringList() << "t" << "tags", "Tags to search for.", "tags");
const QCommandLineOption sourceOption(QStringList() << "s" << "sources", "Source websites.", "sources");
const QCommandLineOption pageOption(QStringList() << "p" << "page", "Starting page.", "page", "1");
const QCommandLineOption limitOption(QStringList() << "m" << "max", "Maximum of returned images.", "count");
const QCommandLineOption perPageOption(QStringList() << "i" << "perpage", "Number of images per page.", "count", "20");
const QCommandLineOption pathOption(QStringList() << "l" << "location", "Location to save the results.", "path");
const QCommandLineOption filenameOption(QStringList() << "f" << "filename", "Filename to save the results.", "filename");
const QCommandLineOption userOption(QStringList() << "u" << "user", "Username to connect to the source.", "user");
const QCommandLineOption passwordOption(QStringList() << "w" << "password", "Password to connect to the source.", "password");
const QCommandLineOption blacklistOption(QStringList() << "b" << "blacklist", "Download blacklisted images.");
const QCommandLineOption postFilteringOption(QStringList() << "r" << "postfilter", "Filter results.", "filter");
const QCommandLineOption noDuplicatesOption(QStringList() << "n" << "no-duplicates", "Remove duplicates from results.");
const QCommandLineOption verboseOption(QStringList() << "d" << "debug", "Show debug messages.");
const QCommandLineOption tagsMinOption(QStringList() << "tm" << "tags-min", "Minimum count for tags to be returned.", "count", "0");
const QCommandLineOption tagsFormatOption(QStringList() << "tf" << "tags-format", "Format for returning tags.", "format", "%tag\t%count\t%type");
parser.addOption(tagsOption);
parser.addOption(sourceOption);
parser.addOption(pageOption);
Expand All @@ -52,11 +52,11 @@ int main(int argc, char *argv[])
parser.addOption(tagsFormatOption);
parser.addOption(noDuplicatesOption);
parser.addOption(verboseOption);
QCommandLineOption returnCountOption(QStringList() << "rc" << "return-count", "Return total image count.");
QCommandLineOption returnTagsOption(QStringList() << "rt" << "return-tags", "Return tags for a search.");
QCommandLineOption returnPureTagsOption(QStringList() << "rp" << "return-pure-tags", "Return tags.");
QCommandLineOption returnImagesOption(QStringList() << "ri" << "return-images", "Return images url.");
QCommandLineOption downloadOption(QStringList() << "download", "Download found images.");
const QCommandLineOption returnCountOption(QStringList() << "rc" << "return-count", "Return total image count.");
const QCommandLineOption returnTagsOption(QStringList() << "rt" << "return-tags", "Return tags for a search.");
const QCommandLineOption returnPureTagsOption(QStringList() << "rp" << "return-pure-tags", "Return tags.");
const QCommandLineOption returnImagesOption(QStringList() << "ri" << "return-images", "Return images url.");
const QCommandLineOption downloadOption(QStringList() << "download", "Download found images.");
parser.addOption(returnCountOption);
parser.addOption(returnTagsOption);
parser.addOption(returnPureTagsOption);
Expand Down
Loading

0 comments on commit a35b805

Please sign in to comment.