<% content_for :head do %>
  <script>
    document.addEventListener('DOMContentLoaded', () => {
      makeStarterCodeFileManager(document.getElementById('starter-code-file-manager'),
        {
          assignment_id: <%= @assignment.id %>,
          repo_url: '<%= File.join(MarkusConfigurator.markus_config_repository_external_base_url,
                                   Assignment::STARTER_CODE_REPO_NAME, @assignment.repository_folder) %>',
          readOnly: <%= @assignment.can_upload_starter_code? ? 'false' : 'true' %>
        }
      );
    });
  </script>
<% end %>

<div id='starter-code-file-manager'></div>

<aside class='dialog' id='addnew_dialog'>
  <h2><%= t('add_new') %></h2>

  <%= form_tag update_files_assignment_path(id: @assignment.id),
               { multipart: true, id: 'file_form' } do %>
      <%= file_field_tag :new_files, name: 'new_files[]', multiple: true %>

      <section class='dialog-actions'>
        <%= submit_tag t(:submit) %>
        <%= button_tag t(:close), onclick: 'modal_addnew.close(); return false;' %>
      </section>
  <% end %>
</aside>

<% content_for :head do %>
  <script>
    document.addEventListener('DOMContentLoaded', () => {
      makeStarterCodeFileManager(document.getElementById('starter-code-file-manager'),
        {
          assignment_id: <%= @assignment.id %>,
          repo_url: '<%= File.join(MarkusConfigurator.markus_config_repository_external_base_url,
                                   Assignment::STARTER_CODE_REPO_NAME) %>',
          readOnly: <%= @assignment.can_upload_starter_code? ? 'false' : 'true' %>
        }
      );
    });
  </script>
<% end %>

<div id='starter-code-file-manager'></div>

<aside class='dialog' id='addnew_dialog'>
  <h2><%= t('add_new') %></h2>

  <%= form_tag update_files_assignment_path(id: @assignment.id),
               { multipart: true, id: 'file_form' } do %>
      <%= file_field_tag :new_files, name: 'new_files[]', multiple: true %>

      <section class='dialog-actions'>
        <%= submit_tag t(:submit) %>
        <%= button_tag t(:close), onclick: 'modal_addnew.close(); return false;' %>
      </section>
  <% end %>
</aside>

Fix repo address to not include subdir
starter-code: Fix repo address to not include subdir
