From 9b4938eb452df22d8f2c9986272ad63f7edd5b53 Mon Sep 17 00:00:00 2001 From: Andrej Shadura Date: Wed, 23 Jan 2019 15:24:14 +0100 Subject: Add a git snapshot watch line --- debian/watch | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/debian/watch b/debian/watch index a38bb4f..721960a 100644 --- a/debian/watch +++ b/debian/watch @@ -1,3 +1,6 @@ -version=3 +version=4 opts=filenamemangle=s/.*\/(.*)$/sparkleshare-$1/ https://github.com/hbons/SparkleShare/releases /hbons/SparkleShare/archive/(.*).tar.gz + +opts="mode=git, pgpmode=none, pretty=3.28+git%cd, repack, compression=xz" \ +https://github.com/hbons/SparkleShare HEAD -- cgit v1.2.3 From a1033375d47a5f2ce879f0a223788b74a2b7ed64 Mon Sep 17 00:00:00 2001 From: Andrej Shadura Date: Wed, 23 Jan 2019 15:28:19 +0100 Subject: New upstream version 3.28+git20190117 --- .gitignore | 1 + README.md | 22 +++- SparkleShare/Common/AboutController.cs | 2 +- SparkleShare/Common/Images/Sources/ssnet.svg | 105 ------------------- SparkleShare/Linux/About.cs | 2 - SparkleShare/Linux/EventLog.cs | 2 - .../apps/org.sparkleshare.SparkleShare.Nightly.png | Bin 0 -> 2296 bytes .../apps/org.sparkleshare.SparkleShare.Nightly.png | Bin 0 -> 7260 bytes .../apps/org.sparkleshare.SparkleShare.Nightly.png | Bin 0 -> 24412 bytes .../apps/org.sparkleshare.SparkleShare.Nightly.png | Bin 0 -> 9028 bytes .../apps/org.sparkleshare.SparkleShare.Nightly.png | Bin 0 -> 52813 bytes SparkleShare/Linux/Images/icons/meson.build | 11 +- SparkleShare/Linux/Note.cs | 2 - SparkleShare/Linux/README.md | 10 +- SparkleShare/Linux/SetupWindow.cs | 3 - SparkleShare/Linux/SparkleShare.Autostart.desktop | 1 + SparkleShare/Linux/StatusIcon.cs | 6 +- SparkleShare/Linux/UserInterface.cs | 5 +- SparkleShare/Linux/meson.build | 12 ++- .../org.sparkleshare.SparkleShare.Nightly.desktop | 9 ++ .../org.sparkleshare.SparkleShare.appdata.xml | 18 +++- .../Linux/org.sparkleshare.SparkleShare.desktop | 1 + Sparkles/Git/Git.Repository.cs | 2 +- Sparkles/InstallationInfo.Directory.cs.in | 1 + Sparkles/Tests/Sparkles.Tests.csproj | 51 ++++++++++ Sparkles/Tests/Test.cs | 113 +++++++++++++++++++++ Sparkles/Tests/packages.config | 4 + meson_options.txt | 1 + 28 files changed, 248 insertions(+), 136 deletions(-) delete mode 100644 SparkleShare/Common/Images/Sources/ssnet.svg create mode 100644 SparkleShare/Linux/Images/icons/hicolor/16x16/apps/org.sparkleshare.SparkleShare.Nightly.png create mode 100644 SparkleShare/Linux/Images/icons/hicolor/24x24/apps/org.sparkleshare.SparkleShare.Nightly.png create mode 100644 SparkleShare/Linux/Images/icons/hicolor/256x256/apps/org.sparkleshare.SparkleShare.Nightly.png create mode 100644 SparkleShare/Linux/Images/icons/hicolor/48x48/apps/org.sparkleshare.SparkleShare.Nightly.png create mode 100644 SparkleShare/Linux/Images/icons/hicolor/512x512/apps/org.sparkleshare.SparkleShare.Nightly.png create mode 100755 SparkleShare/Linux/org.sparkleshare.SparkleShare.Nightly.desktop create mode 100644 Sparkles/Tests/Sparkles.Tests.csproj create mode 100644 Sparkles/Tests/Test.cs create mode 100644 Sparkles/Tests/packages.config diff --git a/.gitignore b/.gitignore index b8baef2..3c5d08c 100644 --- a/.gitignore +++ b/.gitignore @@ -29,6 +29,7 @@ _ReSharper.* *.wxs *.dotCover SparkleShare/Windows/build/ +.vs/ # NuGet Packages *.nupkg diff --git a/README.md b/README.md index 2bea0f9..8c0a95f 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,24 @@ SparkleShare creates a special folder on your computer. You can add remotely hosted folders (or "projects") to this folder. These projects will be automatically kept in sync with both the host and all of your peers when someone adds, removes or edits a file. +## Install on Ubuntu or Fedora + +You can install the package from your distribution (likely old and not updated often), but we recommend to get our Flatpak with automatic updates to always enjoy the latest and greatest: + +```bash +flatpak remote-add flathub https://flathub.org/repo/flathub.flatpakrepo +flatpak install flathub org.sparkleshare.SparkleShare +``` + +Now you can run SparkleShare from the apps menu. + +**Note:** by default SparkleShare uses an AppIndicator status icon on Linux. If you use GNOME on a distribution other than Ubuntu, please install the [AppIndicator extension](https://extensions.gnome.org/extension/615/appindicator-support/). If you don't use GNOME, you can start SparkleShare with `--status-icon=gtk`. + + +## Install on macOS + +Download the app from the [releases page](https://github.com/hbons/SparkleShare/releases). + ## Set up a host @@ -16,12 +34,10 @@ Under the hood SparkleShare uses the version control system [Git](https://git-sc ## Build from source -`SparkleShare` is Free and Open Source software and licensed under the [GNU GPLv3 or later](legal/License_for_SparkleShare.txt). You are welcome to change and redistribute it under certain conditions. Its library `Sparkles` is licensed under the [GNU LGPLv3 or later](legal/License_for_Sparkles.txt). +`SparkleShare` is Free and Open Source software and licensed under the [GNU GPLv3 or later](LICENSE.md). You are welcome to change and redistribute it under certain conditions. Its library `Sparkles` is licensed under the [GNU LGPLv3 or later](LICENSE_Sparkles.md). Here are instructions to build SparkleShare on [Linux distributions](SparkleShare/Linux/README.md), [macOS](SparkleShare/Mac/README.md), and [Windows](SparkleShare/Windows/README.md). -**Note:** by default SparkleShare uses an AppIndicator status icon on Linux. If you use GNOME on a distribution other than Ubuntu, please install the [AppIndicator extension](https://extensions.gnome.org/extension/615/appindicator-support/). If you don't use GNOME, you can start SparkleShare with `--status-icon=gtk`. - [![Build Status](https://travis-ci.org/hbons/SparkleShare.svg?branch=master)](https://travis-ci.org/hbons/SparkleShare) [![Join the chat at https://gitter.im/hbons/SparkleShare](https://badges.gitter.im/hbons/SparkleShare.svg)](https://gitter.im/hbons/SparkleShare?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) diff --git a/SparkleShare/Common/AboutController.cs b/SparkleShare/Common/AboutController.cs index bdf8c65..514d045 100644 --- a/SparkleShare/Common/AboutController.cs +++ b/SparkleShare/Common/AboutController.cs @@ -32,7 +32,7 @@ namespace SparkleShare { public delegate void UpdateLabelEventDelegate (string text); public readonly string WebsiteLinkAddress = "https://www.sparkleshare.org/"; - public readonly string CreditsLinkAddress = "https://github.com/hbons/SparkleShare/blob/master/legal/Authors.txt"; + public readonly string CreditsLinkAddress = "https://github.com/hbons/SparkleShare/blob/master/.github/AUTHORS.md"; public readonly string ReportProblemLinkAddress = "https://www.github.com/hbons/SparkleShare/issues"; public readonly string DebugLogLinkAddress = "file://" + SparkleShare.Controller.Config.LogFilePath; diff --git a/SparkleShare/Common/Images/Sources/ssnet.svg b/SparkleShare/Common/Images/Sources/ssnet.svg deleted file mode 100644 index 6971d98..0000000 --- a/SparkleShare/Common/Images/Sources/ssnet.svg +++ /dev/null @@ -1,105 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - image/svg+xml - - - - - - - - - - - - - - - places - sparkleshare - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/SparkleShare/Linux/About.cs b/SparkleShare/Linux/About.cs index cb4e0cd..b4df76b 100755 --- a/SparkleShare/Linux/About.cs +++ b/SparkleShare/Linux/About.cs @@ -31,8 +31,6 @@ namespace SparkleShare { public About () : base ("About SparkleShare") { - SetWmclass ("SparkleShare", "SparkleShare"); - IconName = "org.sparkleshare.SparkleShare"; Resizable = false; WindowPosition = WindowPosition.CenterAlways; diff --git a/SparkleShare/Linux/EventLog.cs b/SparkleShare/Linux/EventLog.cs index 28ee613..b6d1c53 100755 --- a/SparkleShare/Linux/EventLog.cs +++ b/SparkleShare/Linux/EventLog.cs @@ -40,8 +40,6 @@ namespace SparkleShare { public EventLog () : base ("Recent Changes") { - SetWmclass ("SparkleShare", "SparkleShare"); - TypeHint = Gdk.WindowTypeHint.Dialog; IconName = "org.sparkleshare.SparkleShare"; diff --git a/SparkleShare/Linux/Images/icons/hicolor/16x16/apps/org.sparkleshare.SparkleShare.Nightly.png b/SparkleShare/Linux/Images/icons/hicolor/16x16/apps/org.sparkleshare.SparkleShare.Nightly.png new file mode 100644 index 0000000..cd99297 Binary files /dev/null and b/SparkleShare/Linux/Images/icons/hicolor/16x16/apps/org.sparkleshare.SparkleShare.Nightly.png differ diff --git a/SparkleShare/Linux/Images/icons/hicolor/24x24/apps/org.sparkleshare.SparkleShare.Nightly.png b/SparkleShare/Linux/Images/icons/hicolor/24x24/apps/org.sparkleshare.SparkleShare.Nightly.png new file mode 100644 index 0000000..f59ae6a Binary files /dev/null and b/SparkleShare/Linux/Images/icons/hicolor/24x24/apps/org.sparkleshare.SparkleShare.Nightly.png differ diff --git a/SparkleShare/Linux/Images/icons/hicolor/256x256/apps/org.sparkleshare.SparkleShare.Nightly.png b/SparkleShare/Linux/Images/icons/hicolor/256x256/apps/org.sparkleshare.SparkleShare.Nightly.png new file mode 100644 index 0000000..e035320 Binary files /dev/null and b/SparkleShare/Linux/Images/icons/hicolor/256x256/apps/org.sparkleshare.SparkleShare.Nightly.png differ diff --git a/SparkleShare/Linux/Images/icons/hicolor/48x48/apps/org.sparkleshare.SparkleShare.Nightly.png b/SparkleShare/Linux/Images/icons/hicolor/48x48/apps/org.sparkleshare.SparkleShare.Nightly.png new file mode 100644 index 0000000..109db4d Binary files /dev/null and b/SparkleShare/Linux/Images/icons/hicolor/48x48/apps/org.sparkleshare.SparkleShare.Nightly.png differ diff --git a/SparkleShare/Linux/Images/icons/hicolor/512x512/apps/org.sparkleshare.SparkleShare.Nightly.png b/SparkleShare/Linux/Images/icons/hicolor/512x512/apps/org.sparkleshare.SparkleShare.Nightly.png new file mode 100644 index 0000000..11a9a14 Binary files /dev/null and b/SparkleShare/Linux/Images/icons/hicolor/512x512/apps/org.sparkleshare.SparkleShare.Nightly.png differ diff --git a/SparkleShare/Linux/Images/icons/meson.build b/SparkleShare/Linux/Images/icons/meson.build index 422bda5..61f4294 100644 --- a/SparkleShare/Linux/Images/icons/meson.build +++ b/SparkleShare/Linux/Images/icons/meson.build @@ -1,14 +1,21 @@ # Install app icons in system theme theme_dir = join_paths(get_option('prefix'), 'share', 'icons', 'hicolor') icon_sizes = ['16', '24', '48', '256', '512'] + app_icon_name = 'org.sparkleshare.SparkleShare' +source_icon_name = app_icon_name + +if get_option('nightly') + source_icon_name = app_icon_name + '.Nightly' +endif foreach size : icon_sizes icon_dir = join_paths(size + 'x' + size, 'apps') install_data( - sources: join_paths('hicolor', icon_dir, app_icon_name + '.png'), - install_dir: join_paths(theme_dir, icon_dir)) + sources: join_paths('hicolor', icon_dir, source_icon_name + '.png'), + install_dir: join_paths(theme_dir, icon_dir), + rename: app_icon_name + '.png') endforeach install_data( diff --git a/SparkleShare/Linux/Note.cs b/SparkleShare/Linux/Note.cs index 6fe8187..e2e998b 100644 --- a/SparkleShare/Linux/Note.cs +++ b/SparkleShare/Linux/Note.cs @@ -27,8 +27,6 @@ namespace SparkleShare { public Note () : base ("Add Note") { - SetWmclass ("SparkleShare", "SparkleShare"); - IconName = "org.sparkleshare.SparkleShare"; Resizable = false; WindowPosition = WindowPosition.CenterAlways; diff --git a/SparkleShare/Linux/README.md b/SparkleShare/Linux/README.md index 6b41075..9942afa 100644 --- a/SparkleShare/Linux/README.md +++ b/SparkleShare/Linux/README.md @@ -1,5 +1,11 @@ # SparkleShare for Linux +## Building with Flatpak + +If you want to test SparkleShare from Git, it's easiest to build a flatpak locally using [this spec]( +https://github.com/hbons/org.sparkleshare.SparkleShare/) and run it. + + ## Building on Linux ### Common build requirements @@ -56,8 +62,6 @@ sudo dnf install \ ### Additional source build requirements -Install mono-complete, [see instructions](https://www.mono-project.com/download/stable/#download-lin-ubuntu) - Install these `soup-sharp` and `webkit2gtk-sharp` bindings: ```bash @@ -99,7 +103,7 @@ sudo ninja install -C build/ ``` -If your distribution has an out of date meson package, you can install the latest version using the Python package manager: +If your distribution has an out of date `meson` package, you can install the latest version using the Python package manager: ```bash # Install pip using your system's package manager diff --git a/SparkleShare/Linux/SetupWindow.cs b/SparkleShare/Linux/SetupWindow.cs index a1465d3..4d61a2c 100644 --- a/SparkleShare/Linux/SetupWindow.cs +++ b/SparkleShare/Linux/SetupWindow.cs @@ -32,15 +32,12 @@ namespace SparkleShare { public SetupWindow () : base ("SparkleShare Setup") { - SetWmclass ("SparkleShare", "SparkleShare"); - IconName = "org.sparkleshare.SparkleShare"; Resizable = false; WindowPosition = WindowPosition.CenterAlways; Deletable = false; TypeHint = Gdk.WindowTypeHint.Dialog; - SetSizeRequest (720, 540); DeleteEvent += delegate (object sender, DeleteEventArgs args) { args.RetVal = true; }; diff --git a/SparkleShare/Linux/SparkleShare.Autostart.desktop b/SparkleShare/Linux/SparkleShare.Autostart.desktop index 29ef7e0..6130357 100755 --- a/SparkleShare/Linux/SparkleShare.Autostart.desktop +++ b/SparkleShare/Linux/SparkleShare.Autostart.desktop @@ -5,3 +5,4 @@ Exec=sh -c "type -P sparkleshare &>/dev/null && sparkleshare || flatpak run org. Icon=org.sparkleshare.SparkleShare Terminal=false X-GNOME-Autostart-enabled=true +X-AppStream-Ignore=true diff --git a/SparkleShare/Linux/StatusIcon.cs b/SparkleShare/Linux/StatusIcon.cs index b64f49e..824e081 100644 --- a/SparkleShare/Linux/StatusIcon.cs +++ b/SparkleShare/Linux/StatusIcon.cs @@ -51,13 +51,13 @@ namespace SparkleShare { if (use_appindicator) { #if HAVE_APP_INDICATOR indicator = new Indicator ("sparkleshare", "sparkleshare", (int) IndicatorCategory.ApplicationStatus) { - IconName = "org.sparkleshare.SparkleShare-symbolic", + IconName = UserInterface.APP_ID + "-symbolic", Status = (int) IndicatorStatus.Active }; #endif } else { - this.status_icon = new Gtk.StatusIcon { IconName = "org.sparkleshare.SparkleShare" }; + this.status_icon = new Gtk.StatusIcon { IconName = UserInterface.APP_ID }; this.status_icon.Activate += ShowMenu; // Primary mouse button click this.status_icon.PopupMenu += ShowMenu; // Secondary mouse button click } @@ -127,7 +127,7 @@ namespace SparkleShare { this.state_item = new MenuItem (Controller.StateText) { Sensitive = false }; ImageMenuItem folder_item = new SparkleMenuItem ("SparkleShare"); - folder_item.Image = new Image (UserInterfaceHelpers.GetIcon ("org.sparkleshare.SparkleShare", 16)); + folder_item.Image = new Image (UserInterfaceHelpers.GetIcon (UserInterface.APP_ID, 16)); folder_item.Submenu = new Menu (); this.menu.Add (this.state_item); diff --git a/SparkleShare/Linux/UserInterface.cs b/SparkleShare/Linux/UserInterface.cs index 74fd555..f05d543 100644 --- a/SparkleShare/Linux/UserInterface.cs +++ b/SparkleShare/Linux/UserInterface.cs @@ -38,6 +38,7 @@ namespace SparkleShare public string SecondaryTextColor; public string SecondaryTextColorSelected; + public static readonly string APP_ID = "org.sparkleshare.SparkleShare"; Application application; @@ -46,7 +47,7 @@ namespace SparkleShare string gtk_version = string.Format ("{0}.{1}.{2}", Global.MajorVersion, Global.MinorVersion, Global.MicroVersion); Logger.LogInfo ("Environment", "GTK+ " + gtk_version); - application = new Application ("org.sparkleshare.SparkleShare", GLib.ApplicationFlags.None); + application = new Application (APP_ID, GLib.ApplicationFlags.None); application.Activated += ApplicationActivatedDelegate; if (!application.IsRemote) @@ -82,7 +83,7 @@ namespace SparkleShare run_method.Invoke ((application as GLib.Application), new object [] { 0, null }); } else { - run_method.Invoke ((application as GLib.Application), new object [] { "org.sparkleshare.SparkleShare", new string [0] }); + run_method.Invoke ((application as GLib.Application), new object [] { APP_ID, new string [0] }); } } diff --git a/SparkleShare/Linux/meson.build b/SparkleShare/Linux/meson.build index d3e0233..c806719 100644 --- a/SparkleShare/Linux/meson.build +++ b/SparkleShare/Linux/meson.build @@ -28,10 +28,18 @@ configure_file( # .desktop and .appdata files apps_dir = join_paths(get_option('prefix'), 'share', 'applications') -install_data(sources: 'org.sparkleshare.SparkleShare.desktop', install_dir: apps_dir) install_data(sources: 'org.sparkleshare.SparkleShare.Invites.desktop', install_dir: apps_dir) install_data(sources: 'SparkleShare.Autostart.desktop', install_dir: apps_dir) -install_data(sources: 'org.sparkleshare.SparkleShare.appdata.xml', install_dir: join_paths(get_option('prefix'), 'share', 'appdata')) +install_data(sources: 'org.sparkleshare.SparkleShare.appdata.xml', install_dir: join_paths(get_option('prefix'), 'share', 'metainfo')) + +if get_option('nightly') + install_data(sources: 'org.sparkleshare.SparkleShare.Nightly.desktop', + install_dir: apps_dir, + rename: 'org.sparkleshare.SparkleShare.desktop') +else + install_data(sources: 'org.sparkleshare.SparkleShare.desktop', + install_dir: apps_dir) +endif # Build SparkleShare diff --git a/SparkleShare/Linux/org.sparkleshare.SparkleShare.Nightly.desktop b/SparkleShare/Linux/org.sparkleshare.SparkleShare.Nightly.desktop new file mode 100755 index 0000000..d1639f8 --- /dev/null +++ b/SparkleShare/Linux/org.sparkleshare.SparkleShare.Nightly.desktop @@ -0,0 +1,9 @@ +[Desktop Entry] +Type=Application +Name=SparkleShare (Nightly) +Exec=sparkleshare +Icon=org.sparkleshare.SparkleShare +Terminal=false +Categories=Network;FileTransfer;GNOME;GTK; +X-GNOME-UsesNotifications=true + diff --git a/SparkleShare/Linux/org.sparkleshare.SparkleShare.appdata.xml b/SparkleShare/Linux/org.sparkleshare.SparkleShare.appdata.xml index 2742669..74c412e 100644 --- a/SparkleShare/Linux/org.sparkleshare.SparkleShare.appdata.xml +++ b/SparkleShare/Linux/org.sparkleshare.SparkleShare.appdata.xml @@ -1,11 +1,13 @@ - + SparkleShare Magic self hosted Git file sync Hylke Bons GPL-3.0+ - http://www.sparkleshare.org/ + + https://www.sparkleshare.org/ https://www.github.com/hbons/SparkleShare/issues + https://www.patreon.com/SparkleShare

SparkleShare is a file sharing and collaboration app. It works just like Dropbox, and you can run it on your own server.

@@ -62,12 +64,18 @@ - org.sparkleshare.SparkleShare.desktop - org.sparkleshare.SparkleShare.desktop + org.sparkleshare.SparkleShare + org.sparkleshare.SparkleShare.desktop sparkleshare - CC0-1.0 + CC0-1.0 hi_AT_planetpeanut.uk + + + moderate + mild + intense +
diff --git a/SparkleShare/Linux/org.sparkleshare.SparkleShare.desktop b/SparkleShare/Linux/org.sparkleshare.SparkleShare.desktop index e458729..03daf3e 100755 --- a/SparkleShare/Linux/org.sparkleshare.SparkleShare.desktop +++ b/SparkleShare/Linux/org.sparkleshare.SparkleShare.desktop @@ -6,3 +6,4 @@ Icon=org.sparkleshare.SparkleShare Terminal=false Categories=Network;FileTransfer;GNOME;GTK; X-GNOME-UsesNotifications=true + diff --git a/Sparkles/Git/Git.Repository.cs b/Sparkles/Git/Git.Repository.cs index 2588d82..b7136fc 100644 --- a/Sparkles/Git/Git.Repository.cs +++ b/Sparkles/Git/Git.Repository.cs @@ -434,7 +434,7 @@ namespace Sparkles.Git { git = new GitCommand (LocalPath, "config core.ignorecase true"); git.StartAndWaitForExit (); - git = new GitCommand (LocalPath, "merge FETCH_HEAD"); + git = new GitCommand (LocalPath, "merge --no-edit FETCH_HEAD"); git.StartInfo.RedirectStandardOutput = false; string error_output = git.StartAndReadStandardError (); diff --git a/Sparkles/InstallationInfo.Directory.cs.in b/Sparkles/InstallationInfo.Directory.cs.in index 82a50f5..8cbf76f 100755 --- a/Sparkles/InstallationInfo.Directory.cs.in +++ b/Sparkles/InstallationInfo.Directory.cs.in @@ -27,3 +27,4 @@ namespace Sparkles { public const string Directory = "@ABS_INSTALL_DIR@"; } } + diff --git a/Sparkles/Tests/Sparkles.Tests.csproj b/Sparkles/Tests/Sparkles.Tests.csproj new file mode 100644 index 0000000..11aa209 --- /dev/null +++ b/Sparkles/Tests/Sparkles.Tests.csproj @@ -0,0 +1,51 @@ + + + + + + Debug + AnyCPU + 8.0.30703 + 2.0 + {8AB2969A-951F-4146-A0DD-C46D7526AC20} + Library + Sparkles.Tests + Sparkles.Tests + v4.6.1 + + + + true + full + false + bin\Debug + DEBUG; + prompt + 4 + + + true + bin\Release + prompt + 4 + + + + + ..\..\packages\NUnit.3.10.1\lib\net45\nunit.framework.dll + + + + + + + + + + + {2C914413-B31C-4362-93C7-1AE34F09112A} + Sparkles + + + + \ No newline at end of file diff --git a/Sparkles/Tests/Test.cs b/Sparkles/Tests/Test.cs new file mode 100644 index 0000000..3a22f7d --- /dev/null +++ b/Sparkles/Tests/Test.cs @@ -0,0 +1,113 @@ +// Copyright (C) 2018 Hylke Bons +// +// Permission is hereby granted, free of charge, to any person obtaining +// a copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to +// permit persons to whom the Software is furnished to do so, subject to +// the following conditions: +// +// The above copyright notice and this permission notice shall be +// included in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + + +using NUnit.Framework; + +using System; +using Sparkles; + +namespace Sparkles.Tests { + + [TestFixture ()] + public class TestExtensions { + + [Test ()] + public void ReturnSHA256 () + { + string result = "hello".SHA256 (); + Assert.IsTrue (result == "2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824"); + } + + + [Test ()] + public void ReturnSHA256WithSalt () + { + string salt = "salt"; + string result = "hello".SHA256 (salt); + + Assert.IsTrue (result == "87daba3fe263b34c335a0ee3b28ffec4d159aad6542502eaf551dc7b9128c267"); + } + + + [Test ()] + public void ReturnMD5 () + { + string result = "hello".MD5 (); + Assert.IsTrue (result == "5d41402abc4b2a76b9719d911017c592"); + } + + + string cipher_text; + string plain_text = "secret"; + string password = "password"; + + [Test (), Order (1)] + public void ReturnAESEncrypt () + { + string result = plain_text.AESEncrypt (password); + cipher_text = result; + + Assert.That (result, Is.Not.Null.And.Not.Empty); + } + + + [Test (), Order (2)] + public void ReturnAESDecrypt () + { + string result = cipher_text.AESDecrypt (password); + Assert.IsTrue (result == plain_text); + } + + + [Test ()] + public void ReturnReplaceUnderScoreWithSpace () + { + string result = "good_morning_to_you".ReplaceUnderscoreWithSpace (); + Assert.IsTrue (result == "good morning to you"); + } + + + [Test ()] + public void ReturnToSize () + { + Assert.IsTrue (1099511627776.0.ToSize () == "1 ᴛʙ"); + Assert.IsTrue (1073741824.0.ToSize () == "1 ɢʙ"); + Assert.IsTrue (1048576.0.ToSize () == "1 ᴍʙ"); + Assert.IsTrue (1024.0.ToSize () == "1 ᴋʙ"); + Assert.IsTrue (0.0.ToSize () == "0 ʙ"); + } + + + [Test ()] + public void ReturnToPrettyDate () + { + // TODO + } + + + [Test ()] + public void ReturnIsSymlink () + { + // TODO + } + } +} diff --git a/Sparkles/Tests/packages.config b/Sparkles/Tests/packages.config new file mode 100644 index 0000000..ebeb58f --- /dev/null +++ b/Sparkles/Tests/packages.config @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/meson_options.txt b/meson_options.txt index a00dc67..a28355c 100644 --- a/meson_options.txt +++ b/meson_options.txt @@ -1,2 +1,3 @@ option('ubuntu', type: 'boolean', value: false) +option('nightly', type: 'boolean', value: false) -- cgit v1.2.3 From 4efa6a5f4dff6fef977c7550f9f2b4a9407bb17e Mon Sep 17 00:00:00 2001 From: Andrej Shadura Date: Wed, 23 Jan 2019 15:30:12 +0100 Subject: The upstream now installs appdata files in the right place Gbp-Dch: Ignore --- debian/dirs | 1 - debian/rules | 1 - 2 files changed, 2 deletions(-) delete mode 100644 debian/dirs diff --git a/debian/dirs b/debian/dirs deleted file mode 100644 index d5c61ee..0000000 --- a/debian/dirs +++ /dev/null @@ -1 +0,0 @@ -/usr/share/metainfo/ diff --git a/debian/rules b/debian/rules index d7ebb96..6f20637 100755 --- a/debian/rules +++ b/debian/rules @@ -7,7 +7,6 @@ export CSC=/usr/bin/mono-csc override_dh_auto_install: dh_auto_install - mv debian/sparkleshare/usr/share/appdata debian/sparkleshare/usr/share/metainfo chmod -x debian/sparkleshare/usr/share/sparkleshare/html/*.html override_dh_installchangelogs: -- cgit v1.2.3 From 92c02f9e6fb2ee775ecaabaefcba5add3c7df666 Mon Sep 17 00:00:00 2001 From: Andrej Shadura Date: Wed, 23 Jan 2019 15:31:53 +0100 Subject: Update the homepage and copyrights --- debian/control | 2 +- debian/copyright | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/debian/control b/debian/control index 09bd959..601b304 100644 --- a/debian/control +++ b/debian/control @@ -12,7 +12,7 @@ Build-Depends-Indep: intltool, mono-devel (>= 3.2.8), python-nautilus Standards-Version: 3.9.6 -Homepage: http://sparkleshare.org/ +Homepage: https://sparkleshare.org/ Vcs-Git: https://salsa.debian.org/debian/sparkleshare Vcs-Browser: https://salsa.debian.org/debian/sparkleshare diff --git a/debian/copyright b/debian/copyright index 03bf2ab..55684ce 100644 --- a/debian/copyright +++ b/debian/copyright @@ -1,9 +1,9 @@ Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: sparkleshare -Source: http://sparkleshare.org/ +Source: https://sparkleshare.org/ Files: * -Copyright: 2010—2018 Hylke Bons +Copyright: 2010—2019 Hylke Bons License: GPL-3+ Files: debian/* @@ -14,7 +14,7 @@ Copyright: 2012 Chow Loong Jin 2015 Jo Shields 2017 Jeremy Bicha - 2015-2018 Andrew Shadura + 2015-2019 Andrej Shadura 2018 Maxime “pep” Buquet License: GPL-3+ -- cgit v1.2.3 From 80ec330b842f375e1d4ccc0f23f856f89b217a75 Mon Sep 17 00:00:00 2001 From: Andrej Shadura Date: Wed, 23 Jan 2019 15:33:34 +0100 Subject: Update the package description Ubuntu One is no more --- debian/control | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/debian/control b/debian/control index 601b304..14798ec 100644 --- a/debian/control +++ b/debian/control @@ -33,7 +33,7 @@ Description: distributed collaboration and sharing tool with any Git repository you have access to. . SparkleShare can be used as a rough alternative to web services such as - Dropbox or Ubuntu One. + Dropbox or Seafile. . Though SparkleShare is not made to be a graphical frontend for git or a backup tool, it may be useful for other kinds of purposes as well, like backing up -- cgit v1.2.3 From 3a42253c487c5ac141c43d5ac442d6c63a4df4eb Mon Sep 17 00:00:00 2001 From: Andrej Shadura Date: Wed, 23 Jan 2019 15:34:14 +0100 Subject: Bump Standards-Version --- debian/control | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/debian/control b/debian/control index 14798ec..56a5956 100644 --- a/debian/control +++ b/debian/control @@ -11,7 +11,7 @@ Build-Depends-Indep: intltool, libwebkit2-sharp-4.0-cil-dev, mono-devel (>= 3.2.8), python-nautilus -Standards-Version: 3.9.6 +Standards-Version: 4.3.0 Homepage: https://sparkleshare.org/ Vcs-Git: https://salsa.debian.org/debian/sparkleshare Vcs-Browser: https://salsa.debian.org/debian/sparkleshare -- cgit v1.2.3 From 8968d172a6b3a31b0ed6743c64a8fd2decc8cc45 Mon Sep 17 00:00:00 2001 From: Andrej Shadura Date: Wed, 23 Jan 2019 15:36:02 +0100 Subject: Update the changelog --- debian/changelog | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/debian/changelog b/debian/changelog index 67337ca..7471710 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,9 +1,17 @@ -sparkleshare (3.28-2) UNRELEASED; urgency=medium +sparkleshare (3.28+git20190117-1) unstable; urgency=medium - * d/copyright: Change Format URL to correct one - * d/changelog: Remove trailing whitespaces + [ Ondřej Nový ] + * d/copyright: Change Format URL to correct one. + * d/changelog: Remove trailing whitespaces. - -- Ondřej Nový Mon, 01 Oct 2018 09:55:47 +0200 + [ Andrej Shadura ] + * New upstream snapshot 3.28+git20190117. + * Add a git snapshot watch line. + * Update the homepage and copyrights. + * Update the package description. + * Bump Standards-Version, no changes. + + -- Andrej Shadura Wed, 23 Jan 2019 15:35:21 +0100 sparkleshare (3.28-1) unstable; urgency=medium -- cgit v1.2.3 From 7d9e48aed2d8079bda2958a84a2fe165e7388300 Mon Sep 17 00:00:00 2001 From: Andrej Shadura Date: Wed, 23 Jan 2019 16:41:47 +0100 Subject: Add a CC0-licensed file --- debian/copyright | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/debian/copyright b/debian/copyright index 55684ce..73bfc42 100644 --- a/debian/copyright +++ b/debian/copyright @@ -26,6 +26,12 @@ Files: Sparkles/* Copyright: 2010—2018 Hylke Bons License: LGPL-3+ +Files: SparkleShare/Linux/org.sparkleshare.SparkleShare.appdata.xml +Copyright: 2010—2018 Hylke Bons +License: CC0-1.0 + On Debian systems, the complete text of the Creative Commons CC0 1.0 + Universal license can be found in "/usr/share/common-licenses/CC0-1.0". + Files: debian/missing-sources/jquery-1.6.1.js SparkleShare/Common/HTML/jquery.js -- cgit v1.2.3