diff --git a/.gitattributes b/.gitattributes index ae7015b472..546b134a0c 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,11 +1,14 @@ # Set default behaviour, in case users don't have core.autocrlf set. * text=auto -# Explicitly declare text files we want to always be normalized and converted +# Treat email fixtures as binary files so CRLF are not converted to LF. +*.eml binary + +# Explicitly declare text files we want to always be normalized and converted # to native line endings on checkout. *.yml text -# Custom for Visual Studio, very unlikely, but lets keep it +# Custom for Visual Studio, very unlikely, but lets keep it *.cs diff=csharp *.sln merge=union *.csproj merge=union diff --git a/Brewfile b/Brewfile index ba4f913899..89595137b6 100644 --- a/Brewfile +++ b/Brewfile @@ -1,11 +1,5 @@ # Install development dependencies on Mac OS X using Homebrew (http://mxcl.github.com/homebrew) -# add this repo to Homebrew's sources -tap 'homebrew/dupes' - -# install the gcc compiler required for ruby -brew 'apple-gcc42' - # you probably already have git installed; ensure that it is the latest version brew 'git' diff --git a/Gemfile b/Gemfile index cf25046564..d7ed141f27 100644 --- a/Gemfile +++ b/Gemfile @@ -2,8 +2,7 @@ source 'https://rubygems.org' # if there is a super emergency and rubygems is playing up, try #source 'http://production.cf.rubygems.org' -# does not install in linux ATM, so hack this for now -gem 'bootsnap', require: false +gem 'bootsnap', require: false, platform: :mri def rails_master? ENV["RAILS_MASTER"] == '1' @@ -36,7 +35,7 @@ gem 'redis-namespace' gem 'active_model_serializers', '~> 0.8.3' -gem 'onebox', '1.8.38' +gem 'onebox', '1.8.42' gem 'http_accept_language', '~>2.0.5', require: false @@ -49,9 +48,10 @@ gem 'message_bus' gem 'rails_multisite' -gem 'fast_xs' +gem 'fast_xs', platform: :mri -gem 'fast_xor' +# may move to xorcist post: https://github.com/fny/xorcist/issues/4 +gem 'fast_xor', platform: :mri gem 'fastimage' @@ -141,7 +141,7 @@ end # this is an optional gem, it provides a high performance replacement # to String#blank? a method that is called quite frequently in current # ActiveRecord, this may change in the future -gem 'fast_blank' +gem 'fast_blank', platform: :mri # this provides a very efficient lru cache gem 'lru_redux' @@ -155,7 +155,7 @@ gem 'htmlentities', require: false gem 'flamegraph', require: false gem 'rack-mini-profiler', require: false -gem 'unicorn', require: false +gem 'unicorn', require: false, platform: :mri gem 'puma', require: false gem 'rbtrace', require: false, platform: :mri gem 'gc_tracer', require: false, platform: :mri @@ -175,9 +175,13 @@ gem 'logster' gem 'sassc', require: false +gem 'rotp' +gem 'rqrcode' + if ENV["IMPORT"] == "1" gem 'mysql2' gem 'redcarpet' gem 'sqlite3', '~> 1.3.13' gem 'ruby-bbcode-to-md', github: 'nlalonde/ruby-bbcode-to-md' + gem 'reverse_markdown' end diff --git a/Gemfile.lock b/Gemfile.lock index 09d9ff3bb3..1b81cc2495 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -63,9 +63,9 @@ GEM coderay (>= 1.0.0) erubis (>= 2.6.6) rack (>= 0.9.0) - binding_of_caller (0.7.2) + binding_of_caller (0.8.0) debug_inspector (>= 0.0.1) - bootsnap (1.0.0) + bootsnap (1.1.8) msgpack (~> 1.0) builder (3.2.3) bullet (5.5.1) @@ -73,13 +73,14 @@ GEM uniform_notifier (~> 1.10.0) byebug (9.0.6) certified (1.0.0) + chunky_png (1.3.8) coderay (1.1.2) concurrent-ruby (1.0.5) connection_pool (2.2.1) cppjieba_rb (0.3.0) crack (0.4.3) safe_yaml (~> 1.0.0) - crass (1.0.2) + crass (1.0.3) debug_inspector (0.0.3) diff-lcs (1.3) discourse-qunit-rails (0.0.11) @@ -183,14 +184,14 @@ GEM metaclass (~> 0.0.1) mock_redis (0.17.3) moneta (1.0.0) - msgpack (1.1.0) - multi_json (1.12.1) + msgpack (1.2.4) + multi_json (1.13.1) multi_xml (0.6.0) multipart-post (2.0.0) mustache (1.0.5) nokogiri (1.8.2) mini_portile2 (~> 2.3.0) - nokogumbo (1.4.13) + nokogumbo (1.5.0) nokogiri oauth (0.5.1) oauth2 (1.3.1) @@ -199,7 +200,7 @@ GEM multi_json (~> 1.3) multi_xml (~> 0.5) rack (>= 1.2, < 3) - oj (3.1.0) + oj (3.4.0) omniauth (1.6.1) hashie (>= 3.4.6, < 3.6.0) rack (>= 1.6.2, < 3) @@ -228,8 +229,7 @@ GEM omniauth-twitter (1.3.0) omniauth-oauth (~> 1.1) rack - onebox (1.8.38) - fast_blank (>= 1.0.0) + onebox (1.8.42) htmlentities (~> 4.3) moneta (~> 1.0) multi_json (~> 1.11) @@ -298,6 +298,9 @@ GEM redis (~> 3.0, >= 3.0.4) request_store (1.3.2) rinku (2.0.2) + rotp (3.3.0) + rqrcode (0.10.1) + chunky_png (~> 1.0) rspec (3.6.0) rspec-core (~> 3.6.0) rspec-expectations (~> 3.6.0) @@ -338,10 +341,10 @@ GEM nokogiri (>= 1.6.0) ruby_dep (1.5.0) safe_yaml (1.0.4) - sanitize (4.5.0) + sanitize (4.6.0) crass (~> 1.0.2) nokogiri (>= 1.4.4) - nokogumbo (~> 1.4.1) + nokogumbo (~> 1.4) sass (3.4.24) sassc (1.11.2) bundler @@ -461,7 +464,7 @@ DEPENDENCIES omniauth-oauth2 omniauth-openid omniauth-twitter - onebox (= 1.8.38) + onebox (= 1.8.42) openid-redis-store pg (~> 0.21.0) pry-nav @@ -479,6 +482,8 @@ DEPENDENCIES redis redis-namespace rinku + rotp + rqrcode rspec rspec-html-matchers rspec-rails diff --git a/README.md b/README.md index 9a4c6f7595..1069b7ee84 100644 --- a/README.md +++ b/README.md @@ -57,7 +57,6 @@ Plus *lots* of Ruby Gems, a complete list of which is at [/master/Gemfile](https ## Contributing [](https://travis-ci.org/discourse/discourse) -[](https://codeclimate.com/github/discourse/discourse) Discourse is **100% free** and **open source**. We encourage and support an active, healthy community that accepts contributions from the public – including you! diff --git a/app/assets/javascripts/admin/components/site-setting.js.es6 b/app/assets/javascripts/admin/components/site-setting.js.es6 index 73e8160a28..98bdf950f6 100644 --- a/app/assets/javascripts/admin/components/site-setting.js.es6 +++ b/app/assets/javascripts/admin/components/site-setting.js.es6 @@ -1,96 +1,10 @@ import BufferedContent from 'discourse/mixins/buffered-content'; import SiteSetting from 'admin/models/site-setting'; -import { propertyNotEqual } from 'discourse/lib/computed'; -import computed from 'ember-addons/ember-computed-decorators'; -import { categoryLinkHTML } from 'discourse/helpers/category-link'; - -const CustomTypes = ['bool', 'enum', 'list', 'url_list', 'host_list', 'category_list', 'value_list']; - -export default Ember.Component.extend(BufferedContent, { - classNameBindings: [':row', ':setting', 'setting.overridden', 'typeClass'], - content: Ember.computed.alias('setting'), - dirty: propertyNotEqual('buffered.value', 'setting.value'), - validationMessage: null, - - @computed("setting", "buffered.value") - preview(setting, value) { - // A bit hacky, but allows us to use helpers - if (setting.get('setting') === 'category_style') { - let category = this.site.get('categories.firstObject'); - if (category) { - return categoryLinkHTML(category, { - categoryStyle: value - }); - } - } - - let preview = setting.get('preview'); - if (preview) { - return new Handlebars.SafeString("
{{error}}
+ {{error}}
{{/if}}
{{i18n "admin.customize.theme.custom_sections"}}
-{{i18n "admin.customize.theme.custom_sections"}}
+- {{i18n "admin.customize.theme.edit_css_html_help"}} -
++ {{i18n "admin.customize.theme.edit_css_html_help"}} +
{{/if}}{{#if model.remote_theme}} @@ -71,17 +71,17 @@ {{/if}} {{#d-button action="editTheme" class="btn edit"}}{{i18n 'admin.customize.theme.edit_css_html'}}{{/d-button}} {{#if model.remote_theme}} - {{/if}}
@@ -105,6 +105,15 @@ {{#d-button action="addUploadModal" icon="plus"}}{{i18n "admin.customize.theme.add"}}{{/d-button}} + {{#if hasSettings}} +{{i18n (concat "topics.bulk." title)}}
-{{tag-chooser tags=tags categoryId=categoryId}}
+{{tag-chooser filterPlaceholder=null tags=tags categoryId=categoryId}}
{{d-button action=action disabled=emptyTags label=(concat "topics.bulk." label)}} diff --git a/app/assets/javascripts/discourse/templates/components/badge-card.hbs b/app/assets/javascripts/discourse/templates/components/badge-card.hbs index 3c519d85dd..e211aaec06 100644 --- a/app/assets/javascripts/discourse/templates/components/badge-card.hbs +++ b/app/assets/javascripts/discourse/templates/components/badge-card.hbs @@ -5,13 +5,15 @@ {{d-icon "check"}} {{/if}}{{i18n 'category.tags_allowed_tags'}}
- {{tag-chooser placeholderKey="category.tags_placeholder" tags=category.allowed_tags everyTag="true" unlimitedTagCount="true"}} + {{tag-chooser + filterPlaceholder="category.tags_placeholder" + tags=category.allowed_tags + everyTag=true + unlimitedTagCount=true}}{{i18n 'category.tags_allowed_tag_groups'}}
- {{tag-group-chooser placeholderKey="category.tag_groups_placeholder" tagGroups=category.allowed_tag_groups}} + {{tag-group-chooser tagGroups=category.allowed_tag_groups}}