Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/kptsky_testing'
Browse files Browse the repository at this point in the history
  • Loading branch information
kapitainsky committed Feb 17, 2020
2 parents 79f0c1c + da000aa commit a0b66c6
Show file tree
Hide file tree
Showing 21 changed files with 1,143 additions and 407 deletions.
14 changes: 14 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,17 @@
# Change Log
## [1.8.0][1.8.0] - 2020-02-17
- NEW: http(s) proxy configuration for rclone
- NEW: remotes icons size option selector
- NEW: directories tree display for remotes
- NEW: rclone extra default options for all operations (e.g. --fast-list)
- NEW: added "Public Link" button to remote view
- FIXED: option to show hidden files and folders was not always working as expected
- FIXED: for sftp server default to home user directory (as normal sftp would do)
- FIXED: an issue when on Windows local remote only allowed to browse drive C:
- FIXED: problem using rclone and rclone.conf when path contained spaces
- FIXED: bandwidth box on jobs tab is too small for fast connections
- bunch of usual small tweaks and fixes

## [1.7.0][1.7.0] - 2019-11-27
- NEW: built all releases with the latest Qt 5.13.2
- NEW: changed Linux releases format to AppImage only
Expand Down Expand Up @@ -112,6 +125,7 @@
- Mount and unmount folders on macOS and GNU/Linux
- Optionally minimizes to tray, with notifications when upload/download finishes

[1.8.0]: https://github.com/kapitainsky/RcloneBrowser/releases/tag/1.8.0
[1.7.0]: https://github.com/kapitainsky/RcloneBrowser/releases/tag/1.7.0
[1.6.0]: https://github.com/kapitainsky/RcloneBrowser/releases/tag/1.6.0
[1.5.3]: https://github.com/kapitainsky/RcloneBrowser/releases/tag/1.5.3
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.7.0
1.8.0
11 changes: 6 additions & 5 deletions assets/rclone-browser.appdata.xml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<!-- Copyright 2019 Dariusz Bogdanski <[email protected]> -->
<component type="desktop-application">
<id>org.kapitainsky.rclone-browser</id>
<metadata_license>Unlicense</metadata_license>
<project_license>Unlicense</project_license>
<id>org.kapitainsky.rclone_browser</id>
<metadata_license>MIT</metadata_license>
<project_license>MIT</project_license>
<name>Rclone Browser</name>
<summary>Simple cross platfrom GUI for rclone command line.</summary>
<summary>Simple cross platfrom GUI for rclone command line</summary>
<description>
<p>Rclone Browser is a cross-platform Qt5 GUI for Rclone, a command line tool to synchronize (and mount) files from remote cloud storage services like Google Drive, OneDrive, Nextcloud, Dropbox, Amazon Drive and S3, Mega, and others. Use it to copy a file from one cloud storage service to another, from a cloud storage to your system or the other way around, and to mount some cloud storage on your system with a single click.</p>
<p> - Allows to browse and modify any rclone remote, including encrypted ones</p>
Expand All @@ -25,7 +25,8 @@
<p> - Supports portable mode (create .ini file next to executable with same name), rclone and .rclone.conf path now can be relative to executable</p>
<p> - Supports drive-shared-with-me (Google Drive specific)</p>
<p> - For remotes supporting public link sharing has an option (right-click menu) to fetch it</p>
<p> - Supports tasks. Created jobs can be saved and run or edited later.</p>
<p> - Supports tasks. Created jobs can be saved and run or edited later</p>
<p> - Configurable dark mode for all systems</p>
</description>
<screenshots>
<screenshot type="default">
Expand Down
59 changes: 42 additions & 17 deletions scripts/release_AppImage.sh
Original file line number Diff line number Diff line change
@@ -1,27 +1,53 @@
#!/bin/bash

if [ "$1" = "SIGN" ]; then
export SIGN="1"
fi

# x86_64 build on CentOS 7.7
# gcc 7 installed
# sudo yum install -y centos-release-scl
# sudo yum install -y devtoolset-7-gcc*
# run below command before build
# scl enable devtoolset-7 bash

# newer cmake is required than one included in CentOS 7
# download from http://www.cmake.org/download
# sudo mkdir /opt/cmake
# sudo sh cmake-$version.$build-Linux-x86_64.sh --prefix=/opt/cmake

if [ $(arch) = "x86_64" ]; then
CMAKE="/opt/cmake/bin/cmake"
fi

# i686 build on Ubuntu 16.04 LTS
# armv7l build on raspbian stretch

# Qt path and flags set in env
# export PATH="/opt/Qt/5.13.2/bin/:$PATH"
# export CPPFLAGS="-I/opt/Qt/5.13.2/bin/include/"
# export LDFLAGS="-L/opt/Qt/5.13.2/bin/lib/"
# export LD_LIBRARY_PATH="/opt/Qt/5.13.2/bin/lib/:$LD_LIBRARY_PATH"
# armv7l build on raspbian stretch

# Qt path and flags set in env e.g.:
# export PATH="/opt/Qt/5.14.0/bin/:$PATH"
# export CPPFLAGS="-I/opt/Qt/5.14.0/bin/include/"
# export LDFLAGS="-L/opt/Qt/5.14.0/bin/lib/"
# export LD_LIBRARY_PATH="/opt/Qt/5.14.0/bin/lib/:$LD_LIBRARY_PATH"

# for x86 platform
# Qt 5.13.2 uses openssl 1.1 and some older distros still use 1.0
# for x86_64 and i686 platform
# Qt 5.14.0 uses openssl 1.1 and some older distros still use 1.0
# we build openssl 1.1.1d from source using following setup:
# ./config shared --prefix=/opt/openssl-1.1.1/ && make --jobs=`nproc --all` && sudo make install
# and add to build env
# export LD_LIBRARY_PATH="/opt/openssl-1.1.1/lib/:$LD_LIBRARY_PATH"

if [ "$1" = "SIGN" ]; then
export SIGN="1"
fi

# check gcc version on Centos
if [ $(arch) = "x86_64" ]; then
currentver="$(gcc -dumpversion)"
if [ "${currentver:0:1}" -lt "7" ]; then
echo "gcc version 7 or newer required"
echo "on Cetos 7 run"
echo "scl enable devtoolset-7 bash"
exit
fi
fi

# building AppImage in temporary directory to keep system clean
# use RAM disk if possible (as in: not building on CI system like Travis, and RAM disk is available)
if [ "$CI" == "" ] && [ -d /dev/shm ]; then
Expand Down Expand Up @@ -55,15 +81,15 @@ mkdir -p "$ROOT"/release

# clean current version previous build
if [ $(arch) = "armv7l" ] && [ -f "$ROOT"/release/rclone-browser-"$VERSION"-armhf.AppImage ]; then
rm "$ROOT"/release/rclone-browser-"$VERSION"-linux-armhf.AppImage
rm "$ROOT"/release/rclone-browser-"$VERSION"-armhf.AppImage
fi

if [ $(arch) = "i686" ] && [ -f "$ROOT"/release/rclone-browser-"$VERSION"-i386.AppImage ]; then
rm "$ROOT"/release/rclone-browser-"$VERSION"-linux-i386.AppImage
rm "$ROOT"/release/rclone-browser-"$VERSION"-i386.AppImage
fi

if [ $(arch) = "x86_64" ] && [ -f "$ROOT"/release/rclone-browser-"$VERSION"-x86_64.AppImage ]; then
rm "$ROOT"/release/rclone-browser-"$VERSION"-linux-amd64.AppImage
rm "$ROOT"/release/rclone-browser-"$VERSION"-x86_64.AppImage
fi

# build and install to temporary AppDir folder
Expand All @@ -76,7 +102,7 @@ if [ $(arch) = "armv7l" ]; then
fi

if [ $(arch) = "x86_64" ]; then
/opt/cmake/cmake-3.15.5-Linux-x86_64/bin/cmake .. -DCMAKE_INSTALL_PREFIX=/usr
"$CMAKE" .. -DCMAKE_INSTALL_PREFIX=/usr
make --jobs=$(nproc --all)
fi

Expand Down Expand Up @@ -114,7 +140,6 @@ fi
# https://github.com/linuxdeploy/linuxdeploy-plugin-appimage
linuxdeploy-plugin-appimage --appdir=AppDir


# raspberry pi build
if [ $(arch) = "armv7l" ]; then
rename 's/Rclone_Browser/rclone-browser/' Rclone_Browser*
Expand Down
5 changes: 3 additions & 2 deletions src/item_model.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -529,13 +529,14 @@ void ItemModel::load(const QPersistentModelIndex &parentIndex, Item *parent) {

lsd->start(GetRclone(),
QStringList() << "lsd" << GetRcloneConf() << GetDriveSharedWithMe()
<< GetShowHidden()
<< GetShowHidden() << GetDefaultRcloneOptionsList()
<< mRemote + ":" + parent->path.path(),
QIODevice::ReadOnly);
lsl->start(GetRclone(),
QStringList() << "lsl" << GetRcloneConf() << GetDriveSharedWithMe()
<< GetShowHidden() << "--max-depth"
<< "1" << mRemote + ":" + parent->path.path(),
<< "1" << GetDefaultRcloneOptionsList()
<< mRemote + ":" + parent->path.path(),
QIODevice::ReadOnly);
}

Expand Down
6 changes: 6 additions & 0 deletions src/job_options.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#include "job_options.h"
#include "utils.h"
#include <qexception.h>
#include <qlogging.h>
#ifdef _WIN32
Expand Down Expand Up @@ -148,6 +149,11 @@ QStringList JobOptions::getOptions() const {
list << "--stats-file-name-length"
<< "0";

QStringList defaultRcloneOptionsList = GetDefaultRcloneOptionsList();
if (!defaultRcloneOptionsList.isEmpty()) {
list << defaultRcloneOptionsList;
}

list << source;
list << dest;

Expand Down
38 changes: 37 additions & 1 deletion src/job_widget.ui
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<rect>
<x>0</x>
<y>0</y>
<width>896</width>
<width>966</width>
<height>449</height>
</rect>
</property>
Expand Down Expand Up @@ -117,6 +117,12 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>140</width>
<height>0</height>
</size>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
Expand All @@ -143,6 +149,12 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>140</width>
<height>0</height>
</size>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
Expand All @@ -169,6 +181,12 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>140</width>
<height>0</height>
</size>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
Expand Down Expand Up @@ -227,6 +245,12 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>140</width>
<height>0</height>
</size>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
Expand Down Expand Up @@ -322,6 +346,12 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>140</width>
<height>0</height>
</size>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
Expand Down Expand Up @@ -370,6 +400,12 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>140</width>
<height>0</height>
</size>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
Expand Down
35 changes: 33 additions & 2 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,34 @@ int main(int argc, char *argv[]) {
QDir::setCurrent(currentDir);
#endif

// remmber darkMode state on app startup

auto settings = GetSettings();

// initialize proxy settings
if (!(settings->contains("Settings/useProxy"))) {
settings->setValue("Settings/useProxy", "false");
};
if (!(settings->contains("Settings/http_proxy"))) {
settings->setValue("Settings/http_proxy", "");
};
if (!(settings->contains("Settings/https_proxy"))) {
settings->setValue("Settings/https_proxy", "");
};
if (!(settings->contains("Settings/no_proxy"))) {
settings->setValue("Settings/no_proxy", "");
};

if (settings->value("Settings/useProxy").toBool()) {
qputenv("HTTP_PROXY", settings->value("Settings/http_proxy").toByteArray());
qputenv("http_proxy", settings->value("Settings/http_proxy").toByteArray());
qputenv("HTTPS_PROXY",
settings->value("Settings/https_proxy").toByteArray());
qputenv("https_proxy",
settings->value("Settings/https_proxy").toByteArray());
qputenv("NO_PROXY", settings->value("Settings/no_proxy").toByteArray());
qputenv("no_proxy", settings->value("Settings/no_proxy").toByteArray());
}

// remmber darkMode state on app startup
// during first run the darkModeIni key might not exist
if (!(settings->contains("Settings/darkModeIni"))) {
// if darkModeIni does not exist create new key
Expand All @@ -48,6 +73,12 @@ int main(int argc, char *argv[]) {

settings->setValue("Settings/darkModeIni", darkMode);

// during first run the iconSize key might not exist
if (!(settings->contains("Settings/iconSize"))) {
// if iconSize does not exist create new key
settings->setValue("Settings/iconSize", "medium");
};

// enforce one instance of Rclone Browser per user
QString tmpDir;
QString applicationNameBase;
Expand Down
Loading

0 comments on commit a0b66c6

Please sign in to comment.