<% if object.present? && object.asset.present? %>
  <% max_img_size = object.max_image_size %>

  <% if object.url.present? %>
    <%= link_to object.url, target: object.target do %>
      <% if object.disallow_resize? %>
        <%= image_tag object.asset.image.url, alt: '', class: 'img-fluid' %>
      <% else %>
        <%= image_tag object.asset.image.url(max_img_size, max_img_size, quality: 65), alt: '', class: 'img-fluid' %>
      <% end %>
    <% end %>

  <% else %>
    <% if object.disallow_resize? %>
      <%= image_tag object.asset.image.url, alt: '', class: 'img-fluid' %>
    <% else %>
      <%= image_tag object.asset.image.url(max_img_size, max_img_size, quality: 65), alt: '', class: 'img-fluid' %>
    <% end %>
  <% end %>

  <% if object.caption.present? %>
    <% if Udongo.config.flexible_content.picture_caption_editor? %>

        <%= object.caption.html_safe %>

    <% else %>

        <%= object.caption %>

    <% end %>
  <% end %>
<% end %>

<% if object.present? && object.asset.present? %>
  <% max_img_size = object.max_image_size %>

  <% if object.background_image? %>
    <div style="background-image: url('<%= object.asset.image.url(max_img_size, max_img_size, quality: 65) %>'); height: 100%; min-height: <%= object.min_height %>px">

  <% else %>
    <% if object.disallow_resize? %>
      <% img_path = object.asset.image.url %>
    <% else %>
      <% img_path = object.asset.image.url(max_img_size, max_img_size, quality: 65) %>
    <% end %>

    <% if object.url.present? %>
      <%= link_to object.url, target: object.target do %>
        <%= image_tag img_path, alt: '', class: 'img-fluid' %>
      <% end %>

    <% else %>
      <%= image_tag img_path, alt: '', class: 'img-fluid' %>
    <% end %>

    <% if object.caption.present? %>
      <% if Udongo.config.flexible_content.picture_caption_editor? %>

          <%= object.caption.html_safe %>

      <% else %>

          <%= object.caption %>

      <% end %>
    <% end %>
  <% end %>
<% end %>

Rework the flexible content frontend picture rendering.


<%- id = "koi-#{ new_uuid }" -%>

<% if object.respond_to?("#{object.key.singularize}_list".to_sym) %>
  <%= f.input "#{object.key.singularize}_list".to_sym, as: :string, input_html: { id: id, style: 'width:500px' }, label: label %>

  <%= render "koi/admin_crud/form_field_collection_errors", f: f, attr: attr %>

  <script type='text/javascript'>
    $("#<%= id %>").select2({
      tags: <%= raw Setting.tag_counts_on(object.key.to_s.chomp('_list')).collect { |t| t.name } %>,
      tokenSeparators: [","]
    });
  </script>
<% else %>
  <%= f.input attr, as: :string, label: label %>
<% end %>

<%- id = "koi-#{ new_uuid }" -%>

<% if object.respond_to?("#{object.key.singularize}_list".to_sym) %>
  <%= f.input "#{object.key.singularize}_list".to_sym, as: :string, input_html: { id: id, style: 'width:500px' }, label: label %>

  <%= render "koi/admin_crud/form_field_collection_errors", f: f, attr: attr %>

  <%
  tag_list = Setting.tag_counts_on(object.key.to_s.chomp('_list')).collect { |t| t.name }
  tag_list = tag_list | object.data_source.call if object.data_source
  %>

  <script type='text/javascript'>
    $("#<%= id %>").select2({
      tags: <%= raw tag_list %>,
      tokenSeparators: [","]
    });
  </script>
<% else %>
  <%= f.input attr, as: :string, label: label %>
<% end %>

Append any data_source tags to the existing tag list for extensibility.


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
  <title>Tolk</title>
  <%= javascript_include_tag :all %>
  <%= stylesheet_link_tag "/tolk/reset", "/tolk/screen" %>
  <%= yield :head %>

<%= link_to "Tolk", tolk_root_path %><%= yield :locale %>

    <%= yield %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
  <title>Tolk</title>

  <% if respond_to?(:sprockets_include_tag) %>
    <%= sprockets_include_tag %>
  <% else %>
    <%= javascript_include_tag :defaults %>
  <% end %>

  <%= stylesheet_link_tag "/tolk/reset", "/tolk/screen" %>
  <%= yield :head %>

<%= link_to "Tolk", tolk_root_path %><%= yield :locale %>

    <%= yield %>

Use sprokets.js if present, else use the default javascripts


<%
  requestor = @requestor.name(false)
  recipient_name = @user.name(false)
  plan_name = @plan.title
  tool_name = Rails.configuration.branding[:application][:name]
%>

<%= _('Hello %{recipient_name}') % { recipient_name: recipient_name } %>

<%= _('%{commenter} has finished providing feedback on the plan "%{plan_title}". To view the comments, please visit the My Dashboard page in %{tool_name} and open your plan.') % { commenter: requestor, plan_title: plan_name, tool_name: tool_name } %>

<%= render partial: 'email_signature' %>

<%
  requestor = @requestor.name(false)
  recipient_name = @user.name(false)
  plan_name = @plan.title
  tool_name = Rails.configuration.branding[:application][:name]
%>

<%= _('Hello %{recipient_name}') % { recipient_name: recipient_name } %>

  <%= _("%{commenter} has finished providing feedback on the plan \"%{link_html}\". To view the comments, please visit the My Dashboard page in %{tool_name} and open your plan. Plan comments can be found adjacent to your answers in the tabbed panel next to guidance.").html_safe % {
    commenter: requestor,
    link_html: link_to(plan_name, plan_url(@plan)),
    tool_name: tool_name
  }%>

<%= render partial: 'email_signature' %>

Add comments text to feedback completed email

Issue 1492


<%= error_messages_for :user %>

  Fill out the form below with your details so we can get you started.

<% form_for :user, :url => users_path do |f| -%>

    <%= f.label :login %>
    <%= f.text_field :login %>

    <%= f.label :email %>
    <%= f.text_field :email %>

    <%= f.label :password %>
    <%= f.password_field :password %>

    <%= f.label :password_confirmation %>
    <%= f.password_field :password_confirmation %>

  <% if just_installed? %>
    <% Refinery::Plugins.registered.titles.each do |plugin| %>
      <%= hidden_field_tag 'user[plugins][]', plugin, :id => "plugins_#{plugin.downcase.gsub(" ", "_")}"  %>
    <% end %>
  <% end %>

<%= submit_tag 'Sign up' %>

<% end -%>

<%= error_messages_for :user %>

  Fill out the form below with your details so we can get you started.

<% form_for :user, :url => users_path do |f| -%>

    <%= f.label :login %>
    <%= f.text_field :login %>

    <%= f.label :email %>
    <%= f.text_field :email %>

    <%= f.label :password %>
    <%= f.password_field :password %>

    <%= f.label :password_confirmation %>
    <%= f.password_field :password_confirmation %>

  <% if just_installed? %>
    <% @available_plugins = Refinery::Plugins.registered.in_menu.titles.sort.each do |plugin| -%>
      <%= hidden_field_tag 'user[plugins][]', plugin, :id => "plugins_#{plugin.downcase.gsub(" ", "_")}" %>
    <% end -%>
  <% end -%>

<%= submit_tag 'Sign up' %>

<% end -%>

Improve positioning of plugins on initial user create


<IfModule mpm_worker_module>
  StartServers        <%= @startservers %>
  MaxClients          <%= @maxclients %>
  MinSpareThreads     <%= @minsparethreads %>
  MaxSpareThreads     <%= @maxsparethreads %>
  ThreadsPerChild     <%= @threadsperchild %>
  MaxRequestsPerChild <%= @maxrequestsperchild %>
  ServerLimit         <%= @serverlimit %>
</IfModule>

<IfModule mpm_worker_module>
  ServerLimit         <%= @serverlimit %>
  StartServers        <%= @startservers %>
  MaxClients          <%= @maxclients %>
  MinSpareThreads     <%= @minsparethreads %>
  MaxSpareThreads     <%= @maxsparethreads %>
  ThreadsPerChild     <%= @threadsperchild %>
  MaxRequestsPerChild <%= @maxrequestsperchild %>
</IfModule>

Move mpm_worker 'ServerLimit' line in ERB

It turns out that the order of MPM directives is important in certain
cases. Without this commit, the 'ServerLimit' directive was being
processed too late to be used in calculations for 'ThreadsPerChild'.

This commit moves the 'ServerLimit' directive to the top of the
directives in the ERB. This was based on Apache documentation and an
example config of theirs.


<%= link_to revision.title, revision.full_url %>

      <time datetime="<%= revision.published_at %>">
        <%= I18n.localize(revision.published_at.to_date, :format => :long) %>
      </time>

      <%= revision.user.name %>

      <a href="<%= revision.full_url + "#disqus_thread" %>">

Add the div with class posted to be compatible with older layoyt


Listing <%= plural_table_name %>

  <% attributes.each do |attribute| -%>
      <%= attribute.human_name %>
  <% end -%>

    <%%= content_tag_for(:tr, @<%= plural_table_name %>) do |<%= singular_table_name %>| %>
  <% attributes.each do |attribute| -%>
      <%%= <%= singular_table_name %>.<%= attribute.name %> %>
  <% end -%>
      <%%= link_to_show <%= singular_table_name %>, i18n: true %>
      <%%= link_to_edit <%= singular_table_name %> %>
      <%%= link_to_destroy <%= singular_table_name %> %>
    <%% end %>

<%%= link_to_new <%= singular_table_name %> %>

Listing <%= plural_table_name %>

  <% attributes.each do |attribute| -%>
      <%= attribute.human_name %>
  <% end -%>

    <%%= content_tag_for(:tr, @<%= plural_table_name %>) do |<%= singular_table_name %>| %>
  <% attributes.each do |attribute| -%>
    <% if attribute.name == 'name' %>
      <%%= link_to_show <%= singular_table_name %> %>
    <% else %>
      <%%= <%= singular_table_name %>.<%= attribute.name %> %>
    <% end %>
  <% end -%>
      <%%= link_to_show <%= singular_table_name %>, i18n: true %>
      <%%= link_to_edit <%= singular_table_name %> %>
      <%%= link_to_destroy <%= singular_table_name %> %>
    <%% end %>

<%%= link_to_new <%= singular_table_name %> %>

Use link_to_show if attribute is 'name'.


 Update Reach

    <form action="/reaches/<%= @reach.id %>" method="POST">
      <input type="hidden" name="_method" value="PUT">
      Contact name: <input type="text" name="reach[contact_name]" value="<%=@reach.contact_name %>">

      Contact phone: <input type="text" name="reach[contact_phone]" value="<%=@reach.contact_phone %>">

      Text:

      <textarea name="reach[text]" rows="5"><%= @reach.text %></textarea>

      Label: <input type="text" name="reach[label]" value="<%=@reach.label %>">

      <input type="checkbox" name="reach[main_reach]" <% if @reach.main_reach %>checked<% end %>>Set as primary Reach

      <input type="submit" value="Update" class="btn btn-success">

    </form>

    <form action="/reaches/<%= @reach.id %>" method="POST">
      <input type="hidden" name="_method" value="DELETE">
      <input type="submit" value="Delete"  class="btn btn-danger">
    </form>

 Update Reach

    <form action="/reaches/<%= @reach.id %>" method="POST">
      <input type="hidden" name="_method" value="PUT">
      Contact name: <input type="text" name="reach[contact_name]" value="<%=@reach.contact_name %>">

      Contact phone: <input type="text" name="reach[contact_phone]" value="<%=@reach.contact_phone %>">

      Text:

      <textarea name="reach[text]" rows="5"><%= @reach.text %></textarea>

      Label: <input type="text" name="reach[label]" value="<%=@reach.label %>">

        <% if @reach.main_reach %>
          <input type="checkbox" name="reach[main_reach]" checked>
        <% else %>
          <input type="checkbox" name="reach[main_reach]">
        <% end %>
      Set as main Reach

      <input type="submit" value="Update" class="btn btn-success">

    </form>

    <form action="/reaches/<%= @reach.id %>" method="POST">
      <input type="hidden" name="_method" value="DELETE">
      <input type="submit" value="Delete"  class="btn btn-danger">
    </form>

Fix check box for main reach

Fix check box for main reach


#!/bin/sh
# simple curl to cpi-core, set content types, timeout is 1800 s i.e 30 mins
curl -X POST -H "Content-Type: application/json" -H "Accept: application/json" -m 1800 http://<%= p('cpi.host') %>:<%= p('cpi.port') %>/cpi -d @-

#!/bin/sh
# simple curl to cpi-core, set content types, timeout is 1800 s i.e 30 mins
curl -s -X POST -H "Content-Type: application/json" -H "Accept: application/json" -m 1800 http://<%= p('cpi.host') %>:<%= p('cpi.port') %>/cpi -d @- | /var/vcap/sys/log/cpi/curlout.log

FIX : add silent flag (-s) to curl, capture stdout with tee to a log file


check process redis-server with pidfile <%= @redis_pid_path %>
  start program = "/etc/init.d/redis6379 start"
  stop program = "/etc/init.d/redis6379 stop"
  if failed host <%= @host %> port <%= @port %> then alert

check process redis-server with pidfile <%= @redis_pid_path %>
  start program = "/etc/init.d/redis6379 start"
  stop program = "/etc/init.d/redis6379 stop"
  if failed host <%= @host %> port <%= @port %>
    send "PING\r\n" expect "PONG\r\n"
  then alert

Add ping send to redis monit.

Add ping send to redis monit.


<% provide(:title, "New Chat") %>

<row>

New Chat

<%= form_for :chatparams, url: @chatlog, class: "form-signin" do |f| %>

  Private chat:
    <%= f.check_box :privatechat, {}, true %>

  Chat name
  <%= f.text_field :chatname, class: "form-control", placeholder: "Enter chat name here" %>

  <%= submit_tag "Create", class: "btn btn-large btn-primary btn-block"  %>

<% end %>

</row>

<% provide(:title, "New Chat") %>

  <row>

Start a New Chat

            <%= form_for :chatparams, url: @chatlog, class: "form-signin" do |f| %>
              <%= label_tag :chatparams_chatname, "Chat name", class: "label label-default" %>
              <%= f.text_field :chatname, class: "form-control", placeholder: "Enter chat name here" %>
              <%= f.check_box :privatechat, {}, true %>
              <%= label_tag :chatparams_privatechat, "Private?" %>

                <%= submit_tag "Create", class: "btn btn-large btn-primary btn-block"  %>

            <% end %>

  </row>

Clean up Chatlogs new view.

Clean up Chatlogs new view.


<% content_for(:title, 'Upload a picture') %>
<% content_for(:page, 'upload') %>

Upload a picture

        <%= render 'form', picture: @picture %>

<% content_for(:title, 'Upload a picture') %>
<% content_for(:page, 'upload') %>

Upload a picture

        <% if current_user.balance < 0 %>

            Warning!
            Your data balance is -<%= number_to_human_size(-current_user.balance) %>,
            you need to <%= link_to 'top up', account_billing_path %> before uploading
            new pictures.

          <% end %>
        <%= render 'form', picture: @picture %>

Add warning and link to top up on upload page


<% avatar_url = if user.thumbnail.exists?
                  user.thumbnail(:medium)
                else
                  asset_path('staff/staff-default-avatar.png')
                end %>

  <%= link_to staff_path(user) do %>
    <div class="staff-pic" style="background-image: url('<%= avatar_url %>')">

<%= user.display_name %>

<%= user.current_position %>

  <% end %>

<% avatar_url = if user.thumbnail.file?
                  user.thumbnail(:medium)
                else
                  asset_path('staff/staff-default-avatar.png')
                end %>

  <%= link_to staff_path(user) do %>
    <div class="staff-pic" style="background-image: url('<%= avatar_url %>')">

<%= user.display_name %>

<%= user.current_position %>

  <% end %>

Use file instead of exists

Use file instead of exists


LYRICALLY CHALLENGED!

<%= form_tag("/search", method: "get", class: "form-search", remote: true) do %>
  <%= label_tag(:word, "Search for:") %>
  <%= text_field_tag(:word) %>
  <%= submit_tag("Search") %>
<% end %>

 Doing stuff

Delete doing stuff for loading page

Delete doing stuff for loading page


Yardım

<%= link_to_unless_current "Hakkımızda", help_about_path %>

<%= link_to_unless_current "Başvuru yapmak", help_requesting_path %>

<%= link_to_unless_current "Gizlilik", help_privacy_path %>

<%= link_to_unless_current "Kamu görevlileri için bilgi", help_officers_path %>

<%= link_to_unless_current "About the software", help_alaveteli_path %>

<%= link_to_unless_current "Credits", help_credits_path %>

<%= link_to_unless_current "Programmers API", help_api_path %>

<%= link_to_unless_current "Advanced search", advanced_search_path %>

İletişim

Sorunuza burada cevap bulamıyorsanız, <a href="<%= help_contact_path %>">bizimle iletişime geçebilirsiniz.

Yardım

<%= link_to_unless_current "Hakkımızda", help_about_path %>

<%= link_to_unless_current "Başvuru yapmak", help_requesting_path %>

<%= link_to_unless_current "Gizlilik", help_privacy_path %>

<%= link_to_unless_current "Kamu görevlileri için bilgi", help_officers_path %>

<%= link_to_unless_current "About the software", help_alaveteli_path %>

<%= link_to_unless_current "Credits", help_credits_path %>

<%= link_to_unless_current "Programmers API", help_api_path %>

<%= link_to_unless_current "Ara", advanced_search_path %>

İletişim

Sorunuza burada cevap bulamıyorsanız, <a href="<%= help_contact_path %>">bizimle iletişime geçebilirsiniz.

Add "Advanced search" sidebar translation

Uses the page title from http://bilmehakki.org/advancedsearch


<%= form_for [:users, @notification_rule], :html => {:class => 'form-inline'} do |f| %>
	<%= f.label :class_name %>
	<%= f.select :class_name, class_name_options_for_select %>

	<%= f.label :action %>
	<%= f.select :action, action_options_for_select %>

	<%= f.label :reactor_name %>
	<%= f.collection_select :reactor_name, Inquest::Reactor.subclasses, :name, :reaction_description %>

	<div class="form-actions">
		<%= f.submit 'Save Notification', :class => 'btn btn-primary' %>
	</div>
<% end %>

<%= form_for [:users, @notification_rule], :html => {:class => 'well form-inline'} do |f| %>
	<%= f.label :class_name %>
	<%= f.select :class_name, class_name_options_for_select, {}, :class => 'span2', :'data-reveal-section' => '_actions' %>

	<% Inquest::Application.config.notifiable_classes.each do |klass| %>
		<%= content_tag :span, :id => "#{klass.name}_actions", :class => 'hide-unless-selected hide' do %>
			<%= f.label :action %>
			<%= f.select :action, klass.notifiable_actions, {}, :disabled => true %>
		<% end %>
	<% end %>

	<%= f.label :reactor_name %>
	<%= f.collection_select :reactor_name, Inquest::Application.config.reactor_classes, :name, :reaction_description %>

	<%= f.submit 'Save Notification', :class => 'btn btn-primary' %>
<% end %>

Adjust layout of form to fit across page


<script type="text/javascript">
//<![CDATA[
var onbeforeunload_flag = false;

function set_onbeforeunload(value) {
  onbeforeunload_flag = value;
}

function show_confirmation(evt) {
  if (onbeforeunload_flag) {
    <%
    # This sets an additional message shown to the user when
    # he intends to navigate away and cancels the request if
    # 'Cancel' is pressed by the user.
    %>
    evt.returnValue = '<%= I18n.t('uncommitted_changes_warning') %>';
  }
}

// register basic handler
window.onbeforeunload = show_confirmation;
//]]>
</script>

<script type="text/javascript">
//<![CDATA[
var onbeforeunload_flag = false;

function set_onbeforeunload(value) {
  onbeforeunload_flag = value;
}

function show_confirmation(evt) {
  if (onbeforeunload_flag) {
    <%
    # This sets an additional message shown to the user when
    # he intends to navigate away and cancels the request if
    # 'Cancel' is pressed by the user.
    %>
    evt.returnValue = "<%= I18n.t('uncommitted_changes_warning') %>";
  }
}

// register basic handler
window.onbeforeunload = show_confirmation;
//]]>
</script>

Fix Javascript error Strings between single quotes while it should be double quotes.


<?xml version="1.0" encoding="UTF-8"?>
<!-- DO NOT EDIT: File is auto-generated -->
<module>
  <inherits name="org.realityforge.gwt.lognice.Lognice"/>
  <inherits name="com.google.gwt.logging.LoggingDisabled"/>
<% if repository.appcache? -%>
  <inherits name="org.realityforge.gwt.appcache.Appcache"/>
<% end -%>

  <set-configuration-property name="CssResource.enableGss" value="true" />
  <set-configuration-property name="CssResource.legacy" value="true" />

  <source path='client'/>
  <source path='shared'/>
</module>

<?xml version="1.0" encoding="UTF-8"?>
<!-- DO NOT EDIT: File is auto-generated -->
<module>
  <inherits name="com.google.gwt.inject.Inject"/>
  <inherits name="org.realityforge.gwt.lognice.Lognice"/>
  <inherits name="com.google.gwt.logging.LoggingDisabled"/>
<% if repository.appcache? -%>
  <inherits name="org.realityforge.gwt.appcache.Appcache"/>
<% end -%>

  <set-configuration-property name="CssResource.enableGss" value="true" />
  <set-configuration-property name="CssResource.legacy" value="true" />

  <source path='client'/>
  <source path='shared'/>
</module>

Add Inject module as required for gin modules generated


# This file is generated automatically by Puppet - DO NOT EDIT
# Any manual changes will be overwritten
<% @mount_file_content.sort.each do |worker,directives| -%>

<%# Places comment before worker mappings -%>
<% if directives.has_key?('comment') -%>
# <%= directives['comment'] %>
<% end -%>
<% directives['uri_list'].sort.each do |uri| -%>
<%= uri %> = <%= worker %>
<% end -%>
<% end -%>

# This file is generated automatically by Puppet - DO NOT EDIT
# Any manual changes will be overwritten
<%# -%>
<%# mount_file_content should be a hash which keys are workers names -%>
<%# and values are new hashes with two items: -%>
<%# uri_list - Array with URIs to be mapped to worker -%>
<%# comment - Optional comment line -%>
<%# -%>
<%# Example: -%>
<%# # Worker 1 -%>
<%# /context_1/ = worker_1 -%>
<%# /context_1/* = worker_1 -%>
<%# -%>
<%# # Worker 2 -%>
<%# / = worker_2 -%>
<%# /context_2/ = worker_2 -%>
<%# /context_2/* = worker_2 -%>
<%# -%>
<%# should be parameterized as: -%>
<%# $mount_file_content = { -%>
<%#   worker_1 => { -%>
<%#     uri_list => ['/context_1/', '/context_1/*'], -%>
<%#     comment  => 'Worker 1', -%>
<%#   }, -%>
<%#   worker_2 => { -%>
<%#     uri_list => ['/context_2/', '/context_2/*'], -%>
<%#     comment  => 'Worker 2', -%>
<%#   }, -%>
<%# }, -%>
<%# -%>
<% @mount_file_content.sort.each do |worker,directives| -%>

<%# Places comment before worker mappings -%>
<% if directives.has_key?('comment') -%>
# <%= directives['comment'] %>
<% end -%>
<% directives['uri_list'].sort.each do |uri| -%>
<%= uri %> = <%= worker %>
<% end -%>
<% end -%>

Document URI-worker mappings template for mod_jk


<script type="text/javascript" src="//use.typekit.net/csi1ugd.js"></script>
<script type="text/javascript">try{Typekit.load();}catch(e){}</script>

<meta name="google-site-verification" content="DbAHEzh0igI0rZziSexQh5fTrbRfNPSw8BdmrmNY_70" />

Add verification code for Webmaster tools.


            <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1">
                Toggle navigation

            </button>
            <a class="navbar-brand" <%= link_to "Start Bootstrap", root_path %>

                    <%= link_to "Home", root_path %>

                    <%= link_to "About", about_path %>

                    <%= link_to "Sample Post", post_path %>

                    <%= link_to "Contact", contact_path data: { no_turbolink: true }%>

            <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1">
                Toggle navigation

            </button>
            <a class="navbar-brand" <%= link_to "Start Bootstrap", root_path %>

                    <%= link_to "Home", root_path %>

                    <%= link_to "About", about_path %>

                    <%= link_to "Sample Post", post_path %>

                    <%= link_to "Contact", contact_path, data: { no_turbolink: true }%>

Add a missing comma that was causing the clean blog navigation to error out


<%= @agent_name %>.channels = memoryChannel
<%= @agent_name %>.channels.memoryChannel.type = memory
<%= @agent_name %>.sources = pstream
<%= @agent_name %>.sources.pstream.channels = memoryChannel
<%= @agent_name %>.sources.pstream.type = exec
<%= @agent_name %>.sources.pstream.command = tail -f <%= @log_location %>
<%= @agent_name %>.sinks = hdfsSink
<%= @agent_name %>.sinks.hdfsSink.type = hdfs
<%= @agent_name %>.sinks.hdfsSink.channel = memoryChannel
<%= @agent_name %>.sinks.hdfsSink.hdfs.useLocalTimeStamp = true
<%= @agent_name %>.sinks.hdfsSink.hdfs.path = <%= node['bcpc']['hadoop']['hdfs_url'] %>/user/flume/logs/%y-%m-%d
<%= @agent_name %>.sinks.hdfsSink.hdfs.filePrefix = <%= @agent_name %>-<%= node.hostname %>
<%= @agent_name %>.sinks.hdfsSink.hdfs.fileType = DataStream
<%= @agent_name %>.sinks.hdfsSink.hdfs.writeFormat = Text
<%= @agent_name %>.sinks.hdfsSink.hdfs.rollInterval = <%= node['bcpc']['hadoop']['copylog_rollup_interval'] %>
<%= @agent_name %>.sinks.hdfsSink.hdfs.rollSize = 0
<%= @agent_name %>.sinks.hdfsSink.hdfs.rollCount = 0

<%= @agent_name %>.channels = memoryChannel
<%= @agent_name %>.channels.memoryChannel.type = memory
<%= @agent_name %>.channels.memoryChannel.capacity = 10000
<%= @agent_name %>.sources = pstream
<%= @agent_name %>.sources.pstream.channels = memoryChannel
<%= @agent_name %>.sources.pstream.type = exec
<%= @agent_name %>.sources.pstream.command = tail -f <%= @log_location %>
<%= @agent_name %>.sinks = hdfsSink
<%= @agent_name %>.sinks.hdfsSink.type = hdfs
<%= @agent_name %>.sinks.hdfsSink.channel = memoryChannel
<%= @agent_name %>.sinks.hdfsSink.hdfs.useLocalTimeStamp = true
<%= @agent_name %>.sinks.hdfsSink.hdfs.path = <%= node['bcpc']['hadoop']['hdfs_url'] %>/user/flume/logs/%y-%m-%d
<%= @agent_name %>.sinks.hdfsSink.hdfs.filePrefix = <%= @agent_name %>-<%= node.hostname %>
<%= @agent_name %>.sinks.hdfsSink.hdfs.fileType = DataStream
<%= @agent_name %>.sinks.hdfsSink.hdfs.writeFormat = Text
<%= @agent_name %>.sinks.hdfsSink.hdfs.rollInterval = <%= node['bcpc']['hadoop']['copylog_rollup_interval'] %>
<%= @agent_name %>.sinks.hdfsSink.hdfs.rollSize = 0
<%= @agent_name %>.sinks.hdfsSink.hdfs.rollCount = 0

Set a higher value for Flume channel capacity where the default is 100 which is not sufficient


(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');

ga('create', 'GA=UA-60081327-1', 'auto');
ga('send', 'pageview');

(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');

ga('create', 'UA-60081327-1', 'auto');
ga('send', 'pageview');

Fix error in GA code

Fix error in GA code


  <div id="<%= dom_id(@proposal) %>" class="row">

<%= t("proposals.created.title") %>

<%= t("proposals.created.motivation") %>

<%= sanitize(t("proposals.created.motivation_2")) %>

      <% if can?(:dashboard, @proposal) %>
        <%= link_to t("proposals.created.dashboard"),
                    progress_proposal_dashboard_path(@proposal),
                    class: "button" %>
      <% end %>

      <% if can?(:publish, @proposal) %>
        <%= link_to t("proposals.created.publish"),
                    publish_proposal_path(@proposal),
                    method: :patch, class: "button" %>
      <% end %>

<%= t("proposals.created.preview_title") %>

<%= render file: "proposals/show.html.erb", locals: { preview: true } %>

  <div id="<%= dom_id(@proposal) %>" class="row">

<%= t("proposals.created.title") %>

<%= t("proposals.created.motivation") %>

<%= sanitize(t("proposals.created.motivation_2")) %>

      <% if can?(:dashboard, @proposal) %>
        <%= link_to t("proposals.created.dashboard"),
                    progress_proposal_dashboard_path(@proposal),
                    class: "button" %>
      <% end %>

      <% if can?(:publish, @proposal) %>
        <%= link_to t("proposals.created.publish"),
                    publish_proposal_path(@proposal),
                    method: :patch, class: "button" %>
      <% end %>

<%= t("proposals.created.preview_title") %>

<%= render template: "proposals/show", locals: { preview: true } %>

Use `render template:` instead of `render file:`

We did a similar change in commit 47925fbab, and we were getting a
warning in Rails 6.0:

DEPRECATION WARNING: render file: should be given the absolute path to a
file

Since using `render file:` would ignore views in custom folders, we're
using `render template:` instead.


Bienvenido a Real State Web

    Esta es la página inicial
    Ruby on Rails Tutorial
    sample application.

  <%= link_to "Regístrese !", '#', class: "btn btn-lg btn-primary" %>

<%= link_to image_tag("rails.png", alt: "Rails logo"),
            'http://rubyonrails.org/' %>

Bienvenido a Real State Web

    Esta es la página inicial
    Ruby on Rails Tutorial
    sample application.

  <%= link_to "Regístrese !", new_user_path, class: "btn btn-lg btn-primary" %>

<%= link_to image_tag("rails.png", alt: "Rails logo"),
            'http://rubyonrails.org/' %>

Add path to new User action on home page.


docs/
pkg/
Gemfile.lock
Gemfile.local
vendor/
.vendor/
spec/fixtures/manifests/
spec/fixtures/modules/
.vagrant/
.bundle/
.ruby-version
coverage/
log/
.idea/
.dependencies/
.librarian/
Puppetfile.lock
*.iml
.*.sw?
.yardoc/
Dockerfile
<% if ! @configs['paths'].nil? -%>
<% @configs['paths'].each do |path| -%>
<%= path %>
<% end -%>
<% end -%>

docs/
pkg/
Gemfile
Gemfile.lock
Gemfile.local
vendor/
.vendor/
spec/
Rakefile
.vagrant/
.bundle/
.ruby-version
coverage/
log/
.idea/
.dependencies/
.librarian/
Puppetfile.lock
*.iml
.*.sw?
.yardoc/
Dockerfile
<% if ! @configs['paths'].nil? -%>
<% @configs['paths'].each do |path| -%>
<%= path %>
<% end -%>
<% end -%>

Include less when building modules

Include less when building modules

Don't ship the `spec` directory, `Gemfile`, or `Rakefile`.

This should make the average module a fair bit smaller.
PDK already does this by default.
https://github.com/puppetlabs/pdk-templates/blob/172738acbf55e65afb1eb8541deb8bb242ca877b/config_defaults.yml#L57


<%= form_for supporting_page, url: supporting_page.persisted? ? admin_edition_supporting_page_path(@edition, supporting_page.id) : admin_edition_supporting_pages_path(@edition), as: disabled ? :disabled_supporting_page : :supporting_page do |form| %>
  <%= form.errors %>
  <%= form.hidden_field :lock_version %>
  <%= form.text_field :title, disabled: disabled %>
  <%= form.text_area :body, disabled: disabled, class: disabled ? "" : "previewable" %>

  <%= render partial: "admin/shared/attachment_fields", locals: { form: form, edition: supporting_page, parent_type: :supporting_page } %>

  <% unless disabled %>
    <%= form.save_or_cancel cancel: (supporting_page.new_record? ? admin_edition_path(@edition) : admin_supporting_page_path(supporting_page))%>
  <% end %>
<% end %>

<%= edition_editing_tabs(edition) do %>
  <%= standard_edition_form(edition) do |form| %>

    <div class="js-external-url-set">
      <%= render 'inline_attachments_info', form: form, edition: edition %>
    </div>

    <fieldset>
      <legend>Associations</legend>
      <%= render 'related_policy_fields', form: form, edition: edition %>
    </fieldset>

    <%= render 'first_published_at', form: form, edition: edition %>
  <% end %>
<% end %>

Rebuild the supporting pages admin form.


  <meta content='text/html; charset=UTF-8' http-equiv='Content-Type'/>

<%= image_tag("skalbanner.png", size: "250x100", alt: "SkålCon") %>

SkålCon Registration!

Please go to MSP PFS Registration and create your account. Once you have verified your email, please click on the goldenrod "Register" button next to SkålCon to register for the convention. Within 24 hours, volunteers will verify your "paid" status, and you will be able to sign up for specific games.

If you have already registered for SkålCon on the site, thank you! Pleas feel free to ignore this message.

Donations accepted!

If you would like to donate something for either the silent auction or the raffle, please let us know by going to
  our contact page and selecting 'I have something to
  donate!' in the dropdown. Someone will contact you to arrange for your donation.

Thank you for making this convention a success!

SkålCon and MSP Pathfinders

  <meta content='text/html; charset=UTF-8' http-equiv='Content-Type'/>

<%= image_tag("skalbanner.png", size: "250x100", alt: "SkålCon") %>
<%= @message.content %>

SkålCon and MSP Pathfinders

Replace boilerplate with extraction of content.


<!DOCTYPE html>
<html>
<head>
  <title><%= yield :title %> - GOV.UK</title>
  <link title="Search" rel="search" type="application/opensearchdescription+xml" href="/search/opensearch.xml"/>
  <!--[if gt IE 8]><!--><%= stylesheet_link_tag "application-site-search.css", integrity: true, crossorigin: 'anonymous' %><!--<![endif]-->
  <!--[if IE 6]><%= stylesheet_link_tag "application-site-search-ie6.css" %><![endif]-->
  <!--[if IE 7]><%= stylesheet_link_tag "application-site-search-ie7.css" %><![endif]-->
  <!--[if IE 8]><%= stylesheet_link_tag "application-site-search-ie8.css" %><![endif]-->
  <%= javascript_include_tag 'application-site-search', integrity: true, crossorigin: 'anonymous' %>
  <% if @content_item %>
    <%= render partial: 'govuk_component/analytics_meta_tags', locals: { content_item: @content_item } %>
  <% end %>
  <%= yield :extra_headers %>
</head>

<body class="mainstream <%= yield :body_classes %>">
<div id="wrapper">
  <%= yield %>
  <%= render_mustache_templates if Rails.env.development? %>
</div>
</body>
</html>

<!DOCTYPE html>
<html>
<head>
  <title><%= yield :title %> - GOV.UK</title>
  <link title="Search" rel="search" type="application/opensearchdescription+xml" href="/search/opensearch.xml"/>
  <!--[if gt IE 8]><!--><%= stylesheet_link_tag "application-site-search.css", integrity: true, crossorigin: 'anonymous' %><!--<![endif]-->
  <!--[if IE 6]><%= stylesheet_link_tag "application-site-search-ie6.css" %><![endif]-->
  <!--[if IE 7]><%= stylesheet_link_tag "application-site-search-ie7.css" %><![endif]-->
  <!--[if IE 8]><%= stylesheet_link_tag "application-site-search-ie8.css" %><![endif]-->
  <%= javascript_include_tag 'application-site-search', integrity: true, crossorigin: 'anonymous' %>
  <% if @content_item %>
    <%= render partial: 'govuk_component/analytics_meta_tags', locals: { content_item: @content_item } %>
  <% end %>
  <%= yield :extra_headers %>
</head>

<body class="mainstream <%= yield :body_classes %>">
<div id="wrapper">
  <%= yield %>
  <%= render 'govuk_publishing_components/components/feedback' %>
  <%= render_mustache_templates if Rails.env.development? %>
</div>
</body>
</html>

Add feedback component to search pages too

I didn't realise that this used a completely separate layout.

https://trello.com/c/eKtXGtBD


<%= video_tag("/videos/clouds.mp4", controls: false, autoplay: true, :class => "bgvid") %>

Add video tag to the index page

Add video tag to the index page


<%= form_with(model: slot, local: true) do |form| %>
  <% if slot.errors.any? %>

<%= pluralize(slot.errors.count, "error") %> prohibited this slot from being saved:

      <% slot.errors.full_messages.each do |message| %>

<%= message %>

      <% end %>

  <% end %>

  <%= form.label :date %>
  <%= form.date_field :date, id: :start_date %>

  <%= form.label :start_time %>
  <%= form.time_field :start_time, id: :start_time %>

  <%= form.select :duration, ["30 minutes", "1 hour", "1 hour 30 minutes", "2 hours"] %>

    <%= form.submit %>

<% end %>

Add errors-class to slot creation page

Add errors-class to slot creation page


<%= image_tag( song.art, :alt => "Album Art", :size => "36x36" ) %>
<%= link_to "#{song.title} on #{song.album} by #{song.artist}", song.detail%>
<% if ( song.station != nil ) && !song.station.empty? %>
  on station:
  <%= link_to " #{song.station}", play_url(Station.find_by_name(song.station)), method: "post" %>
<% end %>
<br />

<%= link_to(image_tag( song.art, :alt => "Album Art", :size => "36x36" ), song_art_url(song)) %>
<%= link_to "#{song.title} on #{song.album} by #{song.artist}", song.detail%>
<% if ( song.station != nil ) && !song.station.empty? %>
  on station:
  <%= link_to " #{song.station}", play_url(Station.find_by_name(song.station)), method: "post" %>
<% end %>
<br />

Add link to song art in song list

Add link to song art in song list


<%= form_for @user do |f| %>
  <% if @user.errors.any? %>

<%= pluralize(@user.errors.count, "error") %> prevented your profile from being saved:

      <% @user.errors.full_messages.each do |msg| %>

<%= msg %>

      <% end %>

  <% end %>
  <%= f.label :username %>
  <%= f.text_field :username %>
  <%= f.label :email %>
  <%= f.email_field :email %>
  <%= f.label :phone %>
  <%= f.text_field :phone %>
  <%= f.label "School" %>
  <%= collection_select(:user, :school_id, School.all, :id, :name) %>

Password and Parent Password must both be 10 characters or more

  <%= f.label :password %>
  <%= f.password_field :password %>
  <%= f.label :password_confirmation %>
  <%= f.password_field :password_confirmation %>
  <%= f.label :parent_password %>
  <%= f.password_field :parent_password %>
  <%= f.label :parent_password_confirmation %>
  <%= f.password_field :parent_password_confirmation %>
  <%= f.submit %>
<% end %>

<%= form_for @user do |f| %>
  <% if @user.errors.any? %>

<%= pluralize(@user.errors.count, "error") %> prevented your profile from being saved:

      <% @user.errors.full_messages.each do |msg| %>

<%= msg %>

      <% end %>

  <% end %>
  <%= f.label :username %>
  <%= f.text_field :username %>
  <%= f.label :email %>
  <%= f.email_field :email %>
  <%= f.label :phone %>
  <%= f.text_field :phone %>
  <%= f.label "School" %>
  <%= collection_select(:user, :school_id, School.all, :id, :name) %>

Password and Parent Password must both be 10 characters or more

  <%= f.label :password %>
  <%= f.password_field :password %>
  <%= f.label :password_confirmation %>
  <%= f.password_field :password_confirmation %>
  <%= f.label :parent_password %>
  <%= f.password_field :parent_password %>
  <%= f.label :parent_password_confirmation %>
  <%= f.password_field :parent_password_confirmation %>
  <%= f.submit "Update your profile" %>
<% end %>

Change 'Edit User' to 'Update your profile'


<%= notice %>

Listing Users

      Name
      City
      Country
      Email
      Age

    <% @users.each do |user| %>

        <%= user.name %>
        <%= user.city %>
        <%= user.country %>
        <%= user.email %>
        <%= user.age %>
        <%= link_to 'Show', user %>
        <%= link_to 'Edit', edit_user_path(user) %>
        <%= link_to 'Destroy', user, method: :delete, data: { confirm: 'Are you sure?' } %>

    <% end %>

<%= link_to 'New User', new_user_path %>

<%= notice %>

Listing Users

      Name
      City
      Country
      Email
      Age
      Website

    <% @users.each do |user| %>

        <%= user.name %>
        <%= user.city %>
        <%= user.country %>
        <%= user.email %>
        <%= user.age %>
        <%= user.website %>
        <%= link_to 'Show', user %>
        <%= link_to 'Edit', edit_user_path(user) %>
        <%= link_to 'Destroy', user, method: :delete, data: { confirm: 'Are you sure?' } %>

    <% end %>

<%= link_to 'New User', new_user_path %>

Add :website attribute in index view for validity check


<!DOCTYPE html>

<meta charset="utf-8">

  <title>JS Box</title>
  <meta name="viewport" content="width=device-width, initial-scale=1.0">

JS Box

    A simple tool for experimenting with JS libraries in your web console.

    Development versions of jQuery and Underscore are included in this page,
    with no other JavaScript files. To use your web console with these
    libraries, simply open it up on this page and hack away.

  © 2013 Nicolas McCurdy

  <% library_urls.each do |url| %>

  <% end %>

<!DOCTYPE html>

<meta charset="utf-8">

  <title>JS Box</title>
  <meta name="viewport" content="width=device-width, initial-scale=1.0">

  <link rel="stylesheet" href="http://yui.yahooapis.com/pure/0.2.0/pure-min.css">
  <link rel="stylesheet" href="http://fonts.googleapis.com/css?family=Oswald:400,700,300">

JS Box

    A simple tool for experimenting with JS libraries in your web console.

    Development versions of jQuery and Underscore are included in this page,
    with no other JavaScript files. To use your web console with these
    libraries, simply open it up on this page and hack away.

  © 2013 Nicolas McCurdy

  <% library_urls.each do |url| %>

  <% end %>

Use Pure (CSS framework) and Oswald (font)


Welcome!

Food carts is the best solution for managing everything you need when it comes to accepting payments with your Food Cart. We support more than 50+ different payment gateways so you can work with your favorite option. Better still, we make it easy to change gateways without losing your customer data! You worry about making the world's yummiest food and we'll take care of the payments side.

<% if @cart %>

You have already created a cart. View it or delete it.

<% else %>

Create an Account

    <% if @error %>

<%= @error %>

    <% end %>
    <form class="form-horizontal" action="/carts" method="POST">

        Cart Name

          <input type="text" name="cart_name" id="cart_name" placeholder="Cart name">

          <button type="submit" class="btn">Sell Food!</button>

    </form>

<% end %>

Welcome!

Food carts is the best solution for managing everything you need when it comes to accepting payments with your Food Cart. We support more than 60+ different payment gateways so you can work with your favorite option. Better still, we make it easy to change gateways without losing your customer data! You worry about making the world's yummiest food and we'll take care of the payments side.

<% if @cart %>

You have already created a cart. View it or delete it.

<% else %>

Create an Account

    <% if @error %>

<%= @error %>

    <% end %>
    <form class="form-horizontal" action="/carts" method="POST">

        Cart Name

          <input type="text" name="cart_name" id="cart_name" placeholder="Cart name">

          <button type="submit" class="btn">Sell Food!</button>

    </form>

<% end %>

Update gateway count to 60+.

Update gateway count to 60+.


  SSLProtocol -ALL +TLSv1
  SSLCipherSuite ALL:!ADH:RC4+RSA:+HIGH:+MEDIUM:-LOW:-SSLv2:-EXP
  SSLVerifyClient         optional
  SSLVerifyDepth          1
  SSLOptions              +StdEnvVars

  RackBaseURI /
  <Directory /etc/puppet/rack/>
    Options None
    AllowOverride None
    Order allow,deny
    Allow from all
  </Directory>
<% if @puppet_central_ca -%>

  ProxyRequests Off
  <Proxy *>
    Order allow,deny
<% @proxy_allow_from.each do |host| -%>
    Allow from <%= host %>
<% end -%>
  </Proxy>

  ProxyVia On

  ProxyPassMatch ^/([^/]+/certificate.*)$ <%= @puppet_central_ca %>/$1
<% end -%>

  SSLProtocol -ALL +TLSv1
  SSLCipherSuite ALL:!ADH:RC4+RSA:+HIGH:+MEDIUM:-LOW:-SSLv2:-EXP
  SSLVerifyClient         optional
  SSLVerifyDepth          1
  SSLOptions              +StdEnvVars

  RackBaseURI /
  <Directory /etc/puppet/rack/>
    Options None
    AllowOverride None
    Order allow,deny
    Allow from all
  </Directory>
<% if @puppet_central_ca -%>

  ProxyRequests Off
  <Proxy *>
    Order allow,deny
<% @proxy_allow_from.each do |host| -%>
    Allow from <%= host %>
<% end -%>
  </Proxy>

  ProxyVia On

  ProxyPassMatch ^/([^/]+/certificate.*)$ <%= @puppet_central_ca %>/$1
  <Location ~ "/[^/]+/certificate">
   PassengerHighPerformance Off
  </Location>
<% end -%>

Fix CA proxying with passenger

Fix CA proxying with passenger


sudo systemctl daemon-reload
docker exec -it <%= @cluster_owner %>.cache.gateway tail -f /var/log/squid/access.log
<% if @lifecycle_stage == "production" -%>
journalctl -xe
journalctl -l
systemctl list-unit-files
systemctl cat puppet.service
docker exec -it puppet.service puppet agent -t
sudo docker rm -f puppet.service
etcdctl cluster-health
etcdctl member list
docker exec -it <%= @cluster_owner %>.ceph_mon.service bash -c 'ceph --admin-daemon /var/run/ceph/ceph-*asok mon_status'
docker exec -it <%= @cluster_owner %>.ceph_mon.service ceph health detail
fleetctl list-machines
fleetctl list-units
fleetctl list-unit-files
kubectl get all --all-namespaces --show-all=true -o=wide
<%- else -%>
sudo sh -c "source /mnt/etc/environment; /home/core/cluster.coreos.install/install.sh puppet"
(cd /home/core/cluster.coreos.install/; sudo git pull)
journalctl -f -u coreos-bootstrap.service
sudo systemctl restart coreos-bootstrap.service && journalctl -f -u coreos-bootstrap.service
docker exec -it puppet-bootstrap.service puppet agent -t
sudo docker rm -f puppet-bootstrap.service
sudo /home/core/cluster.coreos.install/install.sh puppet
<% end %>

sudo systemctl daemon-reload
docker exec -it <%= @cluster_owner %>.cache.gateway tail -f /var/log/squid/access.log
<% if @lifecycle_stage == "production" -%>
journalctl -xe
journalctl -l
systemctl list-unit-files
systemctl cat puppet.service
docker exec -it puppet.service puppet agent -t
sudo docker rm -f puppet.service
etcdctl cluster-health
etcdctl member list
docker exec -it <%= @cluster_owner %>.ceph_mon.service bash -c 'ceph --admin-daemon /var/run/ceph/ceph-*asok mon_status'
docker exec -it <%= @cluster_owner %>.ceph_mon.service ceph health detail
docker exec -it <%= @cluster_owner %>.ceph_mon.service ceph osd pool stats
fleetctl list-machines
fleetctl list-units
fleetctl list-unit-files
kubectl get all --all-namespaces --show-all=true -o=wide
<%- else -%>
sudo sh -c "source /mnt/etc/environment; /home/core/cluster.coreos.install/install.sh puppet"
(cd /home/core/cluster.coreos.install/; sudo git pull)
journalctl -f -u coreos-bootstrap.service
sudo systemctl restart coreos-bootstrap.service && journalctl -f -u coreos-bootstrap.service
docker exec -it puppet-bootstrap.service puppet agent -t
sudo docker rm -f puppet-bootstrap.service
sudo /home/core/cluster.coreos.install/install.sh puppet
<% end %>

Add "ceph osd pool stats" to history

Add "ceph osd pool stats" to history


  Click any traffic-light to:

see the diff of its files

revert back to its files

fork a new exercise from its files

peek on other avatars' files (in a group exercise)

  Click any traffic-light to:

see the diff of its files

revert back to its files

fork a new exercise from its files

peek at other avatars' files (in a group exercise)

Tweak wording in dialog help-text

Tweak wording in dialog help-text


Please select the Place in the hierarchy where you would like to add your new Place

<%= javascript_include_tag 'kmaps_engine/kmaps_fancytree' %>
<%= javascript_on_load do %>
  $("#relation_tree_container").kmapsFancytree({
    featureId: 13735,
    featuresPath: "<%= new_admin_feature_path %>?parent_id=%%ID%%",
    termIndex: "<%= Feature.config.url %>",
    perspective: "<%= current_perspective.code %>",
    seedTree: {
      descendants: true,
      directAncestors: false,
    },
    displayPopup: false
  });
<% end %>

Add partial for select ancestor

Add partial for select ancestor

Added the select_ancestor partial that shows the hierarchical tree in
the editorial interface for adding new features.


<%= form_tag(newsletter_subscription_path, class: 'newsletter', remote: true) do %>
  <%= hidden_field_tag :authenticity_token, form_authenticity_token -%>

<%= t('newsletter_subscriptions.heading') %>

    <% t('newsletter_subscriptions.benefits').each do |benefit| %>

<%= benefit %>

    <% end %>

  <%= label_tag('subscription[email]', 'Email address', class: 'visually-hidden') %>

        <%= email_field_tag('subscription[email]', nil, class: 'newsletter__input') %>

        <%= button_tag('Sign up', type: 'submit', class: 'button button--inline-input newsletter__button') %>

<% end %>

<%= form_tag(newsletter_subscription_path, class: 'newsletter', remote: true) do %>
  <%= hidden_field_tag :authenticity_token, form_authenticity_token -%>

<%= t('newsletter_subscriptions.heading') %>

    <% t('newsletter_subscriptions.benefits').each do |benefit| %>

<%= benefit %>

    <% end %>

  <%= label_tag('subscription[email]', 'Email address', class: 'visually-hidden') %>

        <%= email_field_tag('subscription[email]', nil, class: 'newsletter__input') %>

        <%= button_tag('Sign up', type: 'submit', class: 'button button--inline-input newsletter__button') %>
          <%= text_field_tag('subscription[email]', nil, class: 'js-newsletter-input newsletter__input') %>

<% end %>

Convert newsletter input to text_field from email_field


<% page_title "Case Studies" %>
<% page_class "case-studies-index index-list-page" %>

Case Studies

Government research into…

      <% if @case_studies.any? %>

          <% @case_studies.each do |case_study| %>
            <%= content_tag_for(:li, case_study, class: 'title') do %>
            <%= link_to case_study.title, public_document_path(case_study) %>
            <% end %>
          <% end %>

      <% end %>

Add classname to index list

Add classname to index list


  <% @datasets.each do |dataset| %>

<%= link_to dataset.name, dataset %>

            <% if dataset.logo.size > 0 %>
              <%= link_to image_tag( logo_dataset_path(dataset), style: 'max-width:100%;' ), dataset %>
            <% else %>
              <%= link_to image_tag( 'project-default-logo.png', style: 'max-width:100%;' ), dataset %>
            <% end %>

  <% end %>

<%= paginate @datasets, theme: "contour" %>

  <% @datasets.each do |dataset| %>

<%= link_to dataset.name, dataset %>

            <% if dataset.logo.size > 0 %>
              <%= link_to image_tag( logo_dataset_path(dataset), style: 'max-width:100%;max-height:140px' ), dataset %>
            <% else %>
              <%= link_to image_tag( 'project-default-logo.png', style: 'max-width:100%;max-height:140px' ), dataset %>
            <% end %>

  <% end %>

<%= paginate @datasets, theme: "contour" %>

Set max-width for dataset logos

Set max-width for dataset logos


<%= link_to rails_blob_path(asset.file, disposition: 'attachment'),
  class: 'file-preview-link',
  id: "modal_link#{asset.id}",
  data: { no_turbolink: true,
          id: true,
          status: 'asset-present',
          'preview-url': asset_file_preview_path(asset) } do %>
  <%= render partial: 'shared/asset_placeholder.html.erb', locals: { edit_page: false, asset: asset } %>
<% end %>

<%= link_to rails_blob_path(asset.file, disposition: 'attachment'),
  class: 'file-preview-link',
  id: "modal_link#{asset.id}",
  data: { no_turbolink: true,
          id: true,
          status: 'asset-present',
          'preview-url': asset_file_preview_path(asset) } do %>
  <%= truncate(asset.file_name, length: Constants::FILENAME_TRUNCATION_LENGTH) %>
<% end %>

Fix file preview in inventory

Fix file preview in inventory


<%# Requires parameter efforts %>

    <%= "#{@participant.full_name}'s efforts:" %>
    From
    Finish Time
    <% if @current_user && @current_user.admin? %>
        Actions
    <% end %>

  <% efforts.each do |effort| %>
      <% if effort.bad? %>

      <% elsif effort.questionable? %>

      <% else %>

      <% end %>
      <%= link_to effort.event.name, effort_path(effort) %>
      <%= effort.state_and_country %>
      <%= effort.try(:time) || effort.finish_status %>
      <% if @current_user && @current_user.admin? %>
          <%= link_to 'Disassociate',
                                             remove_effort_participant_path(@participant, effort_id: effort.id),
                                             method: :delete,
                                             class: 'btn btn-xs btn-danger' %>
      <% end %>

  <% end %>

<%# Requires parameter efforts %>

    <%= "#{@participant.full_name}'s efforts:" %>
    From
    Finish Time
    <% if @current_user && @current_user.admin? %>
        Actions
    <% end %>

  <% efforts.each do |effort| %>
      <% if effort.bad? %>

      <% elsif effort.questionable? %>

      <% else %>

      <% end %>
      <%= link_to effort.event.name, effort_path(effort) %>
      <%= effort.state_and_country %>
      <%= effort.finish_status %>
      <% if @current_user && @current_user.admin? %>
          <%= link_to 'Disassociate',
                                             remove_effort_participant_path(@participant, effort_id: effort.id),
                                             method: :delete,
                                             class: 'btn btn-xs btn-danger' %>
      <% end %>

  <% end %>

Remove obsolete code from _efforts_list_participant partial.


<% cache(["gobierto_cms/pages/meta_welcome", current_site, I18n.locale]) do %>
  <% title(@page.title) %>
  <% description(truncate(strip_tags(@page.body), length: 100)) %>

  <%= render @page.template %>
<% end %>

<% cache(["gobierto_cms/pages/meta_welcome", current_site, I18n.locale]) do %>
  <% title(@page.title) %>
  <% description(truncate(strip_tags(@page.body), length: 100)) %>

  <% content_for :javascript_module_link do %>
    <%= javascript_packs_with_chunks_tag 'cms', 'data-turbolinks-track': true %>
  <% end %>

  <% content_for :stylesheet_module_link do %>
    <%= stylesheet_packs_with_chunks_tag 'cms' %>
  <% end %>

  <%= render @page.template %>
<% end %>

Add the frontend dependencies in the meta_welcome template


use strict;

#
# Place your configuration directives here.  They will override those in
# earlier files.
#
# See /usr/share/doc/amavisd-new/ for documentation and examples of
# the directives you can use in this file
#

$myhostname = '<%= @fqdn %>';
@local_domains_acl = qw(.);
@inet_acl = qw( <%= @ipaddress %> )

#------------ Do not modify anything below this line -------------
1;  # ensure a defined return

use strict;

#
# Place your configuration directives here.  They will override those in
# earlier files.
#
# See /usr/share/doc/amavisd-new/ for documentation and examples of
# the directives you can use in this file
#

$myhostname = '<%= @fqdn %>';
@local_domains_acl = qw(.);
$inet_socket_bind = '<%= @ipaddress %>';

#------------ Do not modify anything below this line -------------
1;  # ensure a defined return

Change bind address not the acl

Change bind address not the acl


<% page_title 'Edit attachment' %>

Editing attachment: <%= @attachment.title %>

		<%= render partial: 'form', locals: { edition: @edition, attachment: @attachment, url: admin_edition_attachment_path(@edition, @attachment) } %>

Tweak markup for attachments edit

Tweak markup for attachments edit


<input id="hidden_filenames"
       type="hidden"
       name="hidden_filenames"
       value='<%= raw JSON.generate(@hidden_filenames) %>'>

<%# Note %>
<%# 1) The value attribute uses single quotes               %>
<%# 2) The json contains double quotes                      %>
<%# 3) The @hidden_filenames must not contain single quotes %>

Add comment re single/double quotes on kata/edit hidden_filenames


# Managed by Chef! :heart_eyes_cat:

TAGS="packer_chef_solo_time:<%= Time.now.utc.iso8601 %>"

<% @languages.map(&:strip).reject(&:empty?).each do |lang| %>
TAGS="$TAGS,language_<%= lang %>:true"
<% end %>

export TAGS

# Managed by Chef! :heart_eyes_cat:

TAGS="packer_chef_solo_time:<%= Time.now.utc.strftime('%Y%m%dT%H%M%SZ') %>"

<% @languages.map(&:strip).reject(&:empty?).each do |lang| %>
TAGS="$TAGS,language_<%= lang %>:true"
<% end %>

export TAGS

Use a timestamp format without colons whoops


<fieldset id="edition_attachment_fields" class="attachments multiple_file_uploads tabbable">
  <legend>Attachments</legend>

  <ul class="existing-attachments">
  <% edition.attachments.each_with_index do |attachment, i| %>
    <%= render partial: 'attachment', locals: { edition: edition, attachment: attachment, number: i + 1 } %>
  <% end %>
  </ul>
</fieldset>

<fieldset id="edition_attachment_fields" class="attachments multiple_file_uploads tabbable">
  <legend>Attachments</legend>

  <% if edition.new_record? %>

      If you'd like to add an attachment to this document, please save
      it first. You'll then find a new tab at the top of the page that you
      can use to upload, edit and delete attachments.

  <% else %>

    <% edition.attachments.each_with_index do |attachment, i| %>
      <%= render partial: 'attachment', locals: { edition: edition, attachment: attachment, number: i + 1 } %>
    <% end %>

  <% end %>
</fieldset>

Add message explaining where attachment UI has moed to


  <% if total_pages > 1 %>

        <% unless pages.first == 1 && current_page == pages.first %>

<%= link_to "First", params.merge(page: 1) %>

<%= link_to "«", params.merge(page: current_page - 1) %>

        <% end %>
        <% unless pages.first == 1 %>

...

        <% end %>
        <% pages.each do |page| %>
          <li class="<%= "active" if page == current_page %>">
            <%= link_to page, params.merge(page: page) %>

        <% end %>
        <% unless pages.last == total_pages %>

...

        <% end %>
        <% unless pages.last == total_pages && current_page == pages.last %>

<%= link_to "»", params.merge(page: current_page + 1) %>

<%= link_to "Last", params.merge(page: total_pages) %>

        <% end %>

  <% end %>

  <%#= page_entries_info @resources %>

  <% if total_pages > 1 %>

        <% unless pages.first == 1 && current_page == pages.first %>

<%= link_to "First", params.merge(page: 1) %>

<%= link_to "«", params.merge(page: current_page - 1) %>

        <% end %>
        <% unless pages.first == 1 %>

<%= link_to "…" %>

        <% end %>
        <% pages.each do |page| %>
          <li class="<%= "active" if page == current_page %>">
            <%= link_to page, params.merge(page: page) %>

        <% end %>
        <% unless pages.last == total_pages %>

<%= link_to "…" %>

        <% end %>
        <% unless pages.last == total_pages && current_page == pages.last %>

<%= link_to "»", params.merge(page: current_page + 1) %>

<%= link_to "Last", params.merge(page: total_pages) %>

        <% end %>

  <% end %>

  <%#= page_entries_info @resources %>

Use disabled ellipsis for gaps

Use disabled ellipsis for gaps


<%= render partial: "layouts/sidebar", locals: {cur_step: 1} %>

Sorry, we can't help you right now.

Please have your contractor contact Development Services Department at (210) 207-1111 to get the permit you need.

<%= render partial: "layouts/sidebar", locals: {cur_step: 1} %>

Sorry, we can't help you right now.

The contractor you are using needs to apply for the building permit. Please have your contractor contact Development Services Department at (210) 207-1111 to get the permit you need.

Change using contractor error r page message


<%= render :partial => 'spree/admin/shared/product_sub_menu' %>
<%= render :partial => 'spree/admin/shared/product_tabs', :locals => { :current => 'Translations' } %>
<%= render :partial => 'spree/shared/error_messages', :locals => { :target => @product } %>

<% content_for :page_actions do %>
  <li>
    <%= link_to_add_fields Spree.t(:add_product_translations), 'tbody#product_properties', :class => 'icon-plus button' %>
  </li>
<% end %>

<%= render 'form' %>

<%= render :partial => 'spree/admin/shared/product_sub_menu' %>
<%= render :partial => 'spree/admin/shared/product_tabs', :locals => { :current => 'Translations' } %>
<%= render :partial => 'spree/shared/error_messages', :locals => { :target => @product } %>

<% content_for :page_actions do %>
  <li>
    <%= button_link_to Spree.t(:back_to_products_list), admin_products_url, :icon => 'icon-arrow-left' %>
  </li>
<% end %>

<%= render 'form' %>

Update back to lists button on product translations


<% if current_user %>

<%= link_to t(:my_account), spree.account_path %>

<%= link_to t(:logout), spree.destroy_user_session_path %>

<% else %>

<%= link_to t(:login), spree.login_path %>

<% end %>

<% if current_user %>

<%= link_to t(:my_account), spree.account_path %>

<%= link_to t(:logout), spree.destroy_user_session_path, :method => :delete %>

<% else %>

<%= link_to t(:login), spree.login_path %>

<% end %>

[auth] Make logout link now use a DELETE request


<% @gend_images.each do |gi| %>
<%=link_to gi.id, gi %>
<% end %>

<% @gend_images.each do |gi| %>
<%= link_to gi.id_hash,
  :controller => :gend_images,
  :action => :show,
  :id => gi.id_hash %>
<% end %>

Use id_hash in gend_image index view.

Use id_hash in gend_image index view.


<%= notice %>

Upcoming Meetings

Unless otherwise noted, all meetings are held at the office of Renew Financial on the 8th floor of 400 SW 6th Ave., Portland, OR 97202.

<% if @meetings.size == 0 %>

No meetings have been scheduled yet! Follow @TestRubyPDX on Twitter and you'll be the first to know when we announce one.

<% else %>
  <%= render 'list' %>
<% end %>

<%= notice %>

Upcoming Meetings

Unless otherwise noted, all meetings are held at the office of Renew Financial in the first-floor conference room of 400 SW 6th Ave., Portland, OR 97202. When you arrive, tell the security guard you're there for Test Ruby PDX and head across the lobby to your left.

<% if @meetings.size == 0 %>

No meetings have been scheduled yet! Follow @TestRubyPDX on Twitter and you'll be the first to know when we announce one.

<% else %>
  <%= render 'list' %>
<% end %>

Change the location of meetings to the first-floor conference room


<?xml version="1.0" encoding="UTF-8"?>
<!-- DO NOT EDIT: File is auto-generated -->
<module>
<% if repository.imit? -%>
  <inherits name="<%= repository.imit.qualified_replicant_module_name %>"/>
<% else -%>
  <inherits name='org.realityforge.gwt.datatypes.Datatypes'/>
  <inherits name="com.google.gwt.json.JSON"/>
  <inherits name="dagger.Dagger"/>
<% end -%>
<% if repository.keycloak? -%>
  <inherits name="org.realityforge.gwt.keycloak.Keycloak"/>
<% end -%>
<% if repository.iris_audit? -%>
  <inherits name="iris.audit.Audit"/>
<% end -%>
<% if repository.berk? -%>
  <inherits name="iris.berk.Berk"/>
<% end -%>
</module>

<?xml version="1.0" encoding="UTF-8"?>
<!-- DO NOT EDIT: File is auto-generated -->
<module>
<% if repository.imit? -%>
  <inherits name="<%= repository.imit.qualified_replicant_module_name %>"/>
<% else -%>
  <inherits name='org.realityforge.gwt.datatypes.Datatypes'/>
  <inherits name="com.google.gwt.json.JSON"/>
  <inherits name="dagger.Dagger"/>
<% end -%>
<% if repository.gwt_rpc? -%>
  <inherits name="com.google.gwt.user.RemoteService"/>
<% end -%>
<% if repository.keycloak? -%>
  <inherits name="org.realityforge.gwt.keycloak.Keycloak"/>
<% end -%>
<% if repository.iris_audit? -%>
  <inherits name="iris.audit.Audit"/>
<% end -%>
<% if repository.berk? -%>
  <inherits name="iris.berk.Berk"/>
<% end -%>
</module>

Add inherit required for GWT RPC classes


<% breadcrumb.add @model.description, edit_backend_page_path(@model) %>
<% breadcrumb.add t('b.edit') %>
<%= render 'backend/breadcrumbs' %>

<%= render 'backend/pages/tabs', active: params[:translation_locale].to_sym %>
<%= render 'backend/general_form_error', object: @translation %>

<%= simple_form_for([:backend, @translation], url: edit_translation_backend_page_path, html: { class: 'no-focus' }, data: { dirty: false }) do |f| %>

          <%= t 'b.content' %>

          <%= f.input :title %>
          <%= f.input :subtitle %>

      <%= render('backend/content/rows', model: @model, locale: params[:translation_locale]) unless @model.content_disabled? %>

      <%= render 'backend/seo_form', f: f %>

      <%= render 'backend/tags', model: @model %>

  <%= render 'backend/form_actions', cancel_url: backend_pages_path %>
<% end %>

<% breadcrumb.add @model.description, edit_backend_page_path(@model) %>
<% breadcrumb.add t('b.edit') %>
<%= render 'backend/breadcrumbs' %>

<%= render 'backend/pages/tabs', active: params[:translation_locale].to_sym %>
<%= render 'backend/general_form_error', object: @translation %>

<%= simple_form_for([:backend, @translation], url: edit_translation_backend_page_path, html: { class: 'no-focus' }) do |f| %>
  <%= trigger_dirty_inputs_warning %>

          <%= t 'b.content' %>

          <%= f.input :title %>
          <%= f.input :subtitle %>

      <%= render('backend/content/rows', model: @model, locale: params[:translation_locale]) unless @model.content_disabled? %>

      <%= render 'backend/seo_form', f: f %>

      <%= render 'backend/tags', model: @model %>

  <%= render 'backend/form_actions', cancel_url: backend_pages_path %>
<% end %>

Add the dirty input warning trigger to pages.


<% if spree_current_user %>

<%= t(:logged_in_as) %>: <%= spree_current_user.email %>

<%= link_to t(:account), spree.edit_user_path(spree_current_user) %>

<%= link_to t(:logout), spree.logout_path %>

<%= link_to t(:store), spree.products_path, :target => '_blank' %>

<% end %>

<% if spree_current_user %>

<%= t(:logged_in_as) %>: <%= spree_current_user.email %>

<%= link_to t(:account), spree.edit_user_path(spree_current_user) %>

<%= link_to t(:logout), spree.logout_path %>

<%= link_to t(:store), spree.root_path, :target => '_blank' %>

<% end %>

Store links to root_path instead of product_path


echo "---------------------------------------------------------"
echo "👋 Welcome to Gatling!"
echo "⚠ Don't forget to upload your results and command to S3:"
echo "    https://github.com/alphagov/govuk-load-testing/blob/master/docs/uploading.md"
echo "🔎 Results can be found at: <%= @root_dir %>"
echo "---------------------------------------------------------"

Add a space after emoji

Add a space after emoji

The emoji seems to take up the area of the existing space and the
alignment looks all wrong!


  <li role="presentation" class="<%= active == 'orders' ? 'active' : '' %>">Orders

  <li role="presentation" class="<%= active == 'inventory' ? 'active' : '' %>">Inventory

  <li role="presentation" class="<%= active == 'organizations' ? 'active' : '' %>">Organizations

  <li role="presentation" class="<%= active == 'users' ? 'active' : '' %>">Contacts

  <li role="presentation" class="<%= active == 'orders' ? 'active' : '' %>">Orders

  <li role="presentation" class="<%= active == 'inventory' ? 'active' : '' %>">Inventory

  <li role="presentation" class="<%= active == 'organizations' ? 'active' : '' %>">Organizations

  <li role="presentation" class="<%= active == 'users' ? 'active' : '' %>">Users

Rename tab text to User

Rename tab text to User


	<% if current_user.present? %>
		<% content_for :headJavascript do %>

		<% end %>

				<% if @is_locked %>

hueIT is locked

				<% end %>

						<%= render 'form' %>

	<% end %>

Make body take more space on small and medium screens


<%= current_user.name %>

  <% current_user.skills.each do |skill| %>

<%= skill.title %> - Time remaining: <%= skill.time_remaining %>

  <% end %>

<%= form_for @new_skill do |f| %>
  <%= f.text_field :title %>
  <%= f.submit "add" %>
<% end %>

<%= current_user.name %>

  <% current_user.skills.each do |skill| %>

<%= skill.title %> - <%= skill.time_remaining %>

  <% end %>

<%= form_for @new_skill do |f| %>
  <%= f.text_field :title %>
  <%= f.submit "add" %>
<% end %>

Add time remaining to index display

Add time remaining to index display


Edit <%= resource_name.to_s.humanize %>

<%= form_for(resource, as: resource_name, url: registration_path(resource_name), html: { method: :put }) do |f| %>
  <%= devise_error_messages! %>

    <%= f.label :email %>

    <%= f.email_field :email, autofocus: true %>

  <% if devise_mapping.confirmable? && resource.pending_reconfirmation? %>

Currently waiting confirmation for: <%= resource.unconfirmed_email %>

  <% end %>

    <%= f.label :password %> (leave blank if you don't want to change it)

    <%= f.password_field :password, autocomplete: "off" %>

    <%= f.label :password_confirmation %>

    <%= f.password_field :password_confirmation, autocomplete: "off" %>

    <%= f.label :current_password %> (we need your current password to confirm your changes)

    <%= f.password_field :current_password, autocomplete: "off" %>

    <%= f.submit "Update" %>

<% end %>

Cancel my account

Unhappy? <%= button_to "Cancel my account", registration_path(resource_name), data: { confirm: "Are you sure?" }, method: :delete %>

<%= link_to "Back", :back %>

Edit <%= resource_name.to_s.humanize %>

<%= render '/devise/registrations/edit_form' %>
<%= link_to "Back", :back %>

Set path of edit form

[Template] Set path of edit form


<% current_version = project.versions.where("effective_date >= ?", Time.now).last %>
<% active = (current_version && Redmine::Activity::Fetcher.new(User.current, :project => project, :with_subprojects => true).events(Time.now - Setting.plugin_project_overview[:stale_num_days].to_i.days, Time.now).any?) %>

<% if active || @stale %>

	<%= link_to project.name, project_path(project) %>
	<%= active ? "Active" : "Stale" %>
	<%= current_version.name if current_version %>
	<%= progress_bar([current_version.closed_pourcent, current_version.completed_pourcent]) if current_version %>
	<%= current_version.due_date if current_version %>
	<% project.visible_custom_field_values.each do |custom_value| %>

	  	<% if !custom_value.value.blank? %>
	     	<%=h show_value(custom_value) %>
	  	<% end %>

  <% end %>

<% end %>

<% current_version = project.versions.where("effective_date >= ?", Time.now).last %>
<% active = (current_version && Redmine::Activity::Fetcher.new(User.current, :project => project, :with_subprojects => true).events(Time.now - Setting.plugin_project_overview[:stale_num_days].to_i.days, Time.now).any?) %>

<% if active || @stale %>

	<%= link_to project.name, project_path(project) %>
	<%= active ? "Active" : "Stale" %>
	<%= current_version.name if current_version %>
	<%= progress_bar([current_version.closed_pourcent, current_version.completed_pourcent], :width => "100%") if current_version %>
	<%= current_version.due_date if current_version %>
	<% project.visible_custom_field_values.each do |custom_value| %>

	  	<% if !custom_value.value.blank? %>
	     	<%=h show_value(custom_value) %>
	  	<% end %>

  <% end %>

<% end %>

Make the progress bar 100% width of column.


server {
  listen 80;
  server_name nelhage.com;

  location / {
    rewrite ^ https://nelhage.com$request_uri? permanent;
  }
}

server {
  listen 80;
  listen 443 ssl;

  server_name www.nelhage.com;

  ssl_certificate /etc/ssl/certs/www.nelhage.com.pem;
  ssl_certificate_key /etc/ssl/certs/www.nelhage.com.pem;

  location / {
    rewrite ^ https://nelhage.com$request_uri? permanent;
  }
}

server {
  listen 443 ssl;

  server_name nelhage.com;

  ssl_certificate /etc/ssl/certs/www.nelhage.com.pem;
  ssl_certificate_key /etc/ssl/certs/www.nelhage.com.pem;

  add_header Strict-Transport-Security max-age=31536000;

  root /www/nelhage.com/;

  location /blog {
    rewrite ^/blog(.*) http://blog.nelhage.com$1;
  }

  location ~ "^/(git|bughunting|files/(stars|Troy)|poc\|\|gtfo)" {
    autoindex on;
  }

  location /money/ajax/ {
    proxy_pass http://127.0.0.1:19080$uri;
  }
}

server {
  listen 80;
  server_name nelhage.com;

  location / {
    rewrite ^ https://nelhage.com$request_uri? permanent;
  }
}

server {
  listen 80;
  listen 443 ssl;

  server_name www.nelhage.com;

  ssl_certificate /etc/ssl/certs/www.nelhage.com.pem;
  ssl_certificate_key /etc/ssl/certs/www.nelhage.com.pem;

  location / {
    rewrite ^ https://nelhage.com$request_uri? permanent;
  }
}

server {
  listen 443 ssl;

  server_name nelhage.com;

  ssl_certificate /etc/ssl/certs/www.nelhage.com.pem;
  ssl_certificate_key /etc/ssl/certs/www.nelhage.com.pem;

  add_header Strict-Transport-Security max-age=31536000;

  root /opt/www/nelhage.com/;

  location /blog {
    rewrite ^/blog(.*) http://blog.nelhage.com$1;
  }

  location ~ "^/(git|bughunting|files/(stars|Troy)|poc\|\|gtfo)" {
    autoindex on;
  }

  location /money/ajax/ {
    proxy_pass http://127.0.0.1:19080$uri;
  }
}

Fix the docroot for nelhage.com

Fix the docroot for nelhage.com


  <a href="/goals/<%= goal.id %>"><%= goal.name %>

  <%= goal.pillar.name %>: <%= goal.strand.name %>

  <span <% if goal.set_at < DateTime.current && !goal.is_completed %> class="active" <% end %>>Start: <%= goal.set_at %>

  <span <% if goal.deadline < (DateTime.current + 3) && !goal.is_completed %> class="active" <% end %>>Deadline: <%= goal.deadline %>

  <a href="/goals/<%= goal.id %>"><%= goal.name %>

  <%= goal.pillar.name %>: <%= goal.strand.name %>

  <% if goal.set_at < DateTime.current && !goal.is_completed %>

  <% else %>

  <% end %>
  Start: <%= goal.set_at %>

  <% if goal.deadline < (DateTime.current + 3) && !goal.is_completed %>

  <% else %>

  <% end %>
  Deadline: <%= goal.deadline %>

Add proper if-else statement for active spans


<%# The async.callback key can result in an infinite recursive output when to_s is called %>
<% filtered_env = @request.filtered_env.except("async.callback") -%>
<% max = filtered_env.keys.map(&:to_s).max { |a, b| a.length <=> b.length } -%>
<% filtered_env.keys.map(&:to_s).sort.each do |key| -%>
  * <%= raw safe_encode("%-*s: %s" % [max.length, key, inspect_object(filtered_env[key])]).strip %>
<% end -%>

691: Remove async.callback from exception notification


[Unit]
Description=Jenkins Daemon
After=syslog.target

[Service]
Type=simple
Environment="JENKINS_HOME=/var/lib/jenkins"
ExecStart=/usr/bin/java -Xmx<%= @settings['jenkins_heap_limit'] %> -jar /usr/lib/jenkins/jenkins.war --webroot=/var/cache/jenkins/war --httpPort=8082 --ajp13Port=-1 --prefix=/jenkins --httpListenAddress=127.0.0.1
User=jenkins

[Install]
WantedBy=multi-user.target

[Unit]
Description=Jenkins Daemon
After=syslog.target

[Service]
Type=simple
Environment="JENKINS_HOME=/var/lib/jenkins"
ExecStart=/usr/bin/java -Xmx<%= @settings['jenkins_heap_limit'] %> -Dhudson.model.ParametersAction.keepUndefinedParameters=true -jar /usr/lib/jenkins/jenkins.war --webroot=/var/cache/jenkins/war --httpPort=8082 --ajp13Port=-1 --prefix=/jenkins --httpListenAddress=127.0.0.1
User=jenkins

[Install]
WantedBy=multi-user.target

Fix dynamic job' parameters removed by Jenkins

Since the upgrade to Jenkins 1.651 and the SF 2.2.1 release
the artifacts export (with zuul_swift_upload) was broken because
relying on dynamics parameters. This patch adds the option
hudson.model.ParametersAction.keepUndefinedParameters to Jenkins
at startup.

Co-Authored-By: tdecacqu@redhat.com

Change-Id: Ic12b9379f8d9fbdf144ba6aa31c150a14fd675b4


<% if current_site.configuration.available_locales.length > 1 %>

    <%= t('.translate') %>
    <% current_site.configuration.available_locales.each do |locale| %>
      <a href="#" data-toggle-edit-locale="<%= locale %>" class="locale_option tipsit" title="<%= t('.define_content_in_locale', locale_name: t("locales.#{locale}")) %>" <%= %Q{data-loaded-locale="#{locale}"}.html_safe if locale == current_site.configuration.default_locale %>>
        <%= t("locales.#{locale}_short").upcase %>

    <% end %>

<% end %>

<% if current_site.configuration.available_locales.length > 1 %>

    <%= t('.translate') %>
    <% current_site.configuration.available_locales.each do |locale| %>
      <a href="#" data-toggle-edit-locale="<%= locale %>" class="locale_option tipsit" title="<%= t('.define_content_in_locale', locale_name: t("locales.#{locale}")) %>" <%= %Q{data-loaded-locale="#{locale}"}.html_safe if locale == current_site.configuration.default_locale %>>
        <%= t("locales.#{locale}_short").upcase %>

    <% end %>

<% else %>
  <div <%= %Q{data-loaded-locale="#{current_site.configuration.default_locale}"}.html_safe %>>

<% end %>

Fix default locale when only one locale is selected


<<<<<<< HEAD
<%- if @restart_limit -%>
  IF <%= @restart_limit['restarts'] %> RESTARTS WITHIN <%= @restart_limit['cycles'] %> CYCLES THEN <%= @restart_limit['action'] %>
<%- end -%>
  GROUP <%= @group %>
<%- unless @depends.empty? -%>
  DEPENDS <%= @depends.join(', ') %>
<%- end -%>
<%- unless @every.empty? -%>
  EVERY <%= @every %>
<%- end -%>
<%- unless @alerts.empty? -%>
  <%- @alerts.each do |alert| -%>
  ALERT <%= alert %>
  <%- end -%>
<%- end %>
<%- unless @noalerts.empty? -%>
  <%- @noalerts.each do |noalert| -%>
  NOALERT <%= noalert %>
  <%- end -%>
<%- end -%>
<%- @tests_real.each do |test| -%>
  IF <%= test['condition'] %>
  <%- if test.key? 'tolerance' -%>
    FOR <%= test['tolerance'] %>
  <%- end -%>
  THEN <%= test['action'] %>
<%- end -%>

Remove leftover tag of rebase

Remove leftover tag of rebase


Step 2: Tell us about <%= @school_onboarding.school_name %>

    Tell us about your school so that we can tailor the activities and insights
    we provide to you and user pupils, so that you can get the best from our
    service.

    <%= simple_form_for(@school, url: onboarding_school_details_path(@school_onboarding)) do |f| %>
      <%= render 'form', school: @school, school_onboarding: @school_onboarding, key_stages: @key_stages %>
    <% end %>

Step 2: Tell us about your school

    Tell us about your school so that we can tailor the activities and insights
    we provide to you and your pupils, so that you can get the best from our
    service.

    <%= simple_form_for(@school, url: onboarding_school_details_path(@school_onboarding)) do |f| %>
      <%= render 'form', school: @school, school_onboarding: @school_onboarding, key_stages: @key_stages %>
    <% end %>

Tweak wording on tell us about your school


    <%= link_to image_tag(entity.avatar.url), person_path(entity), class: 'image' %>

        <%= link_to entity.name, person_path(entity) %>
        <% if !entity.short_name.nil? && !entity.short_name.blank? %>
        (<%= link_to entity.short_name, organization_path(entity) %>)
        <% end %>

        <%= entity.description %>

      <%= render 'shared/show_admin_links', :item => entity %>

    <%= link_to image_tag(entity.avatar.url), person_path(entity), class: 'image' %>

        <%= link_to entity.name, organization_path(entity) %>
        <% if !entity.short_name.nil? && !entity.short_name.blank? %>
        (<%= link_to entity.short_name, organization_path(entity) %>)
        <% end %>

        <%= entity.description %>

      <%= render 'shared/show_admin_links', :item => entity %>

Fix link in organizations view page

Fix link in organizations view page


New Article

<%= form_for :article, url: articles_path do |f| %>

      <%= f.label :title %>

      <%= f.text_field :title %>

      <%= f.label :text %>

      <%= f.text_area :text %>

      <%= f.submit %>

<% end %>

Create new view for articles

Create new view for articles


User groups

  <%= link_to "Create a group", new_group_path %>

Groups you belong to:

(most active at top)

      Group
      Votes

    <%= render @user_groups %>

Other groups:

To join, you'll need a passcode...

      Group
      Votes

    <%= render @groups %>

User groups

<%= link_to "Create a group", new_group_path %>

  <% if @user_groups.length > 0 %>

Groups you belong to:

(most active at top)

        Group
        Votes

        <%= render @user_groups %>

  <% else %>

You haven't joined any groups yet. Create one or get a passcode from a friend!

  <% end %>

Other groups:

To join, you'll need a passcode...

        Group
        Votes

        <%= render @groups %>

Make groups page mobile responsive

Make groups page mobile responsive


/* DO NOT EDIT: File is auto-generated */
package <%= service.data_module.jws.service_package %>;

<%= description_javadoc_for(service, "") %>@javax.annotation.Generated( "Domgen" )
@SuppressWarnings( { "UnusedDeclaration", "JavaDoc" } )
@javax.jws.WebService( name = "<%= service.jws.service_name %>" )
public interface <%= service.jws.service_name %>
  extends java.rmi.Remote
{
  String SERVICE_NAME = "<%= service.jws.qualified_service_name %>";

<% service.methods.each do |method|
%><%= description_javadoc_for(method)
%>  @javax.jws.WebMethod( operationName = "<%= method.name %>" )
  <%= annotated_type(method.return_value, :jws) %> <%= Domgen::Naming.camelize(method.name) %>(<%= method.parameters.collect{|p| "@javax.jws.WebParam( name = \"#{p.name}\", mode = javax.jws.WebParam.Mode.IN, header = false ) #{annotated_type(p, :jws)} #{Domgen::Naming.camelize(p.name)}" }.join(",\n      ") %>)<%=
    exceptions = ["java.rmi.RemoteException"] + method.exceptions.collect{|e| e.jws.qualified_name}
    "\n    throws #{exceptions.join(', ')}"
%>;

<% end %>}

/* DO NOT EDIT: File is auto-generated */
package <%= service.data_module.jws.service_package %>;

<%= description_javadoc_for(service, "") %>@javax.annotation.Generated( "Domgen" )
@SuppressWarnings( { "UnusedDeclaration", "JavaDoc" } )
@javax.jws.WebService( name = "<%= service.jws.service_name %>" )
public interface <%= service.jws.service_name %>
  extends java.rmi.Remote
{
  String SERVICE_NAME = "<%= service.jws.qualified_service_name %>";

<% service.methods.select{|method| method.jws?}.each do |method|
%><%= description_javadoc_for(method)
%>  @javax.jws.WebMethod( operationName = "<%= method.name %>" )
  <%= annotated_type(method.return_value, :jws) %> <%= Domgen::Naming.camelize(method.name) %>(<%= method.parameters.collect{|p| "@javax.jws.WebParam( name = \"#{p.name}\", mode = javax.jws.WebParam.Mode.IN, header = false ) #{annotated_type(p, :jws)} #{Domgen::Naming.camelize(p.name)}" }.join(",\n      ") %>)<%=
    exceptions = ["java.rmi.RemoteException"] + method.exceptions.collect{|e| e.jws.qualified_name}
    "\n    throws #{exceptions.join(', ')}"
%>;

<% end %>}

Exclude methods where the facet is disabled


        <button type="button" class="close" data-dismiss="modal" aria-label="Close">×</button>

New Show

      	<%= form_tag("/productions/new", method: "post") do %>
        	<%= label_tag(:name, "Production Name:") %>
        	<%= text_field_tag(:name)%>
        	<%= label_tag(:date, "Production Date:") %>
        	<%= text_field_tag(:date)%>
        	<%= label_tag(:venue, "Venue:") %>
        	<%= text_field_tag(:venue)%>
      	<%end%>

        <button type="button" class="btn btn-default" data-dismiss="modal">Close without saving</button>
        <button type="button" class="btn btn-primary">Create Show</button>

        <button type="button" class="close" data-dismiss="modal" aria-label="Close">×</button>

New Show

      	<%= form_tag("/productions/new", method: "post") do %>
        	<%= label_tag(:name, "Production Name:") %>
        	<%= text_field_tag(:name)%>
        	<%= label_tag(:date, "Production Date:") %>
        	<%= date_field_tag(:date)%>
        	<%= label_tag(:venue, "Venue:") %>
        	<%= text_field_tag(:venue)%>
      	<%end%>

        <button type="button" class="btn btn-default" data-dismiss="modal">Close without saving</button>
        <button type="button" class="btn btn-primary">Create Show</button>

Change Date field in new Production modal from text field


<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
  <key>KeepAlive</key>
  <true/>
  <key>Label</key>
  <string><%= project_name %></string>
  <key>ProgramArguments</key>
  <array>
    <string>/usr/sbin/<%= project_name %></string>
    <string>--log</string>
    <string>/var/log/<%= project_name %>/<%= project_name %>.log</string>
    <string>--use-v1-config</string>
  </array>
  <key>RunAtLoad</key>
  <true/>
  <key>WorkingDirectory</key>
  <string><%= install_path %></string>
</dict>
</plist>

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
  <key>KeepAlive</key>
  <true/>
  <key>Label</key>
  <string><%= project_name %></string>
  <key>ProgramArguments</key>
  <array>
    <string>/opt/<%= project_name %>/usr/sbin/<%= project_name %></string>
    <string>--log</string>
    <string>/var/log/<%= project_name %>/<%= project_name %>.log</string>
    <string>--use-v1-config</string>
  </array>
  <key>RunAtLoad</key>
  <true/>
  <key>WorkingDirectory</key>
  <string><%= install_path %></string>
</dict>
</plist>

Use /opt/td-agent prefix instead of /usr/sbin to avoid rootless issue


---

- job:
    name: <%= @job_name %>
    display-name: <%= @job_name %>
    project-type: freestyle
    properties:
      - build-discarder:
          days-to-keep: 30
          artifact-num-to-keep: 5
    builders:
        - shell: |
          <%- if scope.lookupvar('::aws_migration') %>
            ssh deploy@$(govuk_node_list -c search --single-node) '
          <%- else -%>
            ssh deploy@search-1.api '
          <%- end -%>
            cd /var/apps/rummager &&
            govuk_setenv rummager bundle exec rake analytics:create_data_import_csv EXPORT_PATH=/data/export/enhanced_ecommerce &&
            govuk_setenv rummager bundle exec rake analytics:delete_old_files EXPORT_PATH=/data/export/enhanced_ecommerce EXPORT_FILE_LIMIT=10
            '
    triggers:
        - timed: '<%= @cron_schedule %>'
    publishers:
        - trigger-parameterized-builds:
            - project: Success_Passive_Check
              condition: 'SUCCESS'
              predefined-parameters: |
                  NSCA_CHECK_DESCRIPTION=<%= @service_description %>
                  NSCA_OUTPUT=<%= @service_description %> success
            - project: Failure_Passive_Check
              condition: 'FAILED'
              predefined-parameters: |
                  NSCA_CHECK_DESCRIPTION=<%= @service_description %>
                  NSCA_OUTPUT=<%= @service_description %> failed

---

- job:
    name: <%= @job_name %>
    display-name: <%= @job_name %>
    project-type: freestyle
    properties:
      - build-discarder:
          days-to-keep: 30
          artifact-num-to-keep: 5
    builders:
      - trigger-builds:
          - project: run-rake-task
            block: true
            predefined-parameters: |
              TARGET_APPLICATION=rummager
              MACHINE_CLASS=search
              RAKE_TASK="analytics:create_data_import_csv EXPORT_PATH=/data/export/enhanced_ecommerce"
          - project: run-rake-task
            block: true
            predefined-parameters: |
              TARGET_APPLICATION=rummager
              MACHINE_CLASS=search
              RAKE_TASK="analytics:delete_old_files EXPORT_PATH=/data/export/enhanced_ecommerce EXPORT_FILE_LIMIT=10"
    triggers:
        - timed: '<%= @cron_schedule %>'
    publishers:
        - trigger-parameterized-builds:
            - project: Success_Passive_Check
              condition: 'SUCCESS'
              predefined-parameters: |
                  NSCA_CHECK_DESCRIPTION=<%= @service_description %>
                  NSCA_OUTPUT=<%= @service_description %> success
            - project: Failure_Passive_Check
              condition: 'FAILED'
              predefined-parameters: |
                  NSCA_CHECK_DESCRIPTION=<%= @service_description %>
                  NSCA_OUTPUT=<%= @service_description %> failed

Use run-rake-task in enhanced ecommerce jobs


Powered by CARTO

  <% if @error.blank? %>
    <%= form_tag(CartoDB.url(self, :oauth2_authorize, {}, current_user), method: :post) do %>
      <%= hidden_field_tag 'response_type', @response_type %>
      <%= hidden_field_tag 'client_id', @oauth_app.client_id %>
      <%= hidden_field_tag 'scope', @scopes.join(' ') %>
      <%= hidden_field_tag 'state', @state %>
      <%= hidden_field_tag 'redirect_uri', @redirect_uri %>
      <%= submit_tag 'Reject', class: 'oauth-form__button' %>
      <%= submit_tag 'Accept', name: 'accept', class: 'oauth-form__button oauth-form__button--primary' %>
    <% end %>
  <% else %>
    <%= link_to 'Go to dashboard', CartoDB.url(self, 'dashboard', { trailing_slash: true }, current_user), class: 'oauth-form__button oauth-form__button--primary oauth-form__button--is-link' %>
  <% end %>

Add hyperlink to CARTO in footer

Add hyperlink to CARTO in footer


About This Thing

Do you need to come up with an article like, yesterday? Are you running out of ideas?  Are you desperate for headlines that drive traffic to your site, like lemmings over a cliff, or moths to a flame?  Are you  so hung over that you can't think straight?  If so, YOUR TRIBULATIONS ARE OVER.  Let Clickbait Generator be creative for you. We come up with simply irresistible headlines at the press of a virtual button! You click, then they click!  It's just that easy!

And if you believe the above I have a bridge across the Golden Gate to sell you!

About This Thing

Need to come up with an article, like, yesterday? Out of ideas?  Desperate for headlines that drive
traffic to your site, like lemmings over a cliff, or moths to a flame?
Too hung over to do your job?  If so, YOUR PROBLEMS ARE OVER.
Let Clickbait Generator DO IT. Simply irresistible
headlines at the press of a button! You click, then they click!  It's just that easy!

Make the text suck less.

Make the text suck less.


<%= link_to 'Back', spots_path %>

<%= @spot.name %>

<%= link_to 'Edit', edit_spot_path(@spot) %>

<%= @spot.address %>

<%= @spot.phone %>

<% if @spot.website %>
<%= @spot.website %>

<% end %>
<%#= show_price(@spot.price) %>

<%= show_photo(@spot.photo) if @spot.photo %>

<%= button_to "Leave Comment", { action: "new"}, form_class: "comment" %>
<% @spot.comments.each do |comment| %>
	<%= comment.body %>
<% end %>

Add list of comments and comment button

Add list of comments and comment button


<%
  form = local_assigns[:form]
  errors = form&.errors
%>

Estimate how much your guaranteed income could be

<%= render 'calculators/error_summary', messages: errors&.messages if form&.invalid? %>

<form action="/guaranteed-income/estimate#form" method="get">
  <%= render 'calculators/form_input_currency',
             field: :pot,
             value: form&.pot,
             label: 'How much is in your pot?',
             error_messages: errors&.get(:pot) %>

  <%= render 'calculators/form_input_number',
             field: :age,
             css_classes: 'js-scroll-target',
             value: form&.age,
             label: 'What age do you want to retire?',
             error_messages: errors&.get(:age) %>

  <%= render 'calculators/form_input_submit' %>
</form>

<% if form %>

<% end %>

<%
  form = local_assigns[:form]
  errors = form&.errors
%>

Estimate how much your guaranteed income could be

<%= render 'calculators/error_summary', messages: errors&.messages if form&.invalid? %>

<form action="/guaranteed-income/estimate#form" method="get">
  <%= render 'calculators/form_input_currency',
             field: :pot,
             value: form&.pot,
             label: 'How much is in your pot?',
             error_messages: errors&.get(:pot) %>

  <%= render 'calculators/form_input_number',
             field: :age,
             css_classes: 'js-scroll-target',
             value: form&.age,
             label: 'What age do you want to take your money?',
             error_messages: errors&.get(:age) %>

  <%= render 'calculators/form_input_submit' %>
</form>

<% if form %>

<% end %>

Update guaranteed income calculator copy

Removed retire after guider feedback. Changed to  '...take your money?'


<%= link_to 'Trending', '#' %> // <%= link_to 'Newest', '#' %>

<%= @trail.name %>

<%= link_to 'Post a Comment', new_trail_comment_path(@trail) %>

<% @comments.each do |comment| %>

    <%= link_to image_tag("snowflake.png", class: "snowflake"), {:controller => "votes",
        :action => "create",
        :comment_id => comment.id,
        :user_id => current_user.id,
        :value => "1"},
        :method => "post" %>

    <%= comment.votes.sum(:value) %>

<%= comment.content%>

Posted by: <%= comment.user.name %>

<% end %>

<%= link_to 'Trending', '#' %> // <%= link_to 'Newest', '#' %>

<%= @trail.name %>

<%= link_to 'Post a Comment', new_trail_comment_path(@trail) %>

<% @comments.each do |comment| %>

    <% if current_user %>
      <%= link_to image_tag("snowflake.png", class: "snowflake"), {:controller => "votes",
          :action => "create",
          :comment_id => comment.id,
          :user_id => current_user.id,
          :value => "1"},
          :method => "post" %>
    <% else %>
      <%= link_to image_tag("snowflake.png", class: "snowflake") %>
    <% end %>

    <%= comment.votes.sum(:value) %>

<%= comment.content%>

Posted by: <%= comment.user.name %>

<% end %>

Include current_user logic for voting to avoid error page


			<%= render 'layouts/copyright' %>

Users - Index

			<%= render 'layouts/copyright' %>

Users - Index

			<%= render 'layouts/copyright' %>

Users - Index

      <% @users.each do |user| %>

          <%= render user %>

      <% end %>

			<%= render 'layouts/copyright' %>

Users - Index

      <% @users.each do |user| %>

          <%= render user %>

      <% end %>

Add content to user index

Add content to user index


Mark snapshot as safe HTML

Mark snapshot as safe HTML


<% if @assets and @assets.any? %>
  $('table.assets tbody').prepend("<%= j render(@assets) %>");
<% end %>
<% flash.each do |name, msg| %>
  new Flash('<%= msg %>', '<%= name %>')
<% end -%>

<% if @assets and @assets.any? %>
  $('table.assets tbody').prepend("<%= j render(@assets) %>");
  $('tr.no-assets').remove();
<% end %>
<% flash.each do |name, msg| %>
  new Flash('<%= msg %>', '<%= name %>')
<% end -%>

Remove message row for empty assets on new asset create


<% govspeak_for :body do %>
  <% if calculator.number_of_benefits > 0 %>
    Based on your answers you may be eligible to apply for these <%= calculator.number_of_benefits %> things.
  <% else %>
    Based on your answers you are not eligible to apply for any benefits.
  <% end %>

  <% calculator.benefits_for_outcome.each do |benefit| %>
   <%= render "components/result-card", { title: benefit["title"], description: benefit["description"], url: benefit["url"], url_text: benefit["url_text"] } %>

    ---
  <% end %>
<% end %>

<% govspeak_for :body do %>
  <% if calculator.number_of_benefits > 0 %>
    Based on your answers you may be eligible to apply for these <%= calculator.number_of_benefits %> things.
  <% else %>
    Based on your answers, you may not be eligible for any benefits.
  <% end %>

  <% calculator.benefits_for_outcome.each do |benefit| %>
   <%= render "components/result-card", { title: benefit["title"], description: benefit["description"], url: benefit["url"], url_text: benefit["url_text"] } %>

    ---
  <% end %>
<% end %>

Update no eligible benefit copy

Update no eligible benefit copy


<!DOCTYPE html>

  <title>Mountain Chat</title>

  <%= stylesheet_link_tag    'application', media: 'all' %>
  <%= javascript_include_tag 'application' %>
  <%= csrf_meta_tags %>

Mountain Chat Header

<%= yield %>

    <% if current_user %>

Welcome, <%= current_user.name %>

    <% else %>

<%= link_to 'Login', login_path %>

||

<%= link_to 'Signup', new_user_path %>

    <% end %>

<!DOCTYPE html>

  <title>Mountain Chat</title>

  <%= stylesheet_link_tag    'application', media: 'all' %>
  <%= javascript_include_tag 'application' %>
  <%= csrf_meta_tags %>

Mountain Chat Header

<%= yield %>

    <% if current_user %>

Welcome, <%= current_user.name %>

    <% else %>

<%= link_to 'Login', new_session_path %>

||

<%= link_to 'Signup', new_user_path %>

    <% end %>

Change Login path to new_sesion

Change Login path to new_sesion


<!DOCTYPE html>

  <title>BlogSample</title>
  <%= stylesheet_link_tag    'application', media: 'all', 'data-turbolinks-track' => true %>
  <%= javascript_include_tag 'application', 'data-turbolinks-track' => true %>
  <%= csrf_meta_tags %>
  <meta name="viewport" content="width=device-width, initial-scale=1">

  <link data-require="bootstrap-css@3.3.6" data-semver="3.3.6" rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.css" />

<% if user_signed_in? %>
	Hello, <%= current_user.username %> | <%= link_to 'Sign Out', destroy_user_session_path, method: :delete %>
<% else %>
	<%= link_to 'Sign In', new_user_session_path %>
<% end %>

<%= notice %>

<%= alert %>

<%= yield %>

Add div container in layouts

Add div container in layouts


<!DOCTYPE html>
<html>
<head>
  <% if content_for?(:head) %>
    <%= content_for(:head) %>
  <% else %>
    <title>Don't Feed The Meter</title>
  <% end %>
  <%= stylesheet_link_tag    "application", media: "all", "data-turbolinks-track" => true %>
  <%= javascript_include_tag "application", "data-turbolinks-track" => true %>
  <%= csrf_meta_tags %>

</head>
<body>

<%= yield %>

</body>
</html>

<!DOCTYPE html>
<html>
<head>
  <% if content_for?(:head) %>
    <%= content_for(:head) %>
  <% else %>
    <title>Don't Feed The Meter</title>
  <% end %>
  <meta name="viewport" content="width=device-width" />
  <%= stylesheet_link_tag    "application", media: "all", "data-turbolinks-track" => true %>
  <%= javascript_include_tag "application", "data-turbolinks-track" => true %>
  <%= csrf_meta_tags %>

</head>
<body>

<%= yield %>

</body>
</html>

Make app actually responsive (oops)

Make app actually responsive (oops)


<!DOCTYPE html>

  <title><%= content_for?(:title) ? content_for(:title) : "District Housing" %></title>
  <meta name="viewport" content="initial-scale=1">
  <%= stylesheet_link_tag    "application", :media => "all" %>
  <%= javascript_include_tag "application" %>

  <link href="//netdna.bootstrapcdn.com/font-awesome/3.2.1/css/font-awesome.css" rel="stylesheet">
  <link href='http://fonts.googleapis.com/css?family=Montserrat:700' rel='stylesheet' type='text/css'>
  <%= csrf_meta_tags %>

<body id=<%= @landing ? "landing" : ""%>

<%= image_tag "district-housing-logo-small.png" %>

      <% unless @no_sidebar %>

        <%= render "layouts/sidebar" %>

          <%= yield %>

      <% else %>

        <%= yield %>

      <% end %>

<!DOCTYPE html>

  <title><%= content_for?(:title) ? content_for(:title) : "District Housing" %></title>
  <meta name="viewport" content="initial-scale=1">
  <%= stylesheet_link_tag    "application", :media => "all" %>
  <%= javascript_include_tag "application" %>

  <link href="//netdna.bootstrapcdn.com/font-awesome/3.2.1/css/font-awesome.css" rel="stylesheet">
  <link href='http://fonts.googleapis.com/css?family=Montserrat:700' rel='stylesheet' type='text/css'>
  <%= csrf_meta_tags %>

<body <%= "id=landing" if @landing %> >

<%= image_tag "district-housing-logo-small.png" %>

      <% unless @no_sidebar %>

        <%= render "layouts/sidebar" %>

          <%= yield %>

      <% else %>

        <%= yield %>

      <% end %>

Fix improperly generated "landing" class for body


 <%= response.user ? response.user.name : 'Default' %>

<%= response.content %>

   Comments
  <%= link_to 'Add Comment', new_response_comment_path(response) %>
  <% response.comments.each do |comment| %>
    <%= render partial: 'comment', locals: {comment: comment} %>
  <% end %>
   <button data-id="<%response.id%>" class="upvote">UpVote</button>

 <%= response.user ? response.user.name : 'Default' %>

<%= response.content %>

   Comments
  <%= link_to 'Add Comment', new_response_comment_path(response) %>
  <% response.comments.each do |comment| %>
    <%= render partial: 'comment', locals: {comment: comment} %>
  <% end %>
   <button data-id="<%= response.id %>" class="upvote">UpVote</button>

Fix erb tag to populate data id attribute.