From 0616db3d839a97221179caeff37d358b6288ad3a Mon Sep 17 00:00:00 2001 From: Fabian Wilkens Date: Thu, 8 Jul 2021 21:31:44 +0200 Subject: [PATCH] Remove unnecessary files --- sources/extra_files/app/.gitignore | 2 - .../app/views/user_mailer/welcome.html.erb | 223 ------------------ sources/patches/app-00-add-path-url.patch | 12 - sources/patches/app-01-add-mail.patch | 49 ---- 4 files changed, 286 deletions(-) delete mode 100644 sources/extra_files/app/.gitignore delete mode 100644 sources/extra_files/app/app/views/user_mailer/welcome.html.erb delete mode 100644 sources/patches/app-00-add-path-url.patch delete mode 100644 sources/patches/app-01-add-mail.patch diff --git a/sources/extra_files/app/.gitignore b/sources/extra_files/app/.gitignore deleted file mode 100644 index 783a4ae..0000000 --- a/sources/extra_files/app/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -*~ -*.sw[op] diff --git a/sources/extra_files/app/app/views/user_mailer/welcome.html.erb b/sources/extra_files/app/app/views/user_mailer/welcome.html.erb deleted file mode 100644 index 785204e..0000000 --- a/sources/extra_files/app/app/views/user_mailer/welcome.html.erb +++ /dev/null @@ -1,223 +0,0 @@ - - - - - - - -
-
-
-
-
-
- Welcome to - Standard Notes. -
-
-
- Registered as <%= @email %> -
-
-
-

- Hi there, -

-

- Welcome to your new private notes account. - We created Standard Notes to be a safe, private, and lasting place for your most important work. -

-

- You should know: -

-
    -
  1. - Your notes are fully encrypted on your device before they're ever sent to our servers. - This means even we can't read the contents of your notes. -
  2. -
  3. - Standard Notes is available on all your devices. Download the - iOS - and - Android - app to go mobile. Use the - web app on the go. Or download the desktop app on - Mac, Windows, and Linux. -
  4. -
-

- Install instructions for Extensions: -

-
    -
  1. - Open the Standard Notes web or Desktop app -
  2. -
  3. - Press Extensions in the button left corner -
  4. -
  5. - Press on Import Extensions in the button right corner of the new window. -
  6. -
  7. - Enter https://__DOMAIN____PATH__/extensions/repo.json in the field. -
  8. -
  9. - Press Enter on your keyboard. -
  10. -
  11. - Now you can see Editors, Themes and Components which you can install -
  12. -
-

To have all Standard Notes extensions use Standard Notes Extened:

-
-
-
-

Standard Notes Extended

-

- Unlock entirely new workflows with powerful editors and cloud backup options - with - Extended. - Extended is our paid extensions program, and how we support continued development on Standard Notes. -

-

- Benefits: -

-
    -
  • -

    Encrypted attachments for your notes stored directly in your Dropbox, Google Drive, or WebDAV.

    -
  • -
  • -

    Unlimited access to powerful extensions, editors, and beautiful themes.

    -
  • -
  • -

    Note version history (up to 100 years)

    -
  • -
  • -

    Automatic daily backups of your data to your email inbox, Dropbox, OneDrive, and Google Drive

    -
  • -
  • -

    Two-factor authentication

    -
  • -
  • -

    Support our mission for privacy and longevity in software

    -
  • -
- -

As low as

-

$2.48/month

-
- -
Learn More
-
-
-
-
-
-
-
- - diff --git a/sources/patches/app-00-add-path-url.patch b/sources/patches/app-00-add-path-url.patch deleted file mode 100644 index 73f971a..0000000 --- a/sources/patches/app-00-add-path-url.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff --git a/config.ru b/config.ru -index bd83b25..6b1bb50 100644 ---- a/config.ru -+++ b/config.ru -@@ -1,4 +1,6 @@ - # This file is used by Rack-based servers to start the application. - - require ::File.expand_path('../config/environment', __FILE__) --run Rails.application -+map ENV['RAILS_RELATIVE_URL_ROOT'] || '/' do -+ run Rails.application -+end diff --git a/sources/patches/app-01-add-mail.patch b/sources/patches/app-01-add-mail.patch deleted file mode 100644 index b708039..0000000 --- a/sources/patches/app-01-add-mail.patch +++ /dev/null @@ -1,49 +0,0 @@ -diff --git a/app/mailers/application_mailer.rb b/app/mailers/application_mailer.rb -index a813bad..b7f2e2f 100644 ---- a/app/mailers/application_mailer.rb -+++ b/app/mailers/application_mailer.rb -@@ -1,4 +1,4 @@ - class ApplicationMailer < ActionMailer::Base -- default from: 'Standard Notes ' -+ default from: 'Standard Notes <__MAIL__>' - layout 'mailer' - end -diff --git a/app/mailers/user_mailer.rb b/app/mailers/user_mailer.rb -index 6bbbb11..ac7f55e 100644 ---- a/app/mailers/user_mailer.rb -+++ b/app/mailers/user_mailer.rb -@@ -25,4 +25,9 @@ class UserMailer < ApplicationMailer - user = User.find(user_id) - mail(to: user.email, subject: 'Two-factor authentication has been disabled for your account.') - end -+ -+ def welcome(user) -+ @email = user.email -+ mail(to: @email, subject: 'Welcome to your private notes account') -+ end - end -diff --git a/config/application.rb b/config/application.rb -index 3c749e2..feff27c 100644 ---- a/config/application.rb -+++ b/config/application.rb -@@ -79,7 +79,7 @@ module SyncingServer - :user_name => ENV['SMTP_USERNAME'], - :password => ENV['SMTP_PASSWORD'], - :authentication => 'login', -- :enable_starttls_auto => true # detects and uses STARTTLS -+ :enable_starttls_auto => ENV['SMTP_STARTTLS'].present? # detects and uses STARTTLS - } - - # Custom configuration -diff --git a/lib/sync_engine/abstract/user_manager.rb b/lib/sync_engine/abstract/user_manager.rb -index 26a549a..af92835 100644 ---- a/lib/sync_engine/abstract/user_manager.rb -+++ b/lib/sync_engine/abstract/user_manager.rb -@@ -29,6 +29,7 @@ module SyncEngine - else - user = @user_class.new(email: email, encrypted_password: hash_password(password)) - user.update!(registration_params(params)) -+ UserMailer.welcome(user).deliver_later - return success_auth_response(user, params) - end - end