Merge pull request #5410 from svbergerem/configurable-source-url
Make source code url configurable Conflicts: config/diaspora.yml.example
This commit is contained in:
commit
2ab16d473c
5 changed files with 14 additions and 3 deletions
|
|
@ -116,6 +116,7 @@ This is disabled by default since it requires the installation of additional pac
|
|||
* Display diaspora handle in search results [#5419](https://github.com/diaspora/diaspora/pull/5419)
|
||||
* Show a message on the ignored users page when there are none [#5434](https://github.com/diaspora/diaspora/pull/5434)
|
||||
* Truncate too long OpenGraph descriptions [#5387](https://github.com/diaspora/diaspora/pull/5387)
|
||||
* Make the source code URL configurable [#5410](https://github.com/diaspora/diaspora/pull/5410)
|
||||
|
||||
# 0.4.1.2
|
||||
|
||||
|
|
|
|||
|
|
@ -4,11 +4,11 @@
|
|||
|
||||
module ApplicationHelper
|
||||
def pod_name
|
||||
AppConfig.settings.pod_name.present? ? AppConfig.settings.pod_name : "diaspora*"
|
||||
AppConfig.settings.pod_name
|
||||
end
|
||||
|
||||
def pod_version
|
||||
AppConfig.version.number.present? ? AppConfig.version.number : ""
|
||||
AppConfig.version.number
|
||||
end
|
||||
|
||||
def changelog_url
|
||||
|
|
@ -17,6 +17,10 @@ module ApplicationHelper
|
|||
url
|
||||
end
|
||||
|
||||
def source_url
|
||||
AppConfig.settings.source_url.presence || "#{root_path.chomp('/')}/source.tar.gz"
|
||||
end
|
||||
|
||||
def timeago(time, options={})
|
||||
timeago_tag(time, options.merge(:class => 'timeago', :title => time.iso8601, :force => true)) if time
|
||||
end
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
%li= link_to 'diasporafoundation.org', "https://diasporafoundation.org"
|
||||
%li= link_to 'wiki', "https://wiki.diasporafoundation.org"
|
||||
%li= link_to t('layouts.application.whats_new'), changelog_url
|
||||
%li= link_to(t('layouts.header.code') + " " + pod_version, "#{root_path.chomp('/')}/source.tar.gz", {:title => t('layouts.application.source_package')}) unless request.url.match(/joindiaspora.com/)
|
||||
%li= link_to t('layouts.header.code') + " " + pod_version, "#{source_url}", {:title => t('layouts.application.source_package')}
|
||||
%li= link_to(t('layouts.application.toggle'), toggle_mobile_path)
|
||||
- if AppConfig.settings.terms.enable?
|
||||
%li= link_to(t('_terms'), terms_path)
|
||||
|
|
|
|||
|
|
@ -133,6 +133,7 @@ defaults:
|
|||
after_days: 730
|
||||
warn_days: 30
|
||||
limit_removals_to_per_day: 100
|
||||
source_url:
|
||||
services:
|
||||
facebook:
|
||||
enable: false
|
||||
|
|
|
|||
|
|
@ -505,6 +505,11 @@ configuration: ## Section
|
|||
## Limit queuing for removal per day.
|
||||
#limit_removals_to_per_day: 100
|
||||
|
||||
## Source code URL
|
||||
## URL to the source code your pod is currently running.
|
||||
## If not set your pod will provide a downloadable archive.
|
||||
#source_url: 'https://example.org/username/diaspora'
|
||||
|
||||
## Posting from Diaspora to external services (all are disabled by default).
|
||||
services: ## Section
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue